[][src]Struct serenity::utils::VecMap

pub struct VecMap<K, V>(_);

Like HashMap but solely uses a vector instead.

note: This is for internal use.

Methods

impl<K: PartialEq, V> VecMap<K, V>[src]

pub fn new() -> Self[src]

pub fn with_capacity(cap: usize) -> Self[src]

pub fn insert(&mut self, key: K, value: V)[src]

pub fn remove<Q: ?Sized + PartialEq<K>>(&mut self, key: &Q) -> Option<V>[src]

pub fn entry(&mut self, key: K) -> Entry<K, V>[src]

pub fn get<Q: PartialEq<K> + ?Sized>(&self, key: &Q) -> Option<&V>[src]

pub fn iter(&self) -> Iter<(K, V)>[src]

Trait Implementations

impl<K: Default, V: Default> Default for VecMap<K, V>[src]

impl<K: Clone, V: Clone> Clone for VecMap<K, V>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<K, V> IntoIterator for VecMap<K, V>[src]

type Item = (K, V)

The type of the elements being iterated over.

type IntoIter = IntoIter<(K, V)>

Which kind of iterator are we turning this into?

impl<'a, K, V> IntoIterator for &'a VecMap<K, V>[src]

type Item = &'a (K, V)

The type of the elements being iterated over.

type IntoIter = Iter<'a, (K, V)>

Which kind of iterator are we turning this into?

impl<K: Debug, V: Debug> Debug for VecMap<K, V>[src]

Auto Trait Implementations

impl<K, V> Send for VecMap<K, V> where
    K: Send,
    V: Send

impl<K, V> Sync for VecMap<K, V> where
    K: Sync,
    V: Sync

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Erased for T

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Err = <U as TryFrom<T>>::Err

impl<T> DebugAny for T where
    T: Any + Debug
[src]

impl<T> CloneAny for T where
    T: Clone + Any
[src]

impl<T> UnsafeAny for T where
    T: Any