Struct alga::general::Wrapper
[−]
[src]
pub struct Wrapper<M>(pub M);
Wrapper that allows to use operators on algebraic types.
Trait Implementations
impl<M: Clone> Clone for Wrapper<M>[src]
fn clone(&self) -> Wrapper<M>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0
Performs copy-assignment from source. Read more
impl<M: Copy> Copy for Wrapper<M>[src]
impl<M: PartialOrd> PartialOrd for Wrapper<M>[src]
fn partial_cmp(&self, __arg_0: &Wrapper<M>) -> Option<Ordering>
This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, __arg_0: &Wrapper<M>) -> bool
This method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, __arg_0: &Wrapper<M>) -> bool
This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, __arg_0: &Wrapper<M>) -> bool
This method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, __arg_0: &Wrapper<M>) -> bool
This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl<M: PartialEq> PartialEq for Wrapper<M>[src]
fn eq(&self, __arg_0: &Wrapper<M>) -> bool
This method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, __arg_0: &Wrapper<M>) -> bool
This method tests for !=.
impl<M: Debug> Debug for Wrapper<M>[src]
impl<M: Display> Display for Wrapper<M>[src]
fn fmt(&self, fmt: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter.
impl<M> ApproxEq for Wrapper<M> where M: ApproxEq[src]
type Eps = M::Eps
The epsilon type used measure an error.
fn default_epsilon() -> Self::Eps
The default epsilon value to use in ApproxEq::approx_eq.
fn approx_eq_eps(&self, b: &Self, epsilon: &Self::Eps) -> bool
Compare a and b for approximate equality using the specified epsilon value. Read more
fn approx_eq(&self, b: &Self) -> bool
Compare a and b for approximate equality using the default epsilon value returned by ApproxEq::default_epsilon. Read more
impl<M> Add<Wrapper<M>> for Wrapper<M> where M: Magma<Additive>[src]
type Output = Self
The resulting type after applying the + operator
fn add(self, lhs: Self) -> Self
The method for the + operator
impl<M> Neg for Wrapper<M> where M: Quasigroup<Additive>[src]
type Output = Self
The resulting type after applying the - operator
fn neg(self) -> Self
The method for the unary - operator
impl<M> Sub<Wrapper<M>> for Wrapper<M> where M: Quasigroup<Additive>[src]
type Output = Self
The resulting type after applying the - operator
fn sub(self, lhs: Self) -> Self
The method for the - operator
impl<M> Mul<Wrapper<M>> for Wrapper<M> where M: Magma<Multiplicative>[src]
type Output = Self
The resulting type after applying the * operator
fn mul(self, lhs: Self) -> Self
The method for the * operator