public interface Sampler<T>
The Sampler
interface provides access to a value whose type is
specified by the generic parameter T. This T may point to an actual
Object
as stored in a Collection
, a proxy Object
that
allows reading and writing pixel data of an image (e.g. all
NativeTypes
), or a proxy Object
whose content is
generated otherwise and may only be readable (e.g. ShapeList2D).
Modifier and Type | Method and Description |
---|---|
Sampler<T> |
copy() |
T |
get()
Access the actual T instance providing access to a pixel,
sub-pixel or integral region value the
Sampler points at. |
T get()
Sampler
points at.Sampler<T> copy()
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)Copyright © 2015–2022 ImgLib2. All rights reserved.