Serializable

Trait Serializable 

Source
pub trait Serializable<T> {
    // Required methods
    fn from_bytes(bytes: &[u8]) -> Result<T, ParseError>;
    fn to_bytes(&self) -> Result<Vec<u8>, ParseError>;
}

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.

Implementors§