Skip to main content

encode_framed

Function encode_framed 

Source
pub fn encode_framed<T: VersionedCodec>(
    version: u8,
    value: &T,
) -> Result<Vec<u8>, CodecError>
Expand description

Encode value as [version | body], where body is value’s layout at version (see VersionedCodec::encode_version).