public class IterationCodeCursor extends AbstractLocalizable implements Cursor<Void>
Cursor<Void> that visits all positions in the bitmask encoded by a
given IterationCode.
It is constructed with a long[] offset which is not copied, so it can
be used to shift the bitmask and reuse this cursor.
positionn| Modifier | Constructor and Description |
|---|---|
protected |
IterationCodeCursor(IterationCodeCursor c) |
|
IterationCodeCursor(IterationCode iterationCode,
long[] offset) |
|
IterationCodeCursor(gnu.trove.list.array.TIntArrayList itcode,
long[] offset) |
| Modifier and Type | Method and Description |
|---|---|
IterationCodeCursor |
copy() |
IterationCodeCursor |
copyCursor() |
void |
fwd()
Move forward.
|
Void |
get()
Access the actual T instance providing access to a pixel,
sub-pixel or integral region value the
Sampler points at. |
boolean |
hasNext()
Returns true if another step forward is possible.
|
void |
jumpFwd(long steps)
Move steps × forward.
|
Void |
next() |
void |
reset()
Reset the
Iterator, that is put it to where it would be if newly
created. |
getDoublePosition, getFloatPosition, getIntPosition, getLongPosition, localize, localize, localize, localizenumDimensionsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemaining, removegetDoublePosition, getFloatPosition, getIntPosition, getLongPosition, localize, localize, localize, positionAsLongArray, positionAsPointlocalize, localize, localize, positionAsDoubleArray, positionAsRealPointnumDimensionspublic IterationCodeCursor(IterationCode iterationCode, long[] offset)
public IterationCodeCursor(gnu.trove.list.array.TIntArrayList itcode,
long[] offset)
protected IterationCodeCursor(IterationCodeCursor c)
public Void get()
SamplerSampler points at.public void jumpFwd(long steps)
Iteratorsteps - number of steps to move forwardpublic void fwd()
Iteratorpublic void reset()
IteratorIterator, that is put it to where it would be if newly
created.public boolean hasNext()
Iteratorpublic IterationCodeCursor copy()
copy in interface Sampler<Void>Sampler in the same state accessing the same
values.
It does NOT copy T, just the state of the Sampler.
Otherwise use T.copy() if available.
Sampler.copy().get() == Sampler.get(), i.e. both hold the same
value, not necessarily the same instance (this is the case for an
ArrayCursor for example)public IterationCodeCursor copyCursor()
copyCursor in interface Cursor<Void>copyCursor in interface RealCursor<Void>Copyright © 2015–2022 ImgLib2. All rights reserved.