pub trait Decode<'a> {
type Value: Sized;
// Required methods
fn decode(buf: &'a [u8]) -> Result<(Self::Value, &'a [u8]), Error>;
fn decode_with_format(
format: Format,
buf: &'a [u8],
) -> Result<(Self::Value, &'a [u8]), Error>;
}
Expand description
A type that can be decoded from a MessagePack byte slice.
Required Associated Types§
Required Methods§
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.