pub struct ContentStream { /* private fields */ }Expand description
Sequential verified reader over one ContentHandle.
Implementations§
Source§impl ContentStream
impl ContentStream
Sourcepub async fn next(&mut self) -> Result<Option<Arc<[u8]>>>
pub async fn next(&mut self) -> Result<Option<Arc<[u8]>>>
Returns the next verified chunk, or None at EOF.
Each returned value is at most the upload’s configured chunk size. The stream therefore does not allocate in proportion to total content size.
§Errors
Propagates the same storage, format, and integrity errors as
ContentHandle::read_range.
Trait Implementations§
Source§impl Clone for ContentStream
impl Clone for ContentStream
Source§fn clone(&self) -> ContentStream
fn clone(&self) -> ContentStream
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for ContentStream
impl !UnwindSafe for ContentStream
impl Freeze for ContentStream
impl Send for ContentStream
impl Sync for ContentStream
impl Unpin for ContentStream
impl UnsafeUnpin for ContentStream
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