Trait rblas::vector::Vector [] [src]

pub trait Vector<T> {
    fn len(&self) -> c_int;
    fn as_ptr(&self) -> *const T;
    fn as_mut_ptr(&mut self) -> *mut T;

    fn inc(&self) -> c_int { ... }
}

Methods that allow a type to be used in BLAS functions as a vector.

Required Methods

fn len(&self) -> c_int

The number of elements in the vector.

fn as_ptr(&self) -> *const T

An unsafe pointer to a contiguous block of memory.

fn as_mut_ptr(&mut self) -> *mut T

An unsafe mutable pointer to a contiguous block of memory.

Provided Methods

fn inc(&self) -> c_int

The stride within the vector. For example, if inc returns 7, every 7th element is used. Defaults to 1.

Trait Implementations

impl<'a, T> Into<Vec<T>> for &'a Vector<T> where T: Copy

fn into(self) -> Vec<T>

impl<'a, T> Add for &'a Vector<T> where T: Axpy + Copy + Default

type Output = Vec<T>

fn add(self, x: &Vector<T>) -> Vec<T>

impl<'a, T> Mul<T> for &'a Vector<T> where T: Sized + Copy + Scal

type Output = Vec<T>

fn mul(self, alpha: T) -> Vec<T>

impl<'a, T> Mul<Trans<&'a Vector<T>>> for &'a Vector<T> where T: Default + Ger + Gerc + Clone

type Output = Mat<T>

fn mul(self, x: Trans<&Vector<T>>) -> Mat<T>

impl<'a, T> BitXor<Marker> for &'a Vector<T>

type Output = Trans<&'a Vector<T>>

fn bitxor(self, m: Marker) -> Trans<&'a Vector<T>>

Implementors