public class FunctionCursor<C extends RealType<C>,O extends RealType<O>> extends AbstractCursor<O>
| Modifier and Type | Field and Description |
|---|---|
protected Cursor<?> |
cursor |
protected OFunction<C> |
f |
protected Converter<RealType<?>,C> |
inConverter |
protected IFunction |
operation |
protected Converter<C,O> |
outConverter |
protected Sampler<O> |
sampler |
protected C |
scrapC |
protected O |
scrapO |
n| Constructor and Description |
|---|
FunctionCursor(IFunction operation,
Converter<RealType<?>,C> inConverter,
C computeType,
O outputType,
Converter<C,O> outConverter) |
| Modifier and Type | Method and Description |
|---|---|
AbstractCursor<O> |
copy() |
AbstractCursor<O> |
copyCursor() |
void |
fwd() |
O |
get()
Access the actual T instance providing access to a pixel,
sub-pixel or integral region value the
Sampler points at. |
long |
getLongPosition(int d)
Return the current position in a given dimension.
|
boolean |
hasNext() |
void |
localize(long[] position)
Write the current position into the passed array.
|
void |
reset() |
getDoublePosition, getFloatPosition, getIntPosition, jumpFwd, localize, localize, localize, next, remove, toStringnumDimensionsclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEachRemaininglocalize, positionAsLongArray, positionAsPointlocalize, positionAsDoubleArray, positionAsRealPointnumDimensionspublic FunctionCursor(IFunction operation, Converter<RealType<?>,C> inConverter, C computeType, O outputType, Converter<C,O> outConverter)
operation - inConverter - Can be null, and if so, a generic Util#genericRealTypeConverter() will be used.computeType - outputType - outConverter - Can be null, and if so, a generic integer or real converter will be used.public final O get()
SamplerSampler points at.public void fwd()
public final boolean hasNext()
public void reset()
public long getLongPosition(int d)
Localizabled - dimensionpublic void localize(long[] position)
Localizableposition - receives current positionpublic AbstractCursor<O> copy()
copy in interface Sampler<O extends RealType<O>>copy in class AbstractCursor<O extends RealType<O>>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 AbstractCursor<O> copyCursor()
copyCursor in interface Cursor<O extends RealType<O>>copyCursor in interface RealCursor<O extends RealType<O>>copyCursor in class AbstractCursor<O extends RealType<O>>Copyright © 2015–2022 ImgLib2. All rights reserved.