[−][src]Struct smoke::R
A pseudo random generator at a given time
it can created from seed using R::from_seed
, or
from another pseudo random generator using .sub()
as to create a hierarchy (or a tree) of generator.
Implementations
impl R
[src]
pub fn new() -> (Seed, Self)
[src]
pub fn sub(&mut self) -> Self
[src]
pub fn from_seed(seed: Seed) -> Self
[src]
pub fn next_bytes(&mut self, buf: &mut [u8])
[src]
pub fn ascii(&mut self) -> char
[src]
pub fn codepoint(&mut self) -> char
[src]
pub fn bool(&mut self) -> bool
[src]
pub fn num<T: NumPrimitive>(&mut self) -> T
[src]
pub fn num_range<T: NumPrimitive>(&mut self, min_value: T, max_value: T) -> T
[src]
pub fn array_num<T: NumPrimitive>(&mut self, buf: &mut [T])
[src]
pub fn array_num_range<T: NumPrimitive>(
&mut self,
min_value: T,
max_value: T,
buf: &mut [T]
)
[src]
&mut self,
min_value: T,
max_value: T,
buf: &mut [T]
)
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,