public final class RectangularRegion3D extends AbstractRectangularRegion implements HjRegion.HjRegion3D
RectangularRegion3D class.
HjRegion.HjRegion1D, HjRegion.HjRegion2D, HjRegion.HjRegion3D
Modifier and Type | Field and Description |
---|---|
protected int |
maxInc0 |
protected int |
maxInc1 |
protected int |
maxInc2 |
protected int |
minInc0 |
protected int |
minInc1 |
protected int |
minInc2 |
protected int |
range0 |
protected int |
range1 |
protected int |
range2 |
Modifier | Constructor and Description |
---|---|
protected |
RectangularRegion3D(int pMinInc0,
int pMaxInc0,
int pMinInc1,
int pMaxInc1,
int pMinInc2,
int pMaxInc2)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Iterator<HjPoint> |
iterator()
Returns an iterator over an int array whose length is specified by the rank.
|
Iterator<HjPoint> |
iterator(int startLinearIndex,
int maxNumItems)
Returns an iterator over an int array whose length is specified by the rank.
|
int |
lowerLimit(int index)
Returns the lower limit of the region at the specified dimension.
|
int[] |
lowerLimits() |
int |
numElements()
Returns the number of elements in the iteration space defined by the region.
|
int |
rank()
Returns the rank of the region.
|
int |
toLinearIndex(int[] regionIndices)
Returns the zero-based linear index in the 1D array.
|
int |
toLinearIndex(int regionIndex0,
int regionIndex1,
int regionIndex2) |
int[] |
toRegionIndex(int linearIndex)
Return the region based index of the linear index.
|
Iterable<HjPoint> |
toSeqIterable()
The HjPoint object returned by the iterator may be reused by the iterator in subsequent calls to next().
|
String |
toString() |
int |
upperLimit(int index)
Returns the upper limits of the region at the specified dimension.
|
int[] |
upperLimits() |
createIterator
protected final int minInc0
protected final int maxInc0
protected final int minInc1
protected final int maxInc1
protected final int minInc2
protected final int maxInc2
protected final int range0
protected final int range1
protected final int range2
protected RectangularRegion3D(int pMinInc0, int pMaxInc0, int pMinInc1, int pMaxInc1, int pMinInc2, int pMaxInc2)
pMinInc0
- a int.pMaxInc0
- a int.pMinInc1
- a int.pMaxInc1
- a int.pMinInc2
- a int.pMaxInc2
- a int.public Iterable<HjPoint> toSeqIterable()
toSeqIterable
in interface HjRegion
public Iterator<HjPoint> iterator()
public Iterator<HjPoint> iterator(int startLinearIndex, int maxNumItems)
public int rank()
public int numElements()
numElements
in interface HjRegion
public int lowerLimit(int index)
lowerLimit
in interface HjRegion
public int upperLimit(int index)
upperLimit
in interface HjRegion
public int[] toRegionIndex(int linearIndex)
toRegionIndex
in interface HjRegion
linearIndex
- The zero-based linear index in the 1D arraypublic int toLinearIndex(int[] regionIndices)
toLinearIndex
in interface HjRegion
toLinearIndex
in interface HjRegion.HjRegion3D
regionIndices
- The region based index.public int toLinearIndex(int regionIndex0, int regionIndex1, int regionIndex2)
toLinearIndex
in interface HjRegion.HjRegion3D
regionIndex0
- The region index for the first dimension.regionIndex1
- The region index for the second dimension.regionIndex2
- The region index for the third dimension.public int[] lowerLimits()
lowerLimits
in interface HjRegion.HjRegion3D
public int[] upperLimits()
upperLimits
in interface HjRegion.HjRegion3D
Copyright © 2015 Rice University - Department of Computer Science. All rights reserved.