Skip to main content

encode

Function encode 

Source
pub fn encode(
    header: &WireEnvelopeHeader,
    body_archive: &[u8],
) -> Result<Vec<u8>, PartialError>
Expand description

Serialize a header + already-archived body into a framed partial blob.

Each paradigm archives its body via its own rkyv path (the body type lives in the paradigm crate and rkyv’s generic bounds are paradigm-specific) and hands the resulting bytes here. We frame with magic, version, header archive, body archive, CRC.