HeatmapStyleLayer class
final
Constructors
-
HeatmapStyleLayer({required String id, required String sourceId, String? sourceLayerId, double minZoom = 0, double maxZoom = 24, Expression<bool>? filter, bool visible = true, Expression<num>? radius, StyleTransition? radiusTransition, Expression<num>? weight, Expression<num>? intensity, StyleTransition? intensityTransition, Expression<Color>? color, Expression<num>? opacity, StyleTransition? opacityTransition})
-
Creates a HeatmapStyleLayer that is not on a map yet.
-
HeatmapStyleLayer.fromJson(Map<String, Object?> json)
-
Reads a HeatmapStyleLayer from the JSON of a style layer.
Properties
-
color
↔ Expression<Color>
-
Defines the color of each pixel based on its density value in a heatmap.
Should be an expression that uses
["heatmap-density"] as input.
getter/setter pair
-
filter
↔ Expression<bool>?
-
The condition on source features. Only features that match it are shown.
Zoom expressions in filters are only evaluated at integer zoom levels,
and the
feature-state expression is not supported in them.
getter/setter pairinherited
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
id
→ String
-
The unique name of the layer.
finalinherited
-
intensity
↔ Expression<num>
-
Similar to
heatmap-weight
but controls the intensity of the heatmap globally. Primarily used for
adjusting the heatmap based on zoom level.
getter/setter pair
-
intensityTransition
↔ StyleTransition?
-
How intensity changes to a new value.
getter/setter pair
-
maxZoom
↔ double
-
The maximum zoom level of the layer. At and above it, the layer is
hidden.
getter/setter pairinherited
-
minZoom
↔ double
-
The minimum zoom level of the layer. Below it, the layer is hidden.
getter/setter pairinherited
-
opacity
↔ Expression<num>
-
The global opacity at which the heatmap layer will be drawn.
getter/setter pair
-
opacityTransition
↔ StyleTransition?
-
How opacity changes to a new value.
getter/setter pair
-
radius
↔ Expression<num>
-
Radius of influence of one heatmap point in pixels. Increasing the value
makes the heatmap smoother, but less detailed.
getter/setter pair
-
radiusTransition
↔ StyleTransition?
-
How radius changes to a new value.
getter/setter pair
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
-
sourceId
→ String
-
The id of the source of this layer.
finalinherited
-
sourceLayerId
→ String?
-
The layer to use from a vector tile source. Required for vector tile
sources; prohibited for all other source types, including GeoJSON sources.
finalinherited
-
type
→ String
-
The type of the layer in the style spec, such as
line.
no setteroverride
-
visible
↔ bool
-
Whether the layer is shown.
getter/setter pairinherited
-
weight
↔ Expression<num>
-
A measure of how much an individual point contributes to the heatmap. A
value of 10 would be equivalent to having 10 points of weight 1 in the same
spot. Especially useful when combined with clustering.
getter/setter pair
Methods
-
moveBelow(String? layerId)
→ void
-
Moves this layer below the layer
layerId, or to the top if it is null.
See StyleLayers.move.
inherited
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson()
→ Map<String, Object?>
-
The layer as the JSON of a style layer.
inherited
-
toString()
→ String
-
A string representation of this object.
inherited
-
updateFrom(StyleLayer other)
→ void
-
Sets every property of this layer that differs from
other and leaves
the rest alone. Only the changes reach the map.
inherited