Trait ArrayIndexer

Source
pub trait ArrayIndexer<N> {
    // Required methods
    fn stride_from_local_point(shape: PointN<N>, point: Local<N>) -> Stride;
    fn make_stride_iter(
        array_shape: PointN<N>,
        origin: Local<N>,
        step: PointN<N>,
    ) -> ArrayStrideIter;
    fn for_each(for_each: ArrayForEach<N>, f: impl FnMut(PointN<N>, Stride));
    fn for_each_lockstep_unchecked(
        for_each: LockStepArrayForEach<N>,
        f: impl FnMut(PointN<N>, (Stride, Stride)),
    );

    // Provided method
    fn strides_from_local_points(
        shape: PointN<N>,
        points: &[Local<N>],
        strides: &mut [Stride],
    )
       where PointN<N>: Copy { ... }
}

Required Methods§

Source

fn stride_from_local_point(shape: PointN<N>, point: Local<N>) -> Stride

Source

fn make_stride_iter( array_shape: PointN<N>, origin: Local<N>, step: PointN<N>, ) -> ArrayStrideIter

Source

fn for_each(for_each: ArrayForEach<N>, f: impl FnMut(PointN<N>, Stride))

Source

fn for_each_lockstep_unchecked( for_each: LockStepArrayForEach<N>, f: impl FnMut(PointN<N>, (Stride, Stride)), )

Provided Methods§

Source

fn strides_from_local_points( shape: PointN<N>, points: &[Local<N>], strides: &mut [Stride], )
where PointN<N>: Copy,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl ArrayIndexer<[i32; 2]> for [i32; 2]

Source§

impl ArrayIndexer<[i32; 3]> for [i32; 3]

Implementors§