Struct feanor_math::matrix::submatrix::Submatrix

source ·
pub struct Submatrix<'a, V, T>
where V: 'a + AsPointerToSlice<T>,
{ /* private fields */ }

Implementations§

source§

impl<'a, V, T> Submatrix<'a, V, T>
where V: 'a + AsPointerToSlice<T>,

source

pub fn submatrix(self, rows: Range<usize>, cols: Range<usize>) -> Self

source

pub fn restrict_rows(self, rows: Range<usize>) -> Self

source

pub fn at<'b>(&'b self, i: usize, j: usize) -> &'b T

source

pub fn restrict_cols(self, cols: Range<usize>) -> Self

source

pub fn row_iter(self) -> impl 'a + Clone + ExactSizeIterator<Item = &'a [T]>

source

pub fn col_iter( self ) -> impl 'a + Clone + ExactSizeIterator<Item = Column<'a, V, T>>

source

pub fn row_at<'b>(&'b self, i: usize) -> &'b [T]

source

pub fn col_at<'b>(&'b self, j: usize) -> Column<'b, V, T>

source

pub fn col_count(&self) -> usize

source

pub fn row_count(&self) -> usize

source§

impl<'a, V, T> Submatrix<'a, V, T>
where V: 'a + Sync + AsPointerToSlice<T>, T: Sync,

source

pub fn concurrent_row_iter(self) -> impl 'a + ExactSizeIterator<Item = &'a [T]>

source§

impl<'a, T> Submatrix<'a, AsFirstElement<T>, T>

source

pub fn new(data: &'a [T], row_count: usize, col_count: usize) -> Self

source§

impl<'a, T> Submatrix<'a, Vec<T>, T>

source

pub fn new(data: &'a [Vec<T>]) -> Self

source§

impl<'a, T, const N: usize> Submatrix<'a, [T; N], T>

source

pub fn new(data: &'a [[T; N]]) -> Self

Trait Implementations§

source§

impl<'a, V, T> Clone for Submatrix<'a, V, T>
where V: 'a + AsPointerToSlice<T>,

source§

fn clone(&self) -> Self

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<'a, V, R> Matrix<R> for Submatrix<'a, V, R::Element>
where V: 'a + AsPointerToSlice<R::Element>, R: RingBase,

source§

fn entry_at(&self, i: usize, j: usize) -> &<R as RingBase>::Element

source§

fn col_count(&self) -> usize

source§

fn row_count(&self) -> usize

source§

fn format<'a, S>(&'a self, ring: &'a S) -> MatrixDisplayWrapper<'a, R, Self>
where S: RingStore<Type = R>,

source§

fn matrix_eq<M, S>(&self, other: &M, ring: S) -> bool
where M: Matrix<R>, S: RingStore<Type = R>,

source§

impl<'a, V, T> Copy for Submatrix<'a, V, T>
where V: 'a + AsPointerToSlice<T>,

Auto Trait Implementations§

§

impl<'a, V, T> Freeze for Submatrix<'a, V, T>

§

impl<'a, V, T> RefUnwindSafe for Submatrix<'a, V, T>

§

impl<'a, V, T> Send for Submatrix<'a, V, T>
where V: Sync, T: Sync,

§

impl<'a, V, T> Sync for Submatrix<'a, V, T>
where V: Sync, T: Sync,

§

impl<'a, V, T> Unpin for Submatrix<'a, V, T>

§

impl<'a, V, T> UnwindSafe for Submatrix<'a, V, T>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.