GeoLocation

data class GeoLocation(    val position: GeoCoordinate,     val accuracy: Double? = null,     val bearing: Double? = null,     val heading: Double? = null,     val speed: Double? = null,     val altitude: Double? = null,     val time: Long = System.currentTimeMillis(),     val provider: String = DEFAULT_PROVIDER,     val providerType: LocationProviderType = LocationProviderType.REALTIME,     val extras: Bundle? = null)

Geographical representation of a certain location. It provides additional attributes like speed or bearing what can be useful in navigation applications.

Parameters

position

Geographical position of the current location.

accuracy

GPS accuracy (in meters) of the current location.

bearing

Horizontal direction (in degrees) of travel at the current location. Or null if not available.

heading

Compass angle the object is pointing to from the current location. Or null if not available.

speed

Current speed in meters per second. Or null if not available.

altitude

Altitude in meters. Or null if not available.

time

Time in millis.

provider

The name of the location provider.

providerType

The type of the location provider (eg. REALTIME or SOFT_DR).

extras

Extra data accompanying this location.

Important: This is a Public Preview API. It may be changed or removed at any time.

Constructors

Link copied to clipboard
fun GeoLocation(    position: GeoCoordinate,     accuracy: Double? = null,     bearing: Double? = null,     heading: Double? = null,     speed: Double? = null,     altitude: Double? = null,     time: Long = System.currentTimeMillis(),     provider: String = DEFAULT_PROVIDER,     providerType: LocationProviderType = LocationProviderType.REALTIME,     extras: Bundle? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val accuracy: Double? = null
Link copied to clipboard
val altitude: Double? = null
Link copied to clipboard
val bearing: Double? = null
Link copied to clipboard
val extras: Bundle? = null
Link copied to clipboard
val heading: Double? = null
Link copied to clipboard
val position: GeoCoordinate
Link copied to clipboard
val provider: String
Link copied to clipboard
val providerType: LocationProviderType
Link copied to clipboard
val speed: Double? = null
Link copied to clipboard
val time: Long