Instance Method

stopUpdatingLocation()

Stops the generation of location updates.

Declaration

func stopUpdatingLocation()

Discussion

Call this method whenever your code no longer needs to receive location-related events. Disabling event delivery gives the receiver the option of disabling the appropriate hardware (and thereby saving power) when no clients need location data. You can always restart the generation of location updates by calling the startUpdatingLocation() method again.

See Also

Initiating Standard Location Updates

func startUpdatingLocation()

Starts the generation of updates that report the user’s current location.

func requestLocation()

Requests the one-time delivery of the user’s current location.

var pausesLocationUpdatesAutomatically: Bool

A Boolean value indicating whether the location manager object may pause location updates.

var allowsBackgroundLocationUpdates: Bool

A Boolean value indicating whether the app should receive location updates when suspended.

var showsBackgroundLocationIndicator: Bool

A Boolean indicating whether the status bar changes its appearance when location services are used in the background.

var distanceFilter: CLLocationDistance

The minimum distance (measured in meters) a device must move horizontally before an update event is generated.

var desiredAccuracy: CLLocationAccuracy

The accuracy of the location data.

var activityType: CLActivityType

The type of user activity associated with the location updates.

enum CLActivityType

Constants indicating the type of activity associated with location updates.