Trait matrix_pickle::Decode

source ·
pub trait Decode {
    // Required method
    fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>
       where Self: Sized;

    // Provided method
    fn decode_from_slice(buffer: &[u8]) -> Result<Self, DecodeError>
       where Self: Sized { ... }
}
Expand description

A trait for decoding values that were encoded using the matrix-pickle binary format.

Required Methods§

source

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>
where Self: Sized,

Try to read and decode a value from the given reader.

Provided Methods§

source

fn decode_from_slice(buffer: &[u8]) -> Result<Self, DecodeError>
where Self: Sized,

Try to read and decode a value from the given byte slice.

Implementations on Foreign Types§

source§

impl Decode for bool

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl Decode for u8

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl Decode for u32

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl Decode for usize

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl<T: Decode> Decode for Vec<T>

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl<const N: usize> Decode for Box<[u8; N]>

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

source§

impl<const N: usize> Decode for [u8; N]

source§

fn decode(reader: &mut impl Read) -> Result<Self, DecodeError>

Implementors§