pub struct ChainingHashTable<K, V> { /* private fields */ }Implementations§
Source§impl<K: Hash + Debug + PartialEq, V: PartialEq + Clone> ChainingHashTable<K, V>
impl<K: Hash + Debug + PartialEq, V: PartialEq + Clone> ChainingHashTable<K, V>
Sourcepub fn new() -> ChainingHashTable<K, V>
pub fn new() -> ChainingHashTable<K, V>
Creates a new HashTable
Sourcepub fn put(&mut self, key: K, value: V)
pub fn put(&mut self, key: K, value: V)
Adds entry (k, v), overwriting any value v associated with an
existing key k, returns old value. Resizes the map which the
table encounters a load factor >.75.
Sourcepub fn values(&self) -> Vec<&V>
pub fn values(&self) -> Vec<&V>
Returns an iterable collection of all values in the map, including repeats for multiple key-value associations
Sourcepub fn entry_set(&self) -> Vec<&Entry<K, V>>
pub fn entry_set(&self) -> Vec<&Entry<K, V>>
Returns an iterable collection of all (k, v) entries in the map
Trait Implementations§
Auto Trait Implementations§
impl<K, V> Freeze for ChainingHashTable<K, V>
impl<K, V> RefUnwindSafe for ChainingHashTable<K, V>where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for ChainingHashTable<K, V>
impl<K, V> Sync for ChainingHashTable<K, V>
impl<K, V> Unpin for ChainingHashTable<K, V>
impl<K, V> UnwindSafe for ChainingHashTable<K, V>where
K: UnwindSafe,
V: 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