[][src]Trait async_codec_lite::Decoder

pub trait Decoder {
    type Item;
    type Error: Error + 'static;
    pub fn decode(
        &mut self,
        src: &mut BytesMut
    ) -> Result<Option<Self::Item>, Self::Error>; pub fn decode_eof(
        &mut self,
        src: &mut BytesMut
    ) -> Result<Option<Self::Item>, Self::Error> { ... } }

Associated Types

type Item[src]

type Error: Error + 'static[src]

Loading content...

Required methods

pub fn decode(
    &mut self,
    src: &mut BytesMut
) -> Result<Option<Self::Item>, Self::Error>
[src]

Loading content...

Provided methods

pub fn decode_eof(
    &mut self,
    src: &mut BytesMut
) -> Result<Option<Self::Item>, Self::Error>
[src]

Loading content...

Implementors

impl Decoder for BytesCodec[src]

type Error = Infallible

type Item = Bytes

impl Decoder for LinesCodec[src]

type Error = FromUtf8Error

type Item = String

impl<C> Decoder for LimitCodec<C> where
    C: DecoderWithSkipAhead
[src]

type Error = LimitError<<C as Decoder>::Error>

type Item = <C as Decoder>::Item

impl<Enc, Dec> Decoder for CborCodec<Enc, Dec> where
    Dec: Deserialize<'de> + 'static, 
[src]

type Error = Error

type Item = Dec

impl<Enc, Dec> Decoder for JsonCodec<Enc, Dec> where
    Dec: Deserialize<'de> + 'static, 
[src]

type Error = Error

type Item = Dec

impl<L: Length> Decoder for LengthCodec<L>[src]

type Error = OverflowError

type Item = Bytes

Loading content...