Struct compactmap::CompactMap
[−]
[src]
pub struct CompactMap<V> { /* fields omitted */ }
Methods
impl<V> CompactMap<V>[src]
fn new() -> CompactMap<V>[src]
fn insert(&mut self, v: V) -> usize[src]
fn take(&mut self, i: usize) -> Option<V>[src]
fn remove(&mut self, i: usize)[src]
fn get(&self, i: usize) -> Option<&V>[src]
fn get_mut(&mut self, i: usize) -> Option<&mut V>[src]
Trait Implementations
impl<V: Clone> Clone for CompactMap<V>[src]
fn clone(&self) -> CompactMap<V>[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
Performs copy-assignment from source. Read more
impl<V> Default for CompactMap<V>[src]
fn default() -> CompactMap<V>[src]
Returns the "default value" for a type. Read more
impl<V> Hash for CompactMap<V> where
V: Hash, [src]
V: Hash,
fn hash<H>(&self, state: &mut H) where
H: Hasher, [src]
H: Hasher,
Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher]. Read more
impl<V> PartialEq<CompactMap<V>> for CompactMap<V> where
V: PartialEq<V>, [src]
V: PartialEq<V>,
fn eq(&self, other: &CompactMap<V>) -> bool[src]
This method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &Rhs) -> bool1.0.0[src]
This method tests for !=.
impl<V> Eq for CompactMap<V> where
V: Eq, [src]
V: Eq,
impl<V> PartialOrd<CompactMap<V>> for CompactMap<V> where
V: PartialOrd<V>, [src]
V: PartialOrd<V>,
fn partial_cmp(&self, other: &CompactMap<V>) -> Option<Ordering>[src]
This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool1.0.0[src]
This method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &Rhs) -> bool1.0.0[src]
This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, other: &Rhs) -> bool1.0.0[src]
This method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, other: &Rhs) -> bool1.0.0[src]
This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl<V> Ord for CompactMap<V> where
V: Ord, [src]
V: Ord,
fn cmp(&self, other: &CompactMap<V>) -> Ordering[src]
This method returns an Ordering between self and other. Read more
fn max(self, other: Self) -> Self[src]
ord_max_min)Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self[src]
ord_max_min)Compares and returns the minimum of two values. Read more
impl<V> FromIterator<V> for CompactMap<V>[src]
fn from_iter<I>(iter: I) -> CompactMap<V> where
I: IntoIterator<Item = V>, [src]
I: IntoIterator<Item = V>,
Creates a value from an iterator. Read more
impl<'a, V> FromIterator<&'a V> for CompactMap<V> where
V: Copy, [src]
V: Copy,
fn from_iter<I>(iter: I) -> CompactMap<V> where
I: IntoIterator<Item = &'a V>, [src]
I: IntoIterator<Item = &'a V>,
Creates a value from an iterator. Read more
impl<V> Extend<V> for CompactMap<V>[src]
fn extend<I>(&mut self, iter: I) where
I: IntoIterator<Item = V>, [src]
I: IntoIterator<Item = V>,
Extends a collection with the contents of an iterator. Read more
impl<'a, V> Extend<&'a V> for CompactMap<V> where
V: Copy, [src]
V: Copy,
fn extend<I>(&mut self, iter: I) where
I: IntoIterator<Item = &'a V>, [src]
I: IntoIterator<Item = &'a V>,
Extends a collection with the contents of an iterator. Read more
impl<V> Index<usize> for CompactMap<V>[src]
type Output = V
The returned type after indexing.
fn index(&self, i: usize) -> &V[src]
Performs the indexing (container[index]) operation.
impl<'a, V> Index<&'a usize> for CompactMap<V>[src]
type Output = V
The returned type after indexing.
fn index(&self, i: &usize) -> &V[src]
Performs the indexing (container[index]) operation.
impl<V> IndexMut<usize> for CompactMap<V>[src]
fn index_mut(&mut self, i: usize) -> &mut V[src]
Performs the mutable indexing (container[index]) operation.
impl<'a, V> IndexMut<&'a usize> for CompactMap<V>[src]
fn index_mut(&mut self, i: &usize) -> &mut V[src]
Performs the mutable indexing (container[index]) operation.
impl<V: Debug> Debug for CompactMap<V>[src]
impl<'a, V> IntoIterator for &'a CompactMap<V>[src]
type Item = (usize, &'a V)
The type of the elements being iterated over.
type IntoIter = ReadOnlyIter<'a, V>
Which kind of iterator are we turning this into?
fn into_iter(self) -> ReadOnlyIter<'a, V>[src]
Creates an iterator from a value. Read more
impl<'a, V: 'a> IntoIterator for &'a mut CompactMap<V>[src]
type Item = (usize, &'a mut V)
The type of the elements being iterated over.
type IntoIter = MutableIter<'a, V>
Which kind of iterator are we turning this into?
fn into_iter(self) -> MutableIter<'a, V>[src]
Creates an iterator from a value. Read more