Preview of the proposed up-rust native-frame-model branch (up-rust b6b99c6d, up-spec f0e9b17) — not released documentation. branch · write-up

Function try_project_frame_to_umessage

Source
pub fn try_project_frame_to_umessage(
    metadata: UFrameMetadata,
    payload: Option<Bytes>,
) -> Result<UMessage, UFrameMetadataError>
Expand description

Projects native frame metadata and optional payload bytes into a UMessage.

Native payload encodings without a legacy UPayloadFormat equivalent are carried by the UAttributes open payload-encoding identity fields.

ยงErrors

Returns an error if payload bytes and payload encoding are not both present or both absent, if the encoding is not representable, or if metadata invariants are violated.