pub struct Reader<T, E> { /* private fields */ }Implementations§
Trait Implementations§
source§impl<T, E> AsyncRead for Reader<T, E>where
T: Sink<Frame> + Stream<Item = Result<Frame, E>>,
impl<T, E> AsyncRead for Reader<T, E>where T: Sink<Frame> + Stream<Item = Result<Frame, E>>,
type Error = Error<<T as Sink<Frame>>::Error, E>
source§fn poll_read(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
buf: &mut [u8]
) -> Poll<Result<usize, Self::Error>>
fn poll_read( self: Pin<&mut Self>, cx: &mut Context<'_>, buf: &mut [u8] ) -> Poll<Result<usize, Self::Error>>
Attempt to read from the AsyncRead into buf.
On success, returns Poll::Ready(Ok(num_bytes_read)).
If no data is available for reading, this method returns Poll::Pending
and arranges for the current task to be woken.
impl<'__pin, T, E> Unpin for Reader<T, E>where __Origin<'__pin, T, E>: Unpin,
Auto Trait Implementations§
impl<T, E> RefUnwindSafe for Reader<T, E>where E: RefUnwindSafe, T: RefUnwindSafe,
impl<T, E> Send for Reader<T, E>where E: Send, T: Send,
impl<T, E> Sync for Reader<T, E>where E: Sync, T: Sync,
impl<T, E> UnwindSafe for Reader<T, E>where E: UnwindSafe, T: UnwindSafe,
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