Skip to main content

decode_to_cdr

Function decode_to_cdr 

Source
pub fn decode_to_cdr<S: SchemaSource + ?Sized>(
    source: &mut S,
    type_name: &str,
    schema: &'static [Field],
    writer: &mut CdrWriter<'_>,
) -> Result<(), SchemaError>
Expand description

Walk schema, pulling each value from source and writing CDR.

The exact inverse of encode_from_cdr, including the per-struct DHEADER, so a value that survives one survives the pair byte-for-byte.