pub struct Layout {
pub field_low: u32,
pub field_mid: u16,
pub field_high_and_version: u16,
pub clock_seq_high_and_reserved: u8,
pub clock_seq_low: u8,
pub node: Node,
}
Expand description
The UUID format is 16 octets.
Fields§
§field_low: u32
The low field of the Timestamp.
field_mid: u16
The mid field of the Timestamp.
field_high_and_version: u16
The high field of the Timestamp multiplexed with the version number.
clock_seq_high_and_reserved: u8
The high field of the ClockSeq multiplexed with the variant.
clock_seq_low: u8
The low field of the ClockSeq.
node: Node
IEEE 802 MAC-address.
Implementations§
Source§impl Layout
impl Layout
Sourcepub const fn get_timestamp(&self) -> u64
Available on crate feature mac_addr
only.
pub const fn get_timestamp(&self) -> u64
mac_addr
only.Get timestamp where the UUID generated in
Sourcepub const fn get_mac_addr(&self) -> Node
Available on crate feature mac_addr
only.
pub const fn get_mac_addr(&self) -> Node
mac_addr
only.Get the MAC-address where the UUID generated with
Source§impl Layout
impl Layout
Sourcepub fn be_fields(&self) -> (u32, u16, u16, u16, Node)
pub fn be_fields(&self) -> (u32, u16, u16, u16, Node)
Returns the five field values of the UUID in big-endian order.
Sourcepub fn as_fields(&self) -> (u32, u16, u16, u16, Node)
pub fn as_fields(&self) -> (u32, u16, u16, u16, Node)
Returns the five field values of the UUID in little-endian order.
Sourcepub fn be_bytes(&self) -> UUID
pub fn be_bytes(&self) -> UUID
Return the memory representation of the UUID in big-endian order .
Sourcepub fn as_bytes(&self) -> UUID
pub fn as_bytes(&self) -> UUID
Return the memory representation of the UUID in little-endian order .
Sourcepub const fn get_version(&self) -> Option<Version>
pub const fn get_version(&self) -> Option<Version>
Version of the current generated UUID.
Sourcepub const fn get_variant(&self) -> Option<Variant>
pub const fn get_variant(&self) -> Option<Variant>
Variant field of the current generated UUID.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Layout
impl RefUnwindSafe for Layout
impl Send for Layout
impl Sync for Layout
impl Unpin for Layout
impl UnwindSafe for Layout
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more