pub struct DeviceUid(/* private fields */);Expand description
The 16-byte unique identifier of an MX Remote device on the network.
The default value is the empty (all-zero) UID.
Implementations§
Source§impl DeviceUid
impl DeviceUid
Sourcepub const fn from_array(raw: [u8; 16]) -> Self
pub const fn from_array(raw: [u8; 16]) -> Self
Builds a UID from its raw 16 bytes.
Sourcepub fn from_bytes(b: &[u8]) -> Result<Self, UidParseError>
pub fn from_bytes(b: &[u8]) -> Result<Self, UidParseError>
Builds a UID from raw bytes.
An empty slice yields DeviceUid::ZERO; any other length shorter than
16 is an error. Trailing bytes past the first 16 are ignored.
Trait Implementations§
impl Copy for DeviceUid
impl Eq for DeviceUid
Source§impl Ord for DeviceUid
impl Ord for DeviceUid
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialOrd for DeviceUid
impl PartialOrd for DeviceUid
impl StructuralPartialEq for DeviceUid
Auto Trait Implementations§
impl Freeze for DeviceUid
impl RefUnwindSafe for DeviceUid
impl Send for DeviceUid
impl Sync for DeviceUid
impl Unpin for DeviceUid
impl UnsafeUnpin for DeviceUid
impl UnwindSafe for DeviceUid
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