Trait async_serialization::AsyncDeserialize [] [src]

pub trait AsyncDeserialize<R: AsyncRead>: Sized {
    type DeserializeFuture: Future<Item = (R, Self, usize), Error = (R, DeserializeError<Self::Error>)>;
    type Error;
    fn deserialize_future(reader: R) -> Self::DeserializeFuture;
fn already_read(&self) -> usize; }

A type whose values can be deserialized from an AsyncRead.

Associated Types

The future that performs the deserialization. It yields back ownership of the wrapped reader, the deserialized value, and the number of bytes it read from the reader.

The error that is emitted when reading invalid data.

Required Methods

Consume a reader to create a DeserializeFuture.

Return how many bytes have already been read.

Implementors