size_format only.Expand description
The module is responsible for the size of the data
Not activated by default Cargo.toml must be modified for activations
get_chunk = { version = "x.y.z", features = [
"size_format"
] }§Data Size Units for Convenient Size Specification
This module provides structures for dealing with data sizes in both the SI format (1000) and the IEC format (1024).
It includes constants for different size thresholds (e.g., kilobytes, megabytes), data structures representing various units of data size (SIUnit and IECUnit),
and methods for convenient conversion and display of data sizes in human-readable formats.
§SI Units and Sizes
SIUnit: Represents different units of data size in the SI format.SISize: Enum for SI data size categories (e.g., Byte, Kilobyte).
§IEC Units and Sizes
IECUnit: Represents different units of data size in the IEC format.IECSize: Enum for IEC data size categories (e.g., Byte, Kibibyte).
§Conversion between SI and IEC
The modules provide conversion functions (From implementations) between SI and IEC units, enabling seamless interoperability.
Note: These units are intended for convenient size specification and do not store the entire file in memory. Their purpose is to fetch data from files in human-readable formats during iterations or streams, especially for large datasets.
Modules§
- iec
- This module offers functionality for dealing with data sizes in the IEC format (1024)
- si
- This module offers functionality for dealing with data sizes in the SI format (1000)
Traits§
- Into
Enum Iterator - This trait designates that an
Enumcan be iterated over. It can be auto generated using theEnumIterderive macro.