Trait Random

Source
pub trait Random: Sized {
    // Required method
    fn random(rng: &mut impl CryptoRngCore) -> Self;
}
Expand description

Random number generation support.

Required Methods§

Source

fn random(rng: &mut impl CryptoRngCore) -> Self

Generate a cryptographically secure random value.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl Random for Limb

Source§

impl<MOD, const LIMBS: usize> Random for Residue<MOD, LIMBS>
where MOD: ResidueParams<LIMBS>,

Source§

impl<T> Random for NonZero<T>
where T: Random + Zero,

Source§

impl<T: Random> Random for Wrapping<T>

Source§

impl<const LIMBS: usize> Random for Uint<LIMBS>