pub trait Deserialize {
// Required method
fn deserialize<R: BufRead + Seek>(
raw: &mut Deserializer<R>,
) -> Result<Self, DeserializeError>
where Self: Sized;
// Provided method
fn from_cbor_bytes(data: &[u8]) -> Result<Self, DeserializeError>
where Self: Sized { ... }
}
Required Methods§
fn deserialize<R: BufRead + Seek>(
raw: &mut Deserializer<R>,
) -> Result<Self, DeserializeError>where
Self: Sized,
Provided Methods§
Sourcefn from_cbor_bytes(data: &[u8]) -> Result<Self, DeserializeError>where
Self: Sized,
fn from_cbor_bytes(data: &[u8]) -> Result<Self, DeserializeError>where
Self: Sized,
from-bytes using the exact CBOR format specified in the CDDL binary spec. For hashes/addresses/etc this will include the CBOR bytes type/len/etc.