Expand description
random string generation.
salps provides a minimal api for creating silly randomly
generated strings of not particularly high quality.
§usage
use core::fmt::Write;
// first bring a type that implements `core::fmt::Write`
let mut string = String::new();
// then bring an rng generator (you will probably have
// to implement this crate's `Random` trait yourself)
let mut rng = Rng::new();
// and finally, create a configuration, or use the default:
let config = salps::Config::new();
// now generate a word!
salps::word(&mut string, &mut rng, &config)?;Structs§
- Config
- configuration for this crate.
Constants§
- DEFAULT_
END - default configuration used in
Config. - DEFAULT_
END_ FALLBACK - default configuration used in
Config. - DEFAULT_
MID - default configuration used in
Config. - DEFAULT_
MID_ FALLBACK - default configuration used in
Config.
Traits§
- Random
- trait for providing random numbers.