Marker

open class Marker : Annotation

Deprecated

Marker is an annotation that shows an icon image at a geographical location. The default marker uses a provided icon. This icon can be customized using IconFactory to generate an Icon using a provided image. Markers are added to the map by first giving a LatLng and using addMarker. The marker icon will be centered at this position so it is common to add padding to the icon image before usage.

Markers are designed to be interactive. They receive click events by default, and are often used with event listeners to bring up info windows. An InfoWindow is displayed by default when either a title or snippet is provided.

Deprecated

As of 7.0.0, use Mapbox Annotation Plugin instead

Constructors

Link copied to clipboard
open fun Marker(baseMarkerOptions: BaseMarkerOptions)
Creates a instance of Marker using the builder of Marker.

Functions

Link copied to clipboard
open fun compareTo(@NonNull annotation: Annotation): Int
Compares this Annotation object with another Annotation.
abstract fun compareTo(p: T): Int
Link copied to clipboard
open fun equals(@Nullable object: Any): Boolean
Checks if this Annotation object is equal to another Annotation.
Link copied to clipboard
open fun hashCode(): Int
Gives an integer which can be used as the bucket number for storing elements of the set/map.
Link copied to clipboard
open fun hideInfoWindow()
Do not use this method, used internally by the SDK.
Link copied to clipboard
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun remove()
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun setMapboxMap(mapboxMap: MapboxMap)
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun setMapView(mapView: MapView)
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun setRightOffsetPixels(rightOffsetPixels: Int)
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun setTopOffsetPixels(topOffsetPixels: Int)
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun showInfoWindow(@NonNull mapboxMap: MapboxMap, @NonNull mapView: MapView): InfoWindow
Do not use this method, used internally by the SDK.
Link copied to clipboard
open fun toString(): String
Returns a String with the marker position.

Properties

Link copied to clipboard
open var icon: Icon
Link copied to clipboard
open var id: Long
The annotation id Internal C++ id is stored as unsigned int.
Link copied to clipboard
Link copied to clipboard
open var position: LatLng
Link copied to clipboard
open var snippet: String
Link copied to clipboard
open var title: String