pub struct ReadStreamChunks { /* private fields */ }
Expand description
I/O-free coroutine to read HTTP response following the Chunked Transfer Coding.
Implementations§
Source§impl ReadStreamChunks
impl ReadStreamChunks
Sourcepub fn new(read: impl Into<ReadStream>) -> Self
pub fn new(read: impl Into<ReadStream>) -> Self
Creates a new coroutine from the given ReadStream
sub-coroutine.
Sourcepub fn extend(&mut self, bytes: impl IntoIterator<Item = u8>)
pub fn extend(&mut self, bytes: impl IntoIterator<Item = u8>)
Extends the inner read buffer with the given bytes.
Sourcepub fn resume(&mut self, arg: Option<StreamIo>) -> ReadStreamChunksResult
pub fn resume(&mut self, arg: Option<StreamIo>) -> ReadStreamChunksResult
Makes the coroutine progress.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ReadStreamChunks
impl RefUnwindSafe for ReadStreamChunks
impl Send for ReadStreamChunks
impl Sync for ReadStreamChunks
impl Unpin for ReadStreamChunks
impl UnwindSafe for ReadStreamChunks
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