[−][src]Struct ordered_multimap::list_ordered_multimap::VacantEntry
A view into a vacant entry in the multimap.
Methods
impl<'map, Key, Value, State> VacantEntry<'map, Key, Value, State> where
Key: Eq + Hash,
State: BuildHasher,
[src]
Key: Eq + Hash,
State: BuildHasher,
pub fn insert(self, value: Value) -> &'map mut Value
[src]
Examples
use ordered_multimap::ListOrderedMultimap; use ordered_multimap::list_ordered_multimap::Entry; let mut map = ListOrderedMultimap::new(); let mut entry = match map.entry("key") { Entry::Vacant(entry) => entry, _ => panic!("expected vacant entry") }; assert_eq!(entry.insert("value"), &"value");
pub fn insert_entry(self, value: Value) -> OccupiedEntry<'map, Key, Value>
[src]
Examples
use ordered_multimap::ListOrderedMultimap; use ordered_multimap::list_ordered_multimap::Entry; let mut map = ListOrderedMultimap::new(); let mut entry = match map.entry("key") { Entry::Vacant(entry) => entry, _ => panic!("expected vacant entry") }; let mut entry = entry.insert_entry("value"); assert_eq!(entry.get(), &"value");
pub fn into_key(self) -> Key
[src]
Examples
use ordered_multimap::ListOrderedMultimap; use ordered_multimap::list_ordered_multimap::Entry; let mut map: ListOrderedMultimap<&str, &str> = ListOrderedMultimap::new(); let mut entry = match map.entry("key") { Entry::Vacant(entry) => entry, _ => panic!("expected vacant entry") }; assert_eq!(entry.into_key(), "key");
pub fn key(&self) -> &Key
[src]
Examples
use ordered_multimap::ListOrderedMultimap; use ordered_multimap::list_ordered_multimap::Entry; let mut map: ListOrderedMultimap<&str, &str> = ListOrderedMultimap::new(); let mut entry = match map.entry("key") { Entry::Vacant(entry) => entry, _ => panic!("expected vacant entry") }; assert_eq!(entry.key(), &"key");
Trait Implementations
impl<'_, Key, Value, State> Debug for VacantEntry<'_, Key, Value, State> where
Key: Debug,
[src]
Key: Debug,
Auto Trait Implementations
impl<'map, Key, Value, State> RefUnwindSafe for VacantEntry<'map, Key, Value, State> where
Key: RefUnwindSafe,
State: RefUnwindSafe,
Value: RefUnwindSafe,
Key: RefUnwindSafe,
State: RefUnwindSafe,
Value: RefUnwindSafe,
impl<'map, Key, Value, State> Send for VacantEntry<'map, Key, Value, State> where
Key: Send,
State: Sync,
Value: Send,
Key: Send,
State: Sync,
Value: Send,
impl<'map, Key, Value, State> Sync for VacantEntry<'map, Key, Value, State> where
Key: Sync,
State: Sync,
Value: Sync,
Key: Sync,
State: Sync,
Value: Sync,
impl<'map, Key, Value, State> Unpin for VacantEntry<'map, Key, Value, State> where
Key: Unpin,
Key: Unpin,
impl<'map, Key, Value, State = RandomState> !UnwindSafe for VacantEntry<'map, Key, Value, State>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,