#hex-string #hex #string-conversion #numbers #serde

hex-wrapper

Wrappers of the convertion between numbers and hex strings

15 stable releases

new 1.5.2 Feb 17, 2025
1.5.1 Feb 8, 2025
1.4.1 May 31, 2023
1.4.0 Apr 20, 2023
1.0.1 Sep 2, 2021

#832 in Encoding

Download history 7/week @ 2024-12-04 14/week @ 2024-12-11 202/week @ 2025-02-05 301/week @ 2025-02-12

503 downloads per month

MIT/Apache

21KB
305 lines

The hex-wrapper is a collection of wrappers of the convertion between numbers and hex strings.

See the docs.rs for usages.


lib.rs:

hex-wrapper provides N-bit unsigned hexadecimal numbers.

Roughly speaking, Hex converts between uN and (lowercase) String hexadecimally.

Features

Defaults are all off.

  • rand: Enables random constructors HexN::rand() and HexN::with_rng().
  • serde: Enables conversion used in serde (e.g. for json).
  • db: Enables implementations of diesel v2.2 traits.

Traits

Each hex type implements the following traits:

Dependencies

~0–780KB
~15K SLoC