Type Alias B16

Source
pub type B16 = FixedBytes<2>;
Expand description

2-byte fixed byte-array type.

Aliased Type§

struct B16(pub [u8; 2]);

Fields§

§0: [u8; 2]

Trait Implementations§

Source§

impl From<Signed<16, 1>> for B16

Source§

fn from(value: I16) -> Self

Converts a fixed-width unsigned integer into a fixed byte array by interpreting the bytes as big-endian.

Source§

impl From<Uint<16, 1>> for B16

Source§

fn from(value: U16) -> Self

Converts a fixed-width unsigned integer into a fixed byte array by interpreting the bytes as big-endian.

Source§

impl From<i16> for B16

Source§

fn from(value: i16) -> Self

Converts a fixed-width unsigned integer into a fixed byte array by interpreting the bytes as big-endian.

Source§

impl From<u16> for B16

Source§

fn from(value: u16) -> Self

Converts a fixed-width unsigned integer into a fixed byte array by interpreting the bytes as big-endian.

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.

Size: 2 bytes