Function ockam_transport_core::encode_transport_message
source · pub fn encode_transport_message(msg: TransportMessage) -> Result<Vec<u8>>
Expand description
Helper that creates a length-prefixed buffer containing the given
TransportMessage
’s payload
The length-prefix is encoded as a big-endian 16-bit unsigned integer.