pub trait Decode: Sized {
// Required method
fn decode(buf: &mut &[u8]) -> Result<Self, EncodingError>;
}Expand description
Trait for types that can be decoded from bytes.
Required Methods§
fn decode(buf: &mut &[u8]) -> Result<Self, EncodingError>
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§
Implementors§
impl Decode for FieldValue
Decode implementation for FieldValue (value encoding, little-endian).
Note: For Vector type, this implementation requires the dimensions to be known.
Use FieldValue::decode_with_dimensions when decoding from VectorData records.