Expand description
Human-friendly bandwidth parser and formatter
§Facilities:
- Parses bandwidth in free form like
2Gbps 340Mbps
or2.34Gbps
- Formats bandwidth in similar form
150.024kbps
(default) or150kbps 24bps
(with featuredisplay-integer
enabled)
§Features
- Enable
serde
feature for serde integration. - Enable
display-integer
feature to display integer values only.
Modules§
- option
- Convenience module to allow serialization for
Option
- re
- Reexport module
- serde
- Serde support for humanized bandwidth.
Structs§
- Formatted
Bandwidth - A wrapper type that allows you to Display a Bandwidth
Enums§
- Error
- Error parsing human-friendly bandwidth
Functions§
- format_
bandwidth - Formats bandwidth into a human-readable string
- parse_
bandwidth - Parse bandwidth object
1Gbps 12Mbps 5bps
or1.012000005Gbps