Interface LayerContent

    • Method Detail

      • canChangeVisibility

        boolean canChangeVisibility()
        Returns whether or not we can change the visibility of this layer.
        Returns:
        true if we can change this layer's visibility, false otherwise
        Since:
        100.0.0
      • isVisible

        boolean isVisible()
        Returns whether this layer is visible or not.
        Returns:
        true if the layer is visible, false otherwise
        Since:
        100.0.0
      • setVisible

        void setVisible​(boolean isVisible)
        Sets the layer's visibility if canChangeVisibility() returns true.
        Parameters:
        isVisible - true to make the layer visible, false to hide it
        Since:
        100.0.0
      • canShowInLegend

        boolean canShowInLegend()
        Returns whether or not this layer will be listed in the legend.
        Returns:
        true if this layer will be visible in the legend, false otherwise
        Since:
        100.0.0
      • setCanShowInLegend

        void setCanShowInLegend​(boolean canShowInLegend)
        Sets whether or not this layer should be visible in the legend.
        Parameters:
        canShowInLegend - true to show in the legend, false to omit it from the legend
        Since:
        100.0.0
      • getName

        String getName()
        Gets the name of this layer.
        Returns:
        name of this layer
        Since:
        100.0.0
      • getSubLayerContents

        ListenableList<LayerContent> getSubLayerContents()
        Returns a list of sub layers, if any. If there are no sub-layers, an empty list will be returned. This list cannot be used to add or remove sub-layers.
        Returns:
        a read only list of sub-layers, if any
        Since:
        100.0.0
      • fetchLegendInfosAsync

        ListenableFuture<List<LegendInfo>> fetchLegendInfosAsync()
        Asynchronously fetches legend information for this layer, if any.
        Returns:
        a listenable future that can be used to get the legend information
        Since:
        100.0.0
      • isVisibleAtScale

        boolean isVisibleAtScale​(double scale)
        Returns whether or not this layer will be visible at the given scale.
        Parameters:
        scale - will the layer be visible at this scale?
        Returns:
        true if the layer will be visible at the given scale, false otherwise
        Since:
        100.0.0