zng::layout

Trait ByteUnits

Source
pub trait ByteUnits {
    // Required methods
    fn bytes(self) -> ByteLength;
    fn kibibytes(self) -> ByteLength;
    fn kilobytes(self) -> ByteLength;
    fn mebibytes(self) -> ByteLength;
    fn megabytes(self) -> ByteLength;
    fn gibibytes(self) -> ByteLength;
    fn gigabytes(self) -> ByteLength;
    fn tebibytes(self) -> ByteLength;
    fn terabytes(self) -> ByteLength;
}
Expand description

Extension methods for initializing ByteLength values.

Required Methods§

Source

fn bytes(self) -> ByteLength

Bytes.

See ByteLength for more details.

Source

fn kibibytes(self) -> ByteLength

Kibi-bytes.

See ByteLength::from_kibi for more details.

Source

fn kilobytes(self) -> ByteLength

Kilo-bytes.

See ByteLength::from_kilo for more details.

Source

fn mebibytes(self) -> ByteLength

Mebi-bytes.

See ByteLength::from_mebi for more details.

Source

fn megabytes(self) -> ByteLength

Mega-bytes.

See ByteLength::from_mega for more details.

Source

fn gibibytes(self) -> ByteLength

Gibi-bytes.

See ByteLength::from_gibi for more details.

Source

fn gigabytes(self) -> ByteLength

Giga-bytes.

See ByteLength::from_giga for more details.

Source

fn tebibytes(self) -> ByteLength

Tebi-bytes.

See ByteLength::from_tebi for more details.

Source

fn terabytes(self) -> ByteLength

Tera-bytes.

See ByteLength::from_tera for more details.

Implementations on Foreign Types§

Source§

impl ByteUnits for usize

Implementors§