Trait extendr_api::prelude::mat::MatIndex

pub trait MatIndex<RowRange, ColRange>: Sized + Seal {
    type Target;

    // Required method
    fn get(this: Self, row: RowRange, col: ColRange) -> Self::Target;

    // Provided method
    unsafe fn get_unchecked(
        this: Self,
        row: RowRange,
        col: ColRange,
    ) -> Self::Target { ... }
}
Expand description

Represents a type that can be used to slice a matrix, such as an index or a range of indices.

Required Associated Types§

type Target

Resulting type of the indexing operation.

Required Methods§

fn get(this: Self, row: RowRange, col: ColRange) -> Self::Target

Index the matrix at (row, col).

Provided Methods§

unsafe fn get_unchecked( this: Self, row: RowRange, col: ColRange, ) -> Self::Target

Index the matrix at (row, col), without bound checks.

Object Safety§

This trait is not object safe.

Implementors§

§

impl<'a, E> MatIndex<usize, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = <<E as Entity>::Group as ForType>::FaerOf<&'a mut <E as Entity>::Unit>

§

impl<'a, E> MatIndex<usize, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = <<E as Entity>::Group as ForType>::FaerOf<&'a <E as Entity>::Unit>

§

impl<'a, E> MatIndex<usize, Range<usize>> for MatMut<'a, E>
where E: Entity,

§

type Target = RowMut<'a, E>

§

impl<'a, E> MatIndex<usize, Range<usize>> for MatRef<'a, E>
where E: Entity,

§

type Target = RowRef<'a, E>

§

impl<'a, E> MatIndex<Range<usize>, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<Range<usize>, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<'a, E> MatIndex<RangeFrom<usize>, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<RangeFrom<usize>, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<'a, E> MatIndex<RangeFull, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<RangeFull, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<'a, E> MatIndex<RangeInclusive<usize>, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<RangeInclusive<usize>, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<'a, E> MatIndex<RangeTo<usize>, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<RangeTo<usize>, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<'a, E> MatIndex<RangeToInclusive<usize>, usize> for MatMut<'a, E>
where E: Entity,

§

type Target = ColMut<'a, E>

§

impl<'a, E> MatIndex<RangeToInclusive<usize>, usize> for MatRef<'a, E>
where E: Entity,

§

type Target = ColRef<'a, E>

§

impl<E> MatIndex<Range<usize>, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<Range<usize>, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E> MatIndex<RangeFrom<usize>, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<RangeFrom<usize>, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E> MatIndex<RangeFull, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<RangeFull, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E> MatIndex<RangeInclusive<usize>, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<RangeInclusive<usize>, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E> MatIndex<RangeTo<usize>, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<RangeTo<usize>, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E> MatIndex<RangeToInclusive<usize>, Range<usize>> for MatMut<'_, E>
where E: Entity,

§

type Target = MatMut<'_, E>

§

impl<E> MatIndex<RangeToInclusive<usize>, Range<usize>> for MatRef<'_, E>
where E: Entity,

§

type Target = MatRef<'_, E>

§

impl<E, RowRange> MatIndex<RowRange, RangeFrom<usize>> for MatMut<'_, E>
where E: Entity, MatMut<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatMut<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeFrom<usize>> for MatRef<'_, E>
where E: Entity, MatRef<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatRef<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeFull> for MatMut<'_, E>
where E: Entity, MatMut<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatMut<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeFull> for MatRef<'_, E>
where E: Entity, MatRef<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatRef<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeInclusive<usize>> for MatMut<'_, E>
where E: Entity, MatMut<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatMut<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeInclusive<usize>> for MatRef<'_, E>
where E: Entity, MatRef<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatRef<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeTo<usize>> for MatMut<'_, E>
where E: Entity, MatMut<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatMut<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeTo<usize>> for MatRef<'_, E>
where E: Entity, MatRef<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatRef<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeToInclusive<usize>> for MatMut<'_, E>
where E: Entity, MatMut<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatMut<'_, E> as MatIndex<RowRange, Range<usize>>>::Target

§

impl<E, RowRange> MatIndex<RowRange, RangeToInclusive<usize>> for MatRef<'_, E>
where E: Entity, MatRef<'_, E>: MatIndex<RowRange, Range<usize>>,

§

type Target = <MatRef<'_, E> as MatIndex<RowRange, Range<usize>>>::Target