public class ChunkingScheme extends java.lang.Object implements java.lang.Iterable<ChunkPosition>
ChunkingScheme
class describes an overall set of chunks
that fill an n-dimensional space and allows for iteration over the set.
Chunks are all of equal size, except for some chunks at the edges of the
space which may be truncated due to the global dimensions.Constructor and Description |
---|
ChunkingScheme(long[] dims,
long[] chunkSize)
Creates a new chunking scheme.
|
Modifier and Type | Method and Description |
---|---|
int |
getChunkCount()
Gets the total count of chunks in this scheme.
|
long[] |
getChunkSize()
Gets the size of chunks in this scheme.
|
long[] |
getDims()
Gets the global dimensions of the chunking scheme.
|
java.util.Iterator<ChunkPosition> |
iterator() |
public ChunkingScheme(long[] dims, long[] chunkSize)
dims
- the global dimensions of the n-dimensional chunk space.chunkSize
- the size of each chunk in the space (some chunks may be
truncated).public long[] getDims()
public long[] getChunkSize()
public java.util.Iterator<ChunkPosition> iterator()
iterator
in interface java.lang.Iterable<ChunkPosition>
public int getChunkCount()