← Back to notebook index

Notebook Topic

Maps Geolocation

English topic guide inspired by the original iOS Developer Notebook, expanded for both iOS and Android teams.

What this topic covers

Execution checklist

iOS implementation notes

Android implementation notes

Code examples

Swift

let manager = CLLocationManager()
manager.requestWhenInUseAuthorization()
manager.desiredAccuracy = kCLLocationAccuracyHundredMeters
manager.startUpdatingLocation()

Kotlin

fusedClient.requestLocationUpdates(
  LocationRequest.Builder(Priority.PRIORITY_BALANCED_POWER_ACCURACY, 10_000).build(),
  callback,
  Looper.getMainLooper()
)

Reference links

Related topics