MapOptions
data class MapOptions @JvmOverloads constructor(val mapKey: String, val cameraOptions: CameraOptions? = null, val padding: Padding = Padding(), val mapStyle: StyleDescriptor? = null, val styleMode: StyleMode = StyleMode.MAIN, val onlineCachePolicy: OnlineCachePolicy = OnlineCachePolicy.Default, val renderToTexture: Boolean = false) : Parcelable
The MapOptions class configures initial behavior and visual style of the map. It enables setting the default zoom level, the map language, style and more. The MapOptions is used as an argument for MapFragment.newInstance, which instantiates MapFragment object.
val mapOptions = MapOptions(mapKey = "YOUR_API_KEY")
val mapFragment = MapFragment.newInstance(mapOptions)
Content copied to clipboard
Constructors
Link copied to clipboard
constructor(mapKey: String, cameraOptions: CameraOptions? = null, padding: Padding = Padding(), mapStyle: StyleDescriptor? = null, styleMode: StyleMode = StyleMode.MAIN, onlineCachePolicy: OnlineCachePolicy = OnlineCachePolicy.Default, renderToTexture: Boolean = false)
Properties
Link copied to clipboard
Provides CameraOptions associated with the current MapOptions.
Link copied to clipboard
Provides custom StyleDescriptor with style that will be used as initial style.
Link copied to clipboard
Defines OnlineCachePolicy that will be used for the HTTP caching.
Link copied to clipboard
If set to true render to texture view rather than surface view.