ViewPlugin

Defines interface of a ViewPlugin.

fun fun interface ViewPlugin : MapPlugin

Types

Initializer
Link copied to clipboard

Initializer class wraps a bind configuration that can be used during plugin initialisation.

data class Initializer(context: WeakReference<Context>, attributes: TypedArray, pixelRatio: Float)

Functions

bind
Link copied to clipboard

Bind a view instance

abstract fun bind(mapView: FrameLayout, attrs: AttributeSet?, pixelRatio: Float): View
cleanup
Link copied to clipboard

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

open override fun cleanup()
equals
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
hashCode
Link copied to clipboard
open override fun hashCode(): Int
initialize
Link copied to clipboard

Called when the plugin is first added to the map.

open override fun initialize()
onDelegateProvider
Link copied to clipboard

Provides all map delegate instances.

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

Provides a view instances returned in inflate after it's been added to the MapView.

open fun onPluginView(view: View)
toString
Link copied to clipboard
open override fun toString(): String

Inheritors

AttributionPlugin
Link copied to clipboard
CompassPlugin
Link copied to clipboard
LogoPlugin
Link copied to clipboard
ScaleBarPlugin
Link copied to clipboard