Skip to main content

decode_record

Function decode_record 

Source
pub fn decode_record(
    schema: &Schema,
    data: &[u8],
    options: &DecodeOptions,
) -> Result<Value>
Expand description

Decode one fixed-size COBOL record into the public JSON envelope.

This uses the supplied schema and decode options, returning the same envelope shape as the streaming decode APIs for a single record.

ยงErrors

Returns an error if data cannot be decoded according to schema and options, including field conversion errors, invalid record lengths, or unsupported encoding combinations.