pub struct KeyId {
bytes: [u8; 8],
len: usize,
}Expand description
Key identifier
Fields§
§bytes: [u8; 8]Byte array
len: usizeLength of byte array
Implementations§
Source§impl KeyId
impl KeyId
Sourcepub fn new(slice: &[u8]) -> Result<Self>
pub fn new(slice: &[u8]) -> Result<Self>
Create a new KeyId from a slice.
§Errors
Returns Error::KeyIdTooLong in event the provided slice is too long.
Trait Implementations§
Source§impl Ord for KeyId
impl Ord for KeyId
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
Source§impl PartialOrd for KeyId
impl PartialOrd for KeyId
impl Copy for KeyId
impl Eq for KeyId
impl StructuralPartialEq for KeyId
Auto Trait Implementations§
impl Freeze for KeyId
impl RefUnwindSafe for KeyId
impl Send for KeyId
impl Sync for KeyId
impl Unpin for KeyId
impl UnsafeUnpin for KeyId
impl UnwindSafe for KeyId
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