Skip to main content

Module codec

Module codec 

Source
Expand description

Core traits for encoding and decoding.

Traitsยง

BufsMut
A BufMut that can also append pre-existing Bytes chunks.
Codec
Convenience trait combining Encode and Decode.
CodecFixed
Convenience trait combining FixedSize and Codec.
CodecFixedShared
Convenience trait combining CodecFixed with thread-safety bounds and unit config.
CodecShared
Convenience trait combining Codec with thread-safety bounds.
Decode
Trait combining Read with a check for remaining bytes.
Encode
Trait combining Write and EncodeSize for types that can be fully encoded.
EncodeFixed
Convenience trait for FixedSize types that can be encoded directly into a fixed-size array.
EncodeShared
Convenience trait combining Encode with thread-safety bounds.
EncodeSize
Trait for types that can provide their encoded size in bytes.
FixedSize
Trait for types with a known, fixed encoded size.
Read
Trait for types that can be read (decoded) from a byte buffer.
Write
Trait for types that can be written (encoded) to a byte buffer.