pub struct Chunk { /* private fields */ }Expand description
A read stream’s items and options (ReadStream).
Bytes of a region, read by a ReadStream: it owns a pool buffer,
given back when the chunk drops (to its stream while the stream lives,
else to the pool). Send: a worker thread may hold and drop it.
Implementations§
Source§impl Chunk
impl Chunk
Sourcepub fn offset(&self) -> u64
pub fn offset(&self) -> u64
The region offset of bytes()[0] (for an export’s region copied
in full, its offset in the region’s stream: the sum of the earlier
container ranges’ lengths and its place in its own).
Sourcepub fn range(&self) -> usize
pub fn range(&self) -> usize
Which of the stream’s ranges it is of: its index in
Store::prefetch’s ranges (0 for a
region’s own stream), so overlapping ranges read twice are told
apart.
Trait Implementations§
Auto Trait Implementations§
impl Forget for Chunk
impl Freeze for Chunk
impl Move for Chunk
impl RefUnwindSafe for Chunk
impl Send for Chunk
impl Sync for Chunk
impl Unpin for Chunk
impl UnsafeUnpin for Chunk
impl UnwindSafe for Chunk
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