pub fn write(header: &Header, data: &[u8])Expand description
write writes a frame, both header and payload. Only as many bytes of payload are written,
as is specified by the length in the header, so 1, 4, 32 or 128 bytes. A larger
buffer may be provided, but will not be written fully.
§Panics
Panics if provided data-buffer is smaller than length specified in the provided header.