Expand description
Hex encoding of bytes and integers.
encode_bytes and encode_bytes_into encode a byte slice into an
owned String or an appended Vec<u8>, respectively; encode_bytes_to_slice
writes into a caller-provided, pre-sized buffer. encode_u64 encodes an
integer, trimming leading zeros. All four take a HexCase to choose
between lowercase and uppercase digits.
Enums§
- HexCase
- Case of the emitted hex digits.
Traits§
- ToHex
- Trait for converting integer types to hexadecimal in a buffer
Functions§
- encode_
bytes - Returns the hex encoding of
bytesas an ownedString. - encode_
bytes_ into - Appends the hex encoding of
bytestoout. - encode_
bytes_ to_ slice - Writes the hex encoding of
bytesintoout. - encode_
u64 - Writes
vas hex intobufand returns the written subslice.