pub struct Options<M, S>where
S: BuildHasher,{ /* private fields */ }
Expand description
Options for how to initialize the map.
In particular, the options dictate the hashing function, meta type, and initial capacity of the map.
Implementations§
Source§impl<M, S> Options<M, S>where
S: BuildHasher,
impl<M, S> Options<M, S>where
S: BuildHasher,
Sourcepub fn with_hasher<S2>(self, hash_builder: S2) -> Options<M, S2>where
S2: BuildHasher,
pub fn with_hasher<S2>(self, hash_builder: S2) -> Options<M, S2>where
S2: BuildHasher,
Set the hasher used for the map.
Sourcepub fn with_capacity(self, capacity: usize) -> Options<M, S>
pub fn with_capacity(self, capacity: usize) -> Options<M, S>
Set the initial capacity for the map.
Sourcepub fn construct<K, V>(
self,
) -> (ReadHandle<K, V, M, S>, WriteHandle<K, V, M, S>)
pub fn construct<K, V>( self, ) -> (ReadHandle<K, V, M, S>, WriteHandle<K, V, M, S>)
Create the map, and construct the read and write handles used to access it.
Trait Implementations§
Auto Trait Implementations§
impl<M, S> Freeze for Options<M, S>
impl<M, S> RefUnwindSafe for Options<M, S>where
M: RefUnwindSafe,
S: RefUnwindSafe,
impl<M, S> Send for Options<M, S>
impl<M, S> Sync for Options<M, S>
impl<M, S> Unpin for Options<M, S>
impl<M, S> UnwindSafe for Options<M, S>where
M: UnwindSafe,
S: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more