public class ForLoop extends Object
ForLoop.Body
is executed for each index combination of a given array of dimensions.
For example, given the dimensions {2, 3} (a 2D array) the body shall be called for the following sequence of indexes:
{0, 0} {0, 1} {0, 2} {1, 0} {1, 1} {1, 2}So higher indexes vary faster and correspond to inner loops. It is possible to execute multiple different bodies using the same for-loop instance.
Modifier and Type | Class and Description |
---|---|
static interface |
ForLoop.Body |
Constructor and Description |
---|
ForLoop(int[] sizes) |
Modifier and Type | Method and Description |
---|---|
ForLoop |
execute(ForLoop.Body body) |
static ForLoop |
execute(int[] sizes,
ForLoop.Body body) |
public static ForLoop execute(int[] sizes, ForLoop.Body body)
public ForLoop execute(ForLoop.Body body)
Copyright © 2014–2017 European Space Agency (ESA). All rights reserved.