kvision / pl.treksoft.kvision.cordova / Locationservices

Locationservices

(js) object Locationservices

Main geolocation object based on Google location services api.

Types

(js)

Priority

Location services priority.

enum class Priority

Functions

(js)

clearWatch

Clear the given watch.

fun clearWatch(watchId: String): Unit
(js)

getCurrentPosition

Get current location.

suspend fun getCurrentPosition(enableHighAccuracy: Boolean = true, timeout: Number? = null, maximumAge: Number? = null, priority: Priority? = null, interval: Number? = null, fastInterval: Number? = null): Result<Position, GeolocationException>
(js)

watchPosition

Watch location changes.

suspend fun watchPosition(enableHighAccuracy: Boolean = true, timeout: Number? = null, maximumAge: Number? = null, priority: Priority? = null, interval: Number? = null, fastInterval: Number? = null, resultCallback: (Result<Position, GeolocationException>) -> Unit): String?