pub enum Entry<'a, K: Hash + Ord, V> {
Vacant(VacantEntry<'a, K, V>),
Occupied(OccupiedEntry<'a, K, V>),
}Expand description
A mutable reference to a position in the map. This can be used to reference, add, or update the value at a fixed key.
This is not exported to bindings users as bindings provide alternate accessors rather than exposing maps directly.
Variants§
Vacant(VacantEntry<'a, K, V>)
A mutable reference to a position within the map where there is no value.
Occupied(OccupiedEntry<'a, K, V>)
A mutable reference to a position within the map where there is currently a value.
Auto Trait Implementations§
impl<'a, K, V> Freeze for Entry<'a, K, V>where
K: Freeze,
impl<'a, K, V> RefUnwindSafe for Entry<'a, K, V>where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<'a, K, V> Send for Entry<'a, K, V>
impl<'a, K, V> Sync for Entry<'a, K, V>
impl<'a, K, V> Unpin for Entry<'a, K, V>where
K: Unpin,
impl<'a, K, V> !UnwindSafe for Entry<'a, K, V>
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