Class FillLayer

java.lang.Object
com.trimblemaps.mapsdk.style.layers.Layer
com.trimblemaps.mapsdk.style.layers.FillLayer

@UiThread public class FillLayer extends Layer
A filled polygon with an optional stroked border.
  • Constructor Details

    • FillLayer

      public FillLayer(String layerId, String sourceId)
      Creates a FillLayer.
      Parameters:
      layerId - the id of the layer
      sourceId - the id of the source
  • Method Details

    • initialize

      protected void initialize(String layerId, String sourceId)
    • setSourceLayer

      public void setSourceLayer(String sourceLayer)
      Set the source layer.
      Parameters:
      sourceLayer - the source layer to set
    • withSourceLayer

      @NonNull public FillLayer withSourceLayer(String sourceLayer)
      Set the source Layer.
      Parameters:
      sourceLayer - the source layer to set
      Returns:
      This
    • getSourceId

      @NonNull public String getSourceId()
      Get the source id.
      Returns:
      id of the source
    • getSourceLayer

      @NonNull public String getSourceLayer()
      Get the source layer.
      Returns:
      sourceLayer the source layer to get
    • setFilter

      public void setFilter(@NonNull Expression filter)
      Set a single expression filter.
      Parameters:
      filter - the expression filter to set
    • withFilter

      @NonNull public FillLayer withFilter(@NonNull Expression filter)
      Set a single expression filter.
      Parameters:
      filter - the expression filter to set
      Returns:
      This
    • getFilter

      @Nullable public Expression getFilter()
      Get a single expression filter.
      Returns:
      the expression filter to get
    • withProperties

      @NonNull public FillLayer withProperties(@NonNull PropertyValue<?>... properties)
      Set a property or properties.
      Parameters:
      properties - the var-args properties
      Returns:
      This
    • getFillSortKey

      @NonNull public PropertyValue<Float> getFillSortKey()
      Get the FillSortKey property
      Returns:
      property wrapper value around Float
    • getFillAntialias

      @NonNull public PropertyValue<Boolean> getFillAntialias()
      Get the FillAntialias property
      Returns:
      property wrapper value around Boolean
    • getFillOpacity

      @NonNull public PropertyValue<Float> getFillOpacity()
      Get the FillOpacity property
      Returns:
      property wrapper value around Float
    • getFillOpacityTransition

      @NonNull public TransitionOptions getFillOpacityTransition()
      Get the FillOpacity property transition options
      Returns:
      transition options for Float
    • setFillOpacityTransition

      public void setFillOpacityTransition(@NonNull TransitionOptions options)
      Set the FillOpacity property transition options
      Parameters:
      options - transition options for Float
    • getFillColor

      @NonNull public PropertyValue<String> getFillColor()
      Get the FillColor property
      Returns:
      property wrapper value around String
    • getFillColorAsInt

      @ColorInt public int getFillColorAsInt()
      The color of the filled part of this layer. This color can be specified as `rgba` with an alpha component and the color's opacity will not affect the opacity of the 1px stroke, if it is used.
      Returns:
      int representation of a rgba string color
      Throws:
      RuntimeException - thrown if property isn't a value
    • getFillColorTransition

      @NonNull public TransitionOptions getFillColorTransition()
      Get the FillColor property transition options
      Returns:
      transition options for String
    • setFillColorTransition

      public void setFillColorTransition(@NonNull TransitionOptions options)
      Set the FillColor property transition options
      Parameters:
      options - transition options for String
    • getFillOutlineColor

      @NonNull public PropertyValue<String> getFillOutlineColor()
      Get the FillOutlineColor property
      Returns:
      property wrapper value around String
    • getFillOutlineColorAsInt

      @ColorInt public int getFillOutlineColorAsInt()
      The outline color of the fill. Matches the value of `fill-color` if unspecified.
      Returns:
      int representation of a rgba string color
      Throws:
      RuntimeException - thrown if property isn't a value
    • getFillOutlineColorTransition

      @NonNull public TransitionOptions getFillOutlineColorTransition()
      Get the FillOutlineColor property transition options
      Returns:
      transition options for String
    • setFillOutlineColorTransition

      public void setFillOutlineColorTransition(@NonNull TransitionOptions options)
      Set the FillOutlineColor property transition options
      Parameters:
      options - transition options for String
    • getFillTranslate

      @NonNull public PropertyValue<Float[]> getFillTranslate()
      Get the FillTranslate property
      Returns:
      property wrapper value around Float[]
    • getFillTranslateTransition

      @NonNull public TransitionOptions getFillTranslateTransition()
      Get the FillTranslate property transition options
      Returns:
      transition options for Float[]
    • setFillTranslateTransition

      public void setFillTranslateTransition(@NonNull TransitionOptions options)
      Set the FillTranslate property transition options
      Parameters:
      options - transition options for Float[]
    • getFillTranslateAnchor

      @NonNull public PropertyValue<String> getFillTranslateAnchor()
      Get the FillTranslateAnchor property
      Returns:
      property wrapper value around String
    • getFillPattern

      @NonNull public PropertyValue<String> getFillPattern()
      Get the FillPattern property
      Returns:
      property wrapper value around String
    • getFillPatternTransition

      @NonNull public TransitionOptions getFillPatternTransition()
      Get the FillPattern property transition options
      Returns:
      transition options for String
    • setFillPatternTransition

      public void setFillPatternTransition(@NonNull TransitionOptions options)
      Set the FillPattern property transition options
      Parameters:
      options - transition options for String
    • finalize

      protected void finalize() throws Throwable
      Overrides:
      finalize in class Layer
      Throws:
      Throwable