public class GridReaderLayerHelper extends InfoToolHelper
contentRef, KEY_POSITION, layerRef
Constructor and Description |
---|
GridReaderLayerHelper() |
Modifier and Type | Method and Description |
---|---|
InfoToolResult |
getInfo(DirectPosition2D pos)
Gets layer data at the specified position.
|
boolean |
isSupportedLayer(Layer layer)
CAlled by the helper lookup system when selecting a helper for a given layer.
|
boolean |
isValid()
Checks if this helper is holding a reference to a
MapContent and a Layer .Helpers only hold a WeakReference to both the map content and layer to avoid
blocking garbage collection when layers are discarded. |
void |
setLayer(Layer layer)
Sets the map layer for this helper.
|
clearTransform, getContentToLayerTransform, getLayer, getMapContent, isTransformRequired, mapBoundsChanged, setMapContent
public boolean isSupportedLayer(Layer layer)
InfoToolHelper
isSupportedLayer
in class InfoToolHelper
layer
- the layertrue
is this helper can handle the layerpublic void setLayer(Layer layer)
InfoToolHelper
setLayer
in class InfoToolHelper
layer
- the map layerpublic boolean isValid()
InfoToolHelper
MapContent
and a Layer
.Helpers only hold a WeakReference
to both the map content and layer to avoid
blocking garbage collection when layers are discarded.isValid
in class InfoToolHelper
true
if both map content and layer references are validpublic InfoToolResult getInfo(DirectPosition2D pos) throws Exception
InfoToolHelper
InfoToolResult
object is returned.getInfo
in class InfoToolHelper
pos
- query positionException
- on error querying the layerCopyright © 1996–2019 Geotools. All rights reserved.