MarkerIcon class sealed

The image of the markers of a layer, which the map adds to the style for it, see Layer.icon.

The map adds each image once, for every layer that shows it, removes it once no layer shows it, and adds it again when another style loads. Layers share an image when their icons are equal.

Annotations

Constructors

MarkerIcon.asset(String path, {double pixelRatio})
The image of the Flutter asset path, with pixelRatio image pixels per logical pixel, see StyleController.addImage.
const
factory
MarkerIcon.bytes(Uint8List bytes, {double pixelRatio})
The encoded image bytes, such as a PNG, with pixelRatio image pixels per logical pixel, see StyleController.addImage.
const
factory
MarkerIcon.expression(Expression<String> imageId)
The image of the style that imageId picks for each feature, such as Expression.get('icon').asString() for the image named in a property of the feature. The map doesn't add or remove images for it.
const
factory
MarkerIcon.iconData(IconData icon, {Color color, double size})
The icon icon, such as one of the Icons of Material, drawn size logical pixels large in color.
const
factory
MarkerIcon.named(String imageId)
The image imageId that the style already has, from its sprite or from StyleController.addImage. The map doesn't add or remove it.
const
factory
MarkerIcon.provider(ImageProvider<Object> provider)
The image of the Flutter ImageProvider provider, such as an AssetImage or a NetworkImage, at the scale of the image it loads.
const
factory

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited