pub fn encode_frame(
payload: &[u8],
out: &mut [u8],
) -> Result<usize, EncodeError>Expand description
Encode one frame, including both delimiting flags, into out.
Returns the number of bytes written. Size out with
max_encoded_len to make overflow impossible.