Struct cosmian_crypto_core::Nonce
source · pub struct Nonce<const LENGTH: usize>(pub [u8; LENGTH]);
Expand description
Nonce object of the given size.
Internally, it uses an array of bytes of the given size.
Tuple Fields§
§0: [u8; LENGTH]
Implementations§
Trait Implementations§
source§impl<const LENGTH: usize> FixedSizeCBytes<LENGTH> for Nonce<LENGTH>
impl<const LENGTH: usize> FixedSizeCBytes<LENGTH> for Nonce<LENGTH>
source§fn try_from_bytes(bytes: [u8; LENGTH]) -> Result<Self, CryptoCoreError>
fn try_from_bytes(bytes: [u8; LENGTH]) -> Result<Self, CryptoCoreError>
Tries to create a key from the given array of bytes into a key.
source§fn try_from_slice(slice: &[u8]) -> Result<Self, CryptoCoreError>
fn try_from_slice(slice: &[u8]) -> Result<Self, CryptoCoreError>
Tries to create a key from the given slice of bytes into a key.
source§impl<const LENGTH: usize> PartialEq for Nonce<LENGTH>
impl<const LENGTH: usize> PartialEq for Nonce<LENGTH>
source§impl<const LENGTH: usize> RandomFixedSizeCBytes<LENGTH> for Nonce<LENGTH>
impl<const LENGTH: usize> RandomFixedSizeCBytes<LENGTH> for Nonce<LENGTH>
impl<const LENGTH: usize> CBytes for Nonce<LENGTH>
impl<const LENGTH: usize> Eq for Nonce<LENGTH>
impl<const LENGTH: usize> StructuralPartialEq for Nonce<LENGTH>
Auto Trait Implementations§
impl<const LENGTH: usize> Freeze for Nonce<LENGTH>
impl<const LENGTH: usize> RefUnwindSafe for Nonce<LENGTH>
impl<const LENGTH: usize> Send for Nonce<LENGTH>
impl<const LENGTH: usize> Sync for Nonce<LENGTH>
impl<const LENGTH: usize> Unpin for Nonce<LENGTH>
impl<const LENGTH: usize> UnwindSafe for Nonce<LENGTH>
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