public interface StructureAnyD extends Structure1D
| Modifier and Type | Interface and Description |
|---|---|
static class |
StructureAnyD.IntReference |
static class |
StructureAnyD.LongReference |
static interface |
StructureAnyD.ReducibleTo1D<R extends Structure1D> |
static interface |
StructureAnyD.ReducibleTo2D<R extends Structure2D> |
static interface |
StructureAnyD.ReferenceCallback |
static class |
StructureAnyD.ReferenceMapper |
Structure1D.BasicMapper<T>, Structure1D.IndexCallback, Structure1D.IndexMapper<T>, Structure1D.IntIndex, Structure1D.LongIndex, Structure1D.LoopCallback| Modifier and Type | Method and Description |
|---|---|
default long |
count()
count() == count(0) * count(1) * count(2) * count(3) * ...
|
long |
count(int dimension) |
static int |
count(int[] structure) |
static int |
count(int[] structure,
int dimension) |
static long |
count(long[] structure) |
static long |
count(long[] structure,
int dimension) |
static int |
index(int[] structure,
int[] reference) |
static int |
index(int[] structure,
long[] reference) |
static long |
index(long[] structure,
long[] reference) |
default void |
loop(int dimension,
long dimensionalIndex,
Structure1D.LoopCallback callback)
Will loop through this multidimensional data structure so that one index value of one dimension is
fixed.
|
default void |
loop(long[] initial,
int dimension,
Structure1D.LoopCallback callback) |
default void |
loop(Predicate<long[]> filter,
Structure1D.IndexCallback callback) |
default void |
loopAll(StructureAnyD.ReferenceCallback callback) |
static void |
loopMatching(StructureAnyD structureA,
StructureAnyD structureB,
Structure1D.IndexCallback callback) |
static StructureAnyD.ReferenceMapper |
mapperOf(StructureAnyD structure,
Structure1D.IndexMapper<Object>[] mappers) |
default int |
rank() |
static long[] |
reference(long index,
long[] structure) |
long[] |
shape() |
static long[] |
shape(StructureAnyD structure) |
static int |
step(int[] structure,
int dimension) |
static int |
step(int[] structure,
int[] increment)
A more complex/general version of step(int[], int).
|
static long |
step(long[] structure,
int dimension)
How does the index change when stepping to the next dimensional unit (next row, next column.
|
static long |
step(long[] structure,
long[] increment)
A more complex/general version of step(int[], int).
|
loopAll, loopMatching, loopRange, mapperstatic StructureAnyD.ReferenceMapper mapperOf(StructureAnyD structure, Structure1D.IndexMapper<Object>[] mappers)
static int count(int[] structure)
structure - An access structurestatic int count(int[] structure,
int dimension)
structure - An access structuredimension - A dimension indexstatic long count(long[] structure)
structure - An access structurestatic long count(long[] structure,
int dimension)
structure - An access structuredimension - A dimension indexstatic int index(int[] structure,
int[] reference)
structure - An access structurereference - An access element referencestatic int index(int[] structure,
long[] reference)
structure - An access structurereference - An access element referencestatic long index(long[] structure,
long[] reference)
structure - An access structurereference - An access element referencestatic void loopMatching(StructureAnyD structureA, StructureAnyD structureB, Structure1D.IndexCallback callback)
static long[] reference(long index,
long[] structure)
static long[] shape(StructureAnyD structure)
static int step(int[] structure,
int dimension)
structure - An access structuredimension - A dimension index indication a directionstatic int step(int[] structure,
int[] increment)
structure - An access structureincrement - A vector indication a direction (and size)static long step(long[] structure,
int dimension)
structure - An access structuredimension - Which reference index to incrementstatic long step(long[] structure,
long[] increment)
structure - An access structureincrement - A vector indication a direction (and size)default long count()
count in interface Structure1Dlong count(int dimension)
default void loop(int dimension,
long dimensionalIndex,
Structure1D.LoopCallback callback)
dimension - The dimension with a fixed/supplied index. (0==row, 1==column, 2=matrix/area...)dimensionalIndex - The index value that dimension is fixed to. (Which row, column or matrix/area)callback - A callback with parameters that define a sub-loopdefault void loop(long[] initial,
int dimension,
Structure1D.LoopCallback callback)
default void loop(Predicate<long[]> filter, Structure1D.IndexCallback callback)
default void loopAll(StructureAnyD.ReferenceCallback callback)
default int rank()
long[] shape()
Copyright © 2018 Optimatika. All rights reserved.