[−][src]Struct abstutil::MultiMap
Fields
map: BTreeMap<K, BTreeSet<V>>
empty: BTreeSet<V>
Implementations
impl<K, V> MultiMap<K, V> where
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
[src]
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
pub fn new() -> MultiMap<K, V>
[src]
pub fn insert(&mut self, key: K, value: V)
[src]
pub fn remove(&mut self, key: K, value: V)
[src]
pub fn get(&self, key: K) -> &BTreeSet<V>
[src]
pub fn set(&mut self, key: K, values: BTreeSet<V>)
[src]
pub fn len(&self) -> usize
[src]
pub fn borrow(&self) -> &BTreeMap<K, BTreeSet<V>>
[src]
pub fn consume(self) -> BTreeMap<K, BTreeSet<V>>
[src]
Trait Implementations
impl<K: Clone, V: Clone> Clone for MultiMap<K, V> where
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
[src]
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
impl<K, V> Default for MultiMap<K, V> where
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
[src]
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
impl<K: PartialEq, V: PartialEq> PartialEq<MultiMap<K, V>> for MultiMap<K, V> where
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
[src]
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
impl<K, V> StructuralPartialEq for MultiMap<K, V> where
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
[src]
K: Ord + PartialEq + Clone,
V: Ord + PartialEq + Clone,
Auto Trait Implementations
impl<K, V> RefUnwindSafe for MultiMap<K, V> where
K: RefUnwindSafe,
V: RefUnwindSafe,
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for MultiMap<K, V> where
K: Send,
V: Send,
K: Send,
V: Send,
impl<K, V> Sync for MultiMap<K, V> where
K: Sync,
V: Sync,
K: Sync,
V: Sync,
impl<K, V> Unpin for MultiMap<K, V> where
K: Unpin,
V: Unpin,
K: Unpin,
V: Unpin,
impl<K, V> UnwindSafe for MultiMap<K, V> where
K: RefUnwindSafe + UnwindSafe,
V: RefUnwindSafe + UnwindSafe,
K: RefUnwindSafe + UnwindSafe,
V: RefUnwindSafe + UnwindSafe,
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> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
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>,