Trait Decode

Source
pub trait Decode: Sized {
    // Required method
    fn decode<R>(
        reader: &mut R,
    ) -> impl Future<Output = Result<Self, Error>> + MaybeSend
       where R: SeqRead;
}

Required Methods§

Source

fn decode<R>( reader: &mut R, ) -> impl Future<Output = Result<Self, Error>> + MaybeSend
where R: SeqRead,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Decode for bool

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for f32

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for f64

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for i8

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for i16

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for i32

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for i64

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for u8

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for u16

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for u32

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for u64

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for String

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl Decode for Bytes

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Source§

impl<T> Decode for Arc<T>
where T: Decode,

Source§

async fn decode<R>(reader: &mut R) -> Result<Self, Error>
where R: SeqRead,

Source§

impl<T> Decode for Vec<T>
where T: Decode + Send + Sync,

Source§

async fn decode<R>(reader: &mut R) -> Result<Self, Error>
where R: SeqRead,

Source§

impl<V> Decode for Option<V>
where V: Decode,

Source§

async fn decode<R: SeqRead>(reader: &mut R) -> Result<Self, Error>

Implementors§