[][src]Struct async_ringbuffer::Reader

pub struct Reader(_);

Read access to a nonblocking ring buffer with fixed capacity.

If there is no data in the buffer to read from, the current task is parked and notified once data becomes available.

Trait Implementations

impl Drop for Reader[src]

impl AsyncRead for Reader[src]

fn poll_read(&mut self, wk: &Waker, buf: &mut [u8]) -> Poll<Result<usize>>[src]

Read data from the RingBuffer.

This only returns Ok(Ready(0)) if either buf.len() == 0, poll_close was called on the corresponding Writer and all buffered data has been read, or if the corresponding Writer has been dropped.

Errors

This never emits an error.

unsafe fn initializer(&self) -> Initializer[src]

Determines if this AsyncReader can work with buffers of uninitialized memory. Read more

fn poll_vectored_read(
    &mut self,
    waker: &Waker,
    vec: &mut [&mut IoVec]
) -> Poll<Result<usize, Error>>
[src]

Attempt to read from the AsyncRead into vec using vectored IO operations. Read more

Auto Trait Implementations

impl !Send for Reader

impl !Sync for Reader

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]