Trait std::slice::ImmutableCloneableVector
pub trait ImmutableCloneableVector<T> { fn partitioned(&self, f: |&T| -> bool) -> (~[T], ~[T]); fn permutations(self) -> Permutations<T>; }
Extension methods for vectors containing Clone
elements.
Required Methods
fn partitioned(&self, f: |&T| -> bool) -> (~[T], ~[T])
Partitions the vector into two vectors (A,B)
, where all
elements of A
satisfy f
and all elements of B
do not.
fn permutations(self) -> Permutations<T>
Create an iterator that yields every possible permutation of the vector in succession.
Implementors
impl<'a, T: Clone> ImmutableCloneableVector<T> for &'a [T]