pub struct ExternalSorterBuilder<T, E, B = LimitedBufferBuilder, C = RmpExternalChunk<T>>{ /* private fields */ }
Expand description
External sorter builder. Provides methods for ExternalSorter
initialization.
Implementations§
Source§impl<T, E, B, C> ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> ExternalSorterBuilder<T, E, B, C>
Sourcepub fn build(
self,
) -> Result<ExternalSorter<T, E, B, C>, SortError<C::SerializationError, C::DeserializationError, E>>
pub fn build( self, ) -> Result<ExternalSorter<T, E, B, C>, SortError<C::SerializationError, C::DeserializationError, E>>
Builds an ExternalSorter
instance using provided configuration.
Sourcepub fn with_threads_number(
self,
threads_number: usize,
) -> ExternalSorterBuilder<T, E, B, C>
pub fn with_threads_number( self, threads_number: usize, ) -> ExternalSorterBuilder<T, E, B, C>
Sets number of threads to be used to sort data in parallel.
Sourcepub fn with_tmp_dir(self, path: &Path) -> ExternalSorterBuilder<T, E, B, C>
pub fn with_tmp_dir(self, path: &Path) -> ExternalSorterBuilder<T, E, B, C>
Sets directory to be used to store temporary data.
Sourcepub fn with_buffer(self, buffer_builder: B) -> ExternalSorterBuilder<T, E, B, C>
pub fn with_buffer(self, buffer_builder: B) -> ExternalSorterBuilder<T, E, B, C>
Sets buffer builder.
Sourcepub fn with_rw_buf_size(
self,
buf_size: usize,
) -> ExternalSorterBuilder<T, E, B, C>
pub fn with_rw_buf_size( self, buf_size: usize, ) -> ExternalSorterBuilder<T, E, B, C>
Sets chunk read/write buffer size.
Trait Implementations§
Source§impl<T, E, B, C> Clone for ExternalSorterBuilder<T, E, B, C>where
T: Send + Clone,
E: Error + Clone,
B: ChunkBufferBuilder<T> + Clone,
C: ExternalChunk<T> + Clone,
impl<T, E, B, C> Clone for ExternalSorterBuilder<T, E, B, C>where
T: Send + Clone,
E: Error + Clone,
B: ChunkBufferBuilder<T> + Clone,
C: ExternalChunk<T> + Clone,
Source§fn clone(&self) -> ExternalSorterBuilder<T, E, B, C>
fn clone(&self) -> ExternalSorterBuilder<T, E, B, C>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<T, E, B, C> Default for ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> Default for ExternalSorterBuilder<T, E, B, C>
Auto Trait Implementations§
impl<T, E, B, C> Freeze for ExternalSorterBuilder<T, E, B, C>where
B: Freeze,
impl<T, E, B, C> RefUnwindSafe for ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> Send for ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> Sync for ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> Unpin for ExternalSorterBuilder<T, E, B, C>
impl<T, E, B, C> UnwindSafe for ExternalSorterBuilder<T, E, B, C>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more