T
- the parameterization lower bounded by Array
itself.E
- the component type.public interface Array<T extends Array<T,E>,E> extends Cloneable
Modifier and Type | Interface and Description |
---|---|
static interface |
Array.IndexingOrder
An enumeration of internal storage orders for
Array s. |
Modifier and Type | Method and Description |
---|---|
T |
clone()
Copies this array.
|
T |
concat(int opDim,
T... srcs)
Concatenates this array with the given arrays along the given dimension.
|
int[] |
dims()
Gets the dimensions.
|
Class<E> |
getComponentType()
Gets the component type.
|
T |
map(T dst,
int... bounds)
Maps this array into a destination array.
|
int |
nDims()
Gets the number of dimensions.
|
Array.IndexingOrder |
order()
Gets the storage order of this array.
|
T |
reshape(int... dims)
Reshapes this array.
|
T |
reverse(int... opDims)
Reverses along the given dimensions.
|
T |
reverseOrder()
Creates an array where the storage order is reversed.
|
T |
shift(int... shifts)
Circularly shifts this array.
|
int |
size(int i)
Gets the size along the given dimension.
|
T |
slice(E value,
int[]... srcSlices)
Slices a value into this array.
|
T |
slice(int[]... srcSlices)
Gets a subarray specified by the given slicing indices.
|
T |
slice(int[][] srcSlices,
T dst,
int[][] dstSlices)
Slices this array into a destination array.
|
T |
slice(T dst,
int[]... dstSlices)
Slices this entire array into a destination array.
|
T |
splice(T dst,
int... slices)
A primitive slicing operation.
|
int |
stride(int i)
Gets the stride along the given dimension.
|
int[] |
strides()
Gets the strides.
|
T |
subarray(int... bounds)
Gets a subarray delimited by the given bounds.
|
T |
tile(int... repetitions)
Tiles this array according to the given number repetitions along each dimension.
|
String |
toString()
Creates a human-readable representation of this array.
|
T |
transpose(int... permutation)
Transposes (permutes) the dimensions of this array.
|
Array.IndexingOrder order()
int size(int i)
int stride(int i)
int nDims()
int[] dims()
int[] strides()
T map(T dst, int... bounds)
dst
- the destination array.bounds
- the mapping bounds as an array of three-tuples. Given the i
th tuple, the first component
denotes the source start, the second component denotes the destination start, and the third component
denotes the mapping size. Is very much the multidimensional analogy to
System.arraycopy(Object, int, Object, int, int)
.T splice(T dst, int... slices)
dst
- the destination array.slices
- the slicing specifications as an array of three-tuples. Given the i
th tuple, the first
component denotes the source index, the second component denotes the destination index, and the third
component denotes the dimension of interest. The sliced portion is the Cartesian product subarray
delineated by these specifications.T slice(int[][] srcSlices, T dst, int[][] dstSlices)
srcSlices
- the source slicing indices along each dimension.dst
- the destination array.dstSlices
- the destination slicing indices along each dimension.T slice(T dst, int[]... dstSlices)
dst
- the destination array.dstSlices
- the destination slicing indices along each dimension.T slice(E value, int[]... srcSlices)
value
- the value.srcSlices
- the source slicing indices along each dimension.T slice(int[]... srcSlices)
srcSlices
- the slicing indices.T subarray(int... bounds)
bounds
- the subarray bounds as an array of two-tuples. Given the i
th tuple, the first component
is the (inclusive) lower range and the second component is the (exclusive) upper range.T tile(int... repetitions)
repetitions
- the number times to repeat along each dimension.T transpose(int... permutation)
permutation
- the dimension permutation.T shift(int... shifts)
shifts
- the shift amounts.T reshape(int... dims)
dims
- the reshaped dimensions.T reverse(int... opDims)
opDims
- the dimensions to reverse along.T concat(int opDim, T... srcs)
opDim
- the dimension to concatenate along.srcs
- the arrays to concatenate with.T reverseOrder()
T clone()