MapOverlayPlugin

Interface for MapOverlay Container that manage MapOverlays.

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 getEdgeInsets(): EdgeInsets

Get an EdgeInsets that represent the width and height of overlays

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 reframe(onReframeFinished: OnReframeFinished? = null)

Reframe MapView to a certain zoom and position to make sure every coordinate will be shown on the MapView and not covered by registered MapOverlays. If no OnReframeFinished object is provided, MapView will jump to the new CameraOptions directly; if OnReframeFinished object is provided, the new CameraOptions will be return and users can define their own animation to move the camera.

Link copied to clipboard

To register a MapOverlayCoordinatesProvider instance to the Container

Link copied to clipboard
abstract fun registerOverlay(overlay: View)

Register an view as overlay.

Link copied to clipboard
abstract fun registerOverlays(overlays: List<View>)

Register views as overlays

Link copied to clipboard
abstract fun setDisplayingAreaMargins(marginTop: Int, marginLeft: Int, marginBottom: Int, marginRight: Int)

Set the margins for the area that displaying import POIs without covered. These margins can let the POIs near the border not by cut or covered.

Link copied to clipboard
abstract fun unregisterOverlay(overlay: View)

Unregister an view.

Link copied to clipboard
abstract fun unregisterOverlays(overlays: List<View>)

Unregister views.