pub struct GenericKeyedChunkReader<K: RawSortKey + 'static> { /* private fields */ }Expand description
Generic reader for keyed temp chunks with background prefetching.
Works with any type implementing RawSortKey.
Auto-detects BGZF compression via magic bytes.
Implementations§
Source§impl<K: RawSortKey + 'static> GenericKeyedChunkReader<K>
impl<K: RawSortKey + 'static> GenericKeyedChunkReader<K>
Sourcepub fn open(path: &Path) -> Result<Self>
pub fn open(path: &Path) -> Result<Self>
Open a keyed chunk file for reading with background prefetching. Auto-detects BGZF/gzip compression via magic bytes (0x1f 0x8b).
§Errors
Returns an error if the file cannot be opened.
Sourcepub fn next_record(&mut self) -> Option<(K, Vec<u8>)>
pub fn next_record(&mut self) -> Option<(K, Vec<u8>)>
Read the next keyed record from the prefetch buffer.
Auto Trait Implementations§
impl<K> Freeze for GenericKeyedChunkReader<K>
impl<K> !RefUnwindSafe for GenericKeyedChunkReader<K>
impl<K> Send for GenericKeyedChunkReader<K>
impl<K> Sync for GenericKeyedChunkReader<K>
impl<K> Unpin for GenericKeyedChunkReader<K>where
K: Unpin,
impl<K> UnsafeUnpin for GenericKeyedChunkReader<K>
impl<K> !UnwindSafe for GenericKeyedChunkReader<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