Struct async_codec_util::Decoder
[−]
[src]
pub struct Decoder<R, D> { /* fields omitted */ }
Future for fully decoding an AsyncDecode
from an AsyncRead
.
Methods
impl<R, D> Decoder<R, D>
[src]
pub fn new(reader: R, dec: D) -> Decoder<R, D>
[src]
Create a new Decoder
wrapping an AsyncRead
and consuming an AsyncDecode
.
Trait Implementations
impl<R, D> Future for Decoder<R, D> where
R: AsyncRead,
D: AsyncDecode,
[src]
R: AsyncRead,
D: AsyncDecode,
type Item = (R, D::Item, usize)
A successful value
type Error = (R, DecodeError<D::Error>)
An error
fn poll(&mut self, cx: &mut Context) -> Poll<Self::Item, Self::Error>
[src]
Attempt to resolve the future to a final value, registering the current task for wakeup if the value is not yet available. Read more