Function rufl::random::string

source ·
pub fn string(length: usize) -> String
Expand description

Generate random string.

§Arguments

  • length - The char size of random string.

§Returns

Returns random string with specific length.

§Examples

use rufl::random;

let random_str = random::string(6);

println!("{}", random_str);
assert_eq!(6, random_str.len());