public class HDF5MDEnumBlock
extends java.lang.Object
Enum
data set block by block, using
natural data blocks. The Natural block for chunked data sets is a chunk, for
non-chunked data sets it is the complete array.
The pattern for using this class is:
for (HDF5MDEnumBlock block : reader.getEnumMDNaturalBlocks(dsNameMD)) { HDF5EnumerationValueMDArray naturalBlock = block.getData(); ... work on naturalBlock, use block.getIndex() or block.getOffset() where needed ... }The iteration in the multi-dimensional case will be in C-order, that is last-index is iterated over first.
Note: If the size of the data set is not an integer number of blocks, then the last block will be smaller than the natural block size.
Modifier and Type | Method and Description |
---|---|
HDF5EnumerationValueMDArray |
getData()
Returns the data block itself.
|
long[] |
getIndex()
Returns the iteration index of this block, starting with
{ 0, ..., 0 } . |
long[] |
getOffset()
Returns the offset in the data set for the current iteration in each dimension.
|
public HDF5EnumerationValueMDArray getData()
public long[] getOffset()
public long[] getIndex()
{ 0, ..., 0 }
.