Skip to main content

dispatch_frame

Function dispatch_frame 

Source
pub async fn dispatch_frame(
    bytes: &[u8],
    ctx: &DispatchContext,
) -> Vec<Outgoing>
Expand description

Decode + route one incoming frame, returning the frames to send back.

Never panics. Malformed bytes yield a single parse-error response with a null id (the id can’t be recovered from unparseable input). Client→server responses are ignored (lattice is the server; it issues no requests in I1). A notification may produce zero or more follow-ups (e.g. initialized → tools/list_changed).