Trait nv_card::MutableCollection
[−]
[src]
pub trait MutableCollection: Collection { fn push(&mut self, item: Self::Item); fn pop(&mut self) -> Option<Self::Item>; fn insert_at(&mut self, index: usize, item: Self::Item); fn remove_at(&mut self, index: usize) -> Option<Self::Item>; }
trait for collections that can be mutated. Inherits from Collection trait
Required Methods
fn push(&mut self, item: Self::Item)
adds an item to the end of a collection
fn pop(&mut self) -> Option<Self::Item>
removes an item from the end of a collection
fn insert_at(&mut self, index: usize, item: Self::Item)
inserts at a specific index
fn remove_at(&mut self, index: usize) -> Option<Self::Item>
removes item at a specific index
Implementors
impl<T> MutableCollection for Vec<T>
impl<T> MutableCollection for DuplicatesAllowedDeck<T>
impl<T> MutableCollection for NoDuplicatesDeck<T> where
T: PartialEq,