pub trait Deserialiser<T>: Send {
const SER_ID: u64;
// Required method
fn deserialise(buf: &mut dyn Buf) -> Result<T, SerError>;
}Expand description
A trait to deserialise values of type T from buffers
There should be one deserialiser with the same serialisation id for each Serialiser or Serialisable implementation. It is recommended to implement both on the same type.
Required Associated Constants§
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.