GPSManager

Simplifies process of requesting GPS location from different GPS sources (built-in GPS modules or external GPS device).

Properties

Link copied to clipboard

Functions

Link copied to clipboard

Add on observer on location provider status changes. Only available with LocationFromBuiltInGPS: this callback will be called when the GPS or Network provider status changed.

Link copied to clipboard

Provides latest known location

Link copied to clipboard

Checks if given Location Data Source is enabled

Link copied to clipboard
open override fun onPositionUpdate(position: Location)

Called whenever last known device location is updated.

Link copied to clipboard
open override fun onProviderDisabled(provider: String)
Link copied to clipboard
open override fun onProviderEnabled(provider: String)
Link copied to clipboard

Removes onPositionUpdateCallback if it was previously added.

Link copied to clipboard

Removes OnProviderStatusChangedCallback if it was previously added.

Link copied to clipboard

Starts requesting location updates from given source, stopping any previously started location providers.

Link copied to clipboard
fun stop()

Stops currently used location data source.