pub struct GenericKeyedChunkWriter<K: RawSortKey> { /* private fields */ }Expand description
Generic writer for keyed temp chunks with pre-computed sort keys.
Works with any type implementing RawSortKey.
Supports optional BGZF compression for reduced disk usage.
Implementations§
Source§impl<K: RawSortKey> GenericKeyedChunkWriter<K>
impl<K: RawSortKey> GenericKeyedChunkWriter<K>
Sourcepub fn create(
path: &Path,
compression_level: u32,
threads: usize,
) -> Result<Self>
pub fn create( path: &Path, compression_level: u32, threads: usize, ) -> Result<Self>
Create a new keyed chunk writer with optional compression.
compression_level0 = uncompressed (fastest, uses most disk).compression_level> 0 = BGZF compression at specified level.threads> 1 enables multi-threaded compression.
§Errors
Returns an error if the output file cannot be created.
§Panics
Panics if threads is greater than 1 but NonZero::new receives zero.
Auto Trait Implementations§
impl<K> Freeze for GenericKeyedChunkWriter<K>
impl<K> !RefUnwindSafe for GenericKeyedChunkWriter<K>
impl<K> Send for GenericKeyedChunkWriter<K>
impl<K> Sync for GenericKeyedChunkWriter<K>
impl<K> Unpin for GenericKeyedChunkWriter<K>where
K: Unpin,
impl<K> UnsafeUnpin for GenericKeyedChunkWriter<K>
impl<K> !UnwindSafe for GenericKeyedChunkWriter<K>
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> 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