pub struct Rng { /* private fields */ }
Expand description
Random number generator
Implementations§
source§impl Rng
impl Rng
pub fn new() -> Self
pub fn set_sequence(&mut self, initseq: u64)
pub fn uniform_uint32(&mut self) -> u32
pub fn uniform_uint32_bounded(&mut self, b: u32) -> u32
pub fn uniform_float(&mut self) -> Float
Trait Implementations§
impl Copy for Rng
Auto Trait Implementations§
impl RefUnwindSafe for Rng
impl Send for Rng
impl Sync for Rng
impl Unpin for Rng
impl UnwindSafe for Rng
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
source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for Pwhere
R: Read + ReadEndian<P>,
P: Default,
impl<R, P> ReadPrimitive<R> for Pwhere R: Read + ReadEndian<P>, P: Default,
source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian()
.