Expand description
Encoders for encoding data into byte slices.
This module contains different types that implement the Encoder trait.
As a summary, these types implement the Encodable trait:
(): does nothing when encoding. Useful for testing.SizeEncoder: counts the number of bytes written.&mut [u8]: writes bytes into a slice, if there is enough space.Vec<u8>(stdorallocfeature): writes bytes into a vector that grows if necessary.ArrayVec(arrayvecfeature): writes bytes into an ArrayVec, if there is enough space.
Structsยง
- Insufficient
Space - An error that occurs when the provided buffer has no space left for encoding.
- Size
Encoder - An encoder that counts the size of the encoded data.