Trait peroxide::structure::dataframe::TypedVector
source · pub trait TypedVector<T> {
Show 15 methods
// Required methods
fn new(v: Vec<T>) -> Self;
fn to_vec(&self) -> Vec<T>;
fn as_slice(&self) -> &[T];
fn as_slice_mut(&mut self) -> &mut [T];
fn at_raw(&self, i: usize) -> T;
fn push(&mut self, elem: T);
fn map<F: Fn(T) -> T>(&self, f: F) -> Self;
fn mut_map<F: Fn(&mut T)>(&mut self, f: F);
fn fold<F: Fn(T, T) -> T>(&self, init: T, f: F) -> T;
fn filter<F: Fn(&T) -> bool>(&self, f: F) -> Self;
fn take(&self, n: usize) -> Self;
fn skip(&self, n: usize) -> Self;
fn take_while<F: Fn(&T) -> bool>(&self, f: F) -> Self;
fn skip_while<F: Fn(&T) -> bool>(&self, f: F) -> Self;
fn zip_with<F: Fn(T, T) -> T>(&self, f: F, other: &Self) -> Self;
}
Required Methods§
fn new(v: Vec<T>) -> Self
fn to_vec(&self) -> Vec<T>
fn as_slice(&self) -> &[T]
fn as_slice_mut(&mut self) -> &mut [T]
fn at_raw(&self, i: usize) -> T
fn push(&mut self, elem: T)
fn map<F: Fn(T) -> T>(&self, f: F) -> Self
fn mut_map<F: Fn(&mut T)>(&mut self, f: F)
fn fold<F: Fn(T, T) -> T>(&self, init: T, f: F) -> T
fn filter<F: Fn(&T) -> bool>(&self, f: F) -> Self
fn take(&self, n: usize) -> Self
fn skip(&self, n: usize) -> Self
fn take_while<F: Fn(&T) -> bool>(&self, f: F) -> Self
fn skip_while<F: Fn(&T) -> bool>(&self, f: F) -> Self
fn zip_with<F: Fn(T, T) -> T>(&self, f: F, other: &Self) -> Self
Object Safety§
This trait is not object safe.