Struct std::collections::hash_map::RandomState 1.7.0[−][src]
pub struct RandomState { /* fields omitted */ }Expand description
RandomState is the default state for HashMap types.
A particular instance RandomState will create the same instances of
Hasher, but the hashers created by two different RandomState
instances are unlikely to produce the same result for the same values.
Examples
use std::collections::HashMap; use std::collections::hash_map::RandomState; let s = RandomState::new(); let mut map = HashMap::with_hasher(s); map.insert(1, 2);Run
Implementations
Trait Implementations
type Hasher = DefaultHasher
type Hasher = DefaultHasherType of the hasher that will be created.
Creates a new hasher. Read more
Constructs a new RandomState.
Auto Trait Implementations
impl RefUnwindSafe for RandomStateimpl Send for RandomStateimpl Sync for RandomStateimpl Unpin for RandomStateimpl UnwindSafe for RandomStateBlanket Implementations
Mutably borrows from an owned value. Read more