AllocatedArray

Trait AllocatedArray 

Source
pub trait AllocatedArray {
    type Elem;

    // Required methods
    fn layout(&self) -> Result<MatrixLayout, LinalgError>;
    fn square_layout(&self) -> Result<MatrixLayout, LinalgError>;
    fn ensure_square(&self) -> Result<(), LinalgError>;
    fn as_allocated(&self) -> Result<&[Self::Elem], LinalgError>;
}

Required Associated Types§

Required Methods§

Source

fn layout(&self) -> Result<MatrixLayout, LinalgError>

Source

fn square_layout(&self) -> Result<MatrixLayout, LinalgError>

Source

fn ensure_square(&self) -> Result<(), LinalgError>

Returns Ok iff the matrix is square (without computing the layout).

Source

fn as_allocated(&self) -> Result<&[Self::Elem], LinalgError>

Implementors§

Source§

impl<A, S> AllocatedArray for ArrayBase<S, Dim<[usize; 2]>>
where S: Data<Elem = A>,

Source§

type Elem = A