org.eclipse.january.dataset

## Class StrideIterator

- java.lang.Object
- - org.eclipse.january.dataset.IndexIterator
  - - org.eclipse.january.dataset.SliceIterator
    - - org.eclipse.january.dataset.StrideIterator

-     public class StrideIterator
      extends SliceIterator

  Class to run over a contiguous dataset using strides

- - ### Field Summary

    - ### Fields inherited from class org.eclipse.january.dataset.IndexIterator

      `index`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StrideIterator(int[] shape)`
    `StrideIterator(int[] shape, int[] strides)`
    `StrideIterator(int[] shape, int[] strides, int offset)`
    `StrideIterator(int isize, int[] shape)`
    `StrideIterator(int isize, int[] shape, int[] strides, int offset)`
    `StrideIterator(int isize, int[] shape, int[] start, int[] stop, int[] step)`
    `StrideIterator(int isize, int[] shape, int[] strides, int offset, int element)`
    `StrideIterator(int isize, int[] shape, int[] oStrides, int oOffset, int[] start, int[] stop, int[] step)`
    `StrideIterator(int isize, int[] shape, int[] oStrides, int oOffset, SliceND slice)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `int[]` | `getPos()`
    `int[]` | `getShape()`
    `boolean` | `hasNext()`
    `void` | `reset()` Reset iterator

    - ### Methods inherited from class org.eclipse.january.dataset.SliceIterator

      `getStart, getStep, setStart`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### StrideIterator

          public StrideIterator(int[] shape)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape)

    - #### StrideIterator

          public StrideIterator(int[] shape,
                        int[] strides)

    - #### StrideIterator

          public StrideIterator(int[] shape,
                        int[] strides,
                        int offset)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape,
                        int[] strides,
                        int offset)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape,
                        int[] strides,
                        int offset,
                        int element)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape,
                        int[] start,
                        int[] stop,
                        int[] step)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape,
                        int[] oStrides,
                        int oOffset,
                        int[] start,
                        int[] stop,
                        int[] step)

    - #### StrideIterator

          public StrideIterator(int isize,
                        int[] shape,
                        int[] oStrides,
                        int oOffset,
                        SliceND slice)

  - ### Method Detail

    - #### getShape

          public int[] getShape()

      Overrides:
        `getShape` in class `SliceIterator`
      Returns:
        shape of iterator (can be null, if not known or applicable)

    - #### hasNext

          public boolean hasNext()

      Overrides:
        `hasNext` in class `SliceIterator`
      Returns:
        true if there is another iteration

    - #### getPos

          public int[] getPos()

      Overrides:
        `getPos` in class `SliceIterator`
      Returns:
        position indices (nb this is reference not a copy so avoid changing and can be null)

    - #### reset

          public void reset()

      Description copied from class: `IndexIterator`
      Reset iterator
      Overrides:
        `reset` in class `SliceIterator`

Copyright © 2017. All rights reserved.