BinaryArrayOperator

Trait BinaryArrayOperator 

Source
pub trait BinaryArrayOperator {
    // Required methods
    fn act(
        &self,
        arg_one: ArrayView1<'_, R32>,
        arg_two: ArrayView1<'_, R32>,
    ) -> Array1<R32>;
    fn get_name(&self) -> String;
}
Expand description

Trait to ease implementation of primitive binary operators which have identical argument types and return type. To be used in tandem with BinaryFuncImpl.

Required Methods§

Source

fn act( &self, arg_one: ArrayView1<'_, R32>, arg_two: ArrayView1<'_, R32>, ) -> Array1<R32>

Given two arrays of equal dimension, act to yield an array of the same number of dimensions.

Source

fn get_name(&self) -> String

Gets the name of this binary operator

Trait Implementations§

Source§

impl Hash for dyn BinaryArrayOperator + '_

Source§

fn hash<H: Hasher>(&self, state: &mut H)

Feeds this value into the given Hasher. Read more
Source§

impl PartialEq for dyn BinaryArrayOperator + '_

Source§

fn eq(&self, other: &Self) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for dyn BinaryArrayOperator + '_

Implementors§