pub trait BytesDecode<'a> {
type DItem: 'a;
// Required method
fn bytes_decode(bytes: &'a [u8]) -> Result<Self::DItem, BoxedError>;
}
Expand description
A trait that represents a decoding structure.
Required Associated Types§
Required Methods§
Sourcefn bytes_decode(bytes: &'a [u8]) -> Result<Self::DItem, BoxedError>
fn bytes_decode(bytes: &'a [u8]) -> Result<Self::DItem, BoxedError>
Decode the given bytes as DItem
.
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.