AnnotationPlugin

Plugin interface for the annotation.

Functions

Link copied to clipboard
open fun cleanup()

Called when the map is destroyed. Should be used to cleanup plugin resources for that map.

Link copied to clipboard
abstract fun createAnnotationManager(type: AnnotationType, annotationConfig: AnnotationConfig?): AnnotationManager<*, *, *, *, *, *, *>

Create an annotation manager.

Link copied to clipboard
open fun initialize()

Called when the plugin is first added to the map.

Link copied to clipboard
open fun onDelegateProvider(delegateProvider: MapDelegateProvider)

Provides all map delegate instances.

Link copied to clipboard
open fun onSizeChanged(width: Int, height: Int)

Invoked when MapView's width and height have changed.

Link copied to clipboard
abstract fun onStyleChanged(style: MapboxStyleManager)

Called when a new Style is loaded.

Link copied to clipboard
abstract fun removeAnnotationManager(annotationManager: AnnotationManager<*, *, *, *, *, *, *>)

Removes an annotation manager, this will remove the underlying layer and source from the style. A removed annotation manager will not be able to reuse anymore, users need to create new annotation manager to add annotations.

Extensions

Link copied to clipboard

Extension function to create a CircleAnnotationManager instance.

Link copied to clipboard

Extension function to create a PointAnnotationManager instance.

Link copied to clipboard

Extension function to create a PolygonAnnotationManager instance.

Link copied to clipboard

Extension function to create a PolylineAnnotationManager instance.