Class CircleManager

java.lang.Object
com.trimblemaps.mapsdk.plugins.annotation.AnnotationManager<com.trimblemaps.mapsdk.style.layers.CircleLayer,Circle,CircleOptions,OnCircleDragListener,OnCircleClickListener,OnCircleLongClickListener>
com.trimblemaps.mapsdk.plugins.annotation.CircleManager

public class CircleManager extends AnnotationManager<com.trimblemaps.mapsdk.style.layers.CircleLayer,Circle,CircleOptions,OnCircleDragListener,OnCircleClickListener,OnCircleLongClickListener>
The circle manager allows to add circles to a map.
  • Constructor Details

    • CircleManager

      @UiThread public CircleManager(@NonNull com.trimblemaps.mapsdk.maps.MapView mapView, @NonNull com.trimblemaps.mapsdk.maps.TrimbleMapsMap trimbleMapsMap, @NonNull com.trimblemaps.mapsdk.maps.Style style)
      Create a circle manager, used to manage circles.
      Parameters:
      trimbleMapsMap - the map object to add circles to
      style - a valid a fully loaded style object
    • CircleManager

      @UiThread public CircleManager(@NonNull com.trimblemaps.mapsdk.maps.MapView mapView, @NonNull com.trimblemaps.mapsdk.maps.TrimbleMapsMap trimbleMapsMap, @NonNull com.trimblemaps.mapsdk.maps.Style style, @Nullable String belowLayerId)
      Create a circle manager, used to manage circles.
      Parameters:
      trimbleMapsMap - the map object to add circles to
      style - a valid a fully loaded style object
      belowLayerId - the id of the layer above the circle layer
    • CircleManager

      @UiThread public CircleManager(@NonNull com.trimblemaps.mapsdk.maps.MapView mapView, @NonNull com.trimblemaps.mapsdk.maps.TrimbleMapsMap trimbleMapsMap, @NonNull com.trimblemaps.mapsdk.maps.Style style, @Nullable String belowLayerId, @Nullable com.trimblemaps.mapsdk.style.sources.GeoJsonOptions geoJsonOptions)
      Create a circle manager, used to manage circles.
      Parameters:
      trimbleMapsMap - the map object to add circles to
      style - a valid a fully loaded style object
      belowLayerId - the id of the layer above the circle layer
      geoJsonOptions - options for the internal source
  • Method Details

    • setDataDrivenPropertyIsUsed

      protected void setDataDrivenPropertyIsUsed(@NonNull String property)
      Specified by:
      setDataDrivenPropertyIsUsed in class AnnotationManager<com.trimblemaps.mapsdk.style.layers.CircleLayer,Circle,CircleOptions,OnCircleDragListener,OnCircleClickListener,OnCircleLongClickListener>
    • create

      @UiThread public List<Circle> create(@NonNull String json)
      Create a list of circles on the map.

      Circles are going to be created only for features with a matching geometry.

      All supported properties are:
      CircleOptions.PROPERTY_CIRCLE_RADIUS - Float
      CircleOptions.PROPERTY_CIRCLE_COLOR - String
      CircleOptions.PROPERTY_CIRCLE_BLUR - Float
      CircleOptions.PROPERTY_CIRCLE_OPACITY - Float
      CircleOptions.PROPERTY_CIRCLE_STROKE_WIDTH - Float
      CircleOptions.PROPERTY_CIRCLE_STROKE_COLOR - String
      CircleOptions.PROPERTY_CIRCLE_STROKE_OPACITY - Float

      Out of spec properties:
      "is-draggable" - Boolean, true if the circle should be draggable, false otherwise

      Parameters:
      json - the GeoJSON defining the list of circles to build
      Returns:
      the list of built circles
    • create

      @UiThread public List<Circle> create(@NonNull com.trimblemaps.geojson.FeatureCollection featureCollection)
      Create a list of circles on the map.

      Circles are going to be created only for features with a matching geometry.

      All supported properties are:
      CircleOptions.PROPERTY_CIRCLE_RADIUS - Float
      CircleOptions.PROPERTY_CIRCLE_COLOR - String
      CircleOptions.PROPERTY_CIRCLE_BLUR - Float
      CircleOptions.PROPERTY_CIRCLE_OPACITY - Float
      CircleOptions.PROPERTY_CIRCLE_STROKE_WIDTH - Float
      CircleOptions.PROPERTY_CIRCLE_STROKE_COLOR - String
      CircleOptions.PROPERTY_CIRCLE_STROKE_OPACITY - Float

      Out of spec properties:
      "is-draggable" - Boolean, true if the circle should be draggable, false otherwise

      Parameters:
      featureCollection - the featureCollection defining the list of circles to build
      Returns:
      the list of built circles
    • getCircleTranslate

      public Float[] getCircleTranslate()
      Get the CircleTranslate property

      The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.

      Returns:
      property wrapper value around Float[]
    • setCircleTranslate

      public void setCircleTranslate(Float[] value)
      Set the CircleTranslate property

      The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.

      Parameters:
      value - property wrapper value around Float[]
    • getCircleTranslateAnchor

      public String getCircleTranslateAnchor()
      Get the CircleTranslateAnchor property

      Controls the frame of reference for PropertyFactory.circleTranslate(java.lang.Float[]).

      Returns:
      property wrapper value around String
    • setCircleTranslateAnchor

      public void setCircleTranslateAnchor(String value)
      Set the CircleTranslateAnchor property

      Controls the frame of reference for PropertyFactory.circleTranslate(java.lang.Float[]).

      Parameters:
      value - property wrapper value around String
    • getCirclePitchScale

      public String getCirclePitchScale()
      Get the CirclePitchScale property

      Controls the scaling behavior of the circle when the map is pitched.

      Returns:
      property wrapper value around String
    • setCirclePitchScale

      public void setCirclePitchScale(String value)
      Set the CirclePitchScale property

      Controls the scaling behavior of the circle when the map is pitched.

      Parameters:
      value - property wrapper value around String
    • getCirclePitchAlignment

      public String getCirclePitchAlignment()
      Get the CirclePitchAlignment property

      Orientation of circle when map is pitched.

      Returns:
      property wrapper value around String
    • setCirclePitchAlignment

      public void setCirclePitchAlignment(String value)
      Set the CirclePitchAlignment property

      Orientation of circle when map is pitched.

      Parameters:
      value - property wrapper value around String
    • setFilter

      public void setFilter(@NonNull com.trimblemaps.mapsdk.style.expressions.Expression expression)
      Set filter on the managed circles.
      Parameters:
      expression - expression
    • getFilter

      @Nullable public com.trimblemaps.mapsdk.style.expressions.Expression getFilter()
      Get filter of the managed circles.
      Returns:
      expression