pub struct WindowedReader<G, M: JoinMode, const BODY_SIZE: usize = DEFAULT_BODY_SIZE>where
G: ChunkGet<BODY_SIZE>,{ /* private fields */ }Expand description
Seek-and-play reader: forward in-order delivery over a window that slides
with the read cursor, bounded to window in-flight plus buffered leaves.
Retains the joiner’s reusable state (getter, pre-expanded frontier, tree
params) so each stream rebuilds a fresh window-bounded walk
from [position, size) without re-expanding the frontier. seek
only repositions; it never re-fetches intermediates.
Implementations§
Source§impl<G, M, const BODY_SIZE: usize> WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> WindowedReader<G, M, BODY_SIZE>
Sourcepub fn stream(&mut self) -> impl Stream<Item = Result<Bytes>> + '_
pub fn stream(&mut self) -> impl Stream<Item = Result<Bytes>> + '_
In-order leaf bodies from the current position to EOF. Each item is one
contiguous run; reassembly is pure concatenation. Peak memory is window
leaf bodies: the window slides with the emit cursor, so only leaves within
window spans ahead of it are ever fetched or held.
Source§impl<G, M, const BODY_SIZE: usize> WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> WindowedReader<G, M, BODY_SIZE>
Sourcepub fn into_reader(self) -> WindowedJoinerReader<G, M, BODY_SIZE>
pub fn into_reader(self) -> WindowedJoinerReader<G, M, BODY_SIZE>
Wrap as a tokio AsyncRead + AsyncSeek reader. Native-only.
Trait Implementations§
Auto Trait Implementations§
impl<G, M, const BODY_SIZE: usize> Freeze for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> RefUnwindSafe for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> Send for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> Sync for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> Unpin for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> UnsafeUnpin for WindowedReader<G, M, BODY_SIZE>
impl<G, M, const BODY_SIZE: usize> UnwindSafe for WindowedReader<G, M, BODY_SIZE>
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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