Class FeatureLayerHelper

    • Field Detail


        public static final double DEFAULT_DISTANCE_FRACTION
        Default distance fraction used with line and point features. When the user clicks on the map, this tool searches for features within a rectangle of width w centred on the mouse location, where w is the average map side length multiplied by the value of this constant.
        See Also:
        Constant Field Values
    • Constructor Detail

      • FeatureLayerHelper

        public FeatureLayerHelper()
        No argument constructor required by the helper lookup system.
    • Method Detail

      • setLayer

        public void setLayer​(Layer layer)
        Sets the map layer for this helper. The layer argument must be an instance of FeatureLayer.
        setLayer in class InfoToolHelper
        layer - the map layer
      • isSupportedLayer

        public boolean isSupportedLayer​(Layer layer)
        Description copied from class: InfoToolHelper
        Called by the helper lookup system when selecting a helper for a given layer.
        Specified by:
        isSupportedLayer in class InfoToolHelper
        layer - the layer
        true is this helper can handle the layer
      • getInfo

        public InfoToolResult getInfo​(Position2D pos)
                               throws Exception
        Description copied from class: InfoToolHelper
        Gets layer data at the specified position. If there are no feature data at the position, an empty InfoToolResult object is returned.
        Specified by:
        getInfo in class InfoToolHelper
        pos - query position
        layer data
        Exception - on error querying the layer