[−][src]Crate randomize
Simple and minimalist randomization library.
NOT FOR CRYPTOGRAPHIC PURPOSES.
Usage
You should make a PCG32 value, and then generally you'll call methods
from the Gen32 trait:
use randomize::{Gen32, PCG32}; let mut g = PCG32::seed(5, 6); println!("rolling 1d6: {}", g.dice(1, 6));
Cargo Features
getrandom: adds thefrom_getrandommethod to thePCG32type, which makes a new generator from OS randomness. This depends on the getrandom crate.
Structs
| BoundedRandU32 | Stores the values to sample a number in |
| ExplodingDie | Stores data for an "exploding" 1 through |
| PCG32 | A permuted congruential generator with 32 bits of output per step. |
| StandardDie | Stores data for a standard 1 through |
Traits
| Gen32 | For random number generators with a primary output of |