Interface CLLocationManagerDelegate


  • public interface CLLocationManagerDelegate
    CLLocationManagerDelegate Discussion: Delegate for CLLocationManager.
    • Method Detail

      • locationManagerDidChangeAuthorizationStatus

        default void locationManagerDidChangeAuthorizationStatus​(CLLocationManager manager,
                                                                 int status)
        locationManager:didChangeAuthorizationStatus: Discussion: Invoked when the authorization status changes for this application.
      • locationManagerDidDetermineStateForRegion

        default void locationManagerDidDetermineStateForRegion​(CLLocationManager manager,
                                                               long state,
                                                               CLRegion region)
        locationManager:didDetermineState:forRegion: Discussion: Invoked when there's a state transition for a monitored region or in response to a request for state via a a call to requestStateForRegion:.
      • locationManagerDidEnterRegion

        default void locationManagerDidEnterRegion​(CLLocationManager manager,
                                                   CLRegion region)
        locationManager:didEnterRegion: Discussion: Invoked when the user enters a monitored region. This callback will be invoked for every allocated CLLocationManager instance with a non-nil delegate that implements this method.
      • locationManagerDidExitRegion

        default void locationManagerDidExitRegion​(CLLocationManager manager,
                                                  CLRegion region)
        locationManager:didExitRegion: Discussion: Invoked when the user exits a monitored region. This callback will be invoked for every allocated CLLocationManager instance with a non-nil delegate that implements this method.
      • locationManagerDidFailWithError

        default void locationManagerDidFailWithError​(CLLocationManager manager,
                                                     NSError error)
        locationManager:didFailWithError: Discussion: Invoked when an error has occurred. Error types are defined in "CLError.h".
      • locationManagerDidFinishDeferredUpdatesWithError

        default void locationManagerDidFinishDeferredUpdatesWithError​(CLLocationManager manager,
                                                                      NSError error)
        locationManager:didFinishDeferredUpdatesWithError: Discussion: Invoked when deferred updates will no longer be delivered. Stopping location, disallowing deferred updates, and meeting a specified criterion are all possible reasons for finishing deferred updates. An error will be returned if deferred updates end before the specified criteria are met (see CLError), otherwise error will be nil.
      • locationManagerDidRangeBeaconsInRegion

        default void locationManagerDidRangeBeaconsInRegion​(CLLocationManager manager,
                                                            NSArray<? extends CLBeacon> beacons,
                                                            CLBeaconRegion region)
        locationManager:didRangeBeacons:inRegion: Discussion: Invoked when a new set of beacons are available in the specified region. beacons is an array of CLBeacon objects. If beacons is empty, it may be assumed no beacons that match the specified region are nearby. Similarly if a specific beacon no longer appears in beacons, it may be assumed the beacon is no longer received by the device.
      • locationManagerDidStartMonitoringForRegion

        default void locationManagerDidStartMonitoringForRegion​(CLLocationManager manager,
                                                                CLRegion region)
        locationManager:didStartMonitoringForRegion: Discussion: Invoked when a monitoring for a region started successfully.
      • locationManagerDidUpdateHeading

        default void locationManagerDidUpdateHeading​(CLLocationManager manager,
                                                     CLHeading newHeading)
        locationManager:didUpdateHeading: Discussion: Invoked when a new heading is available.
      • locationManagerDidUpdateLocations

        default void locationManagerDidUpdateLocations​(CLLocationManager manager,
                                                       NSArray<? extends CLLocation> locations)
        locationManager:didUpdateLocations: Discussion: Invoked when new locations are available. Required for delivery of deferred locations. If implemented, updates will not be delivered to locationManager:didUpdateToLocation:fromLocation: locations is an array of CLLocation objects in chronological order.
      • locationManagerDidUpdateToLocationFromLocation

        @Deprecated
        default void locationManagerDidUpdateToLocationFromLocation​(CLLocationManager manager,
                                                                    CLLocation newLocation,
                                                                    CLLocation oldLocation)
        Deprecated.
        locationManager:didUpdateToLocation:fromLocation: Discussion: Invoked when a new location is available. oldLocation may be nil if there is no previous location available. This method is deprecated. If locationManager:didUpdateLocations: is implemented, this method will not be called.
      • locationManagerDidVisit

        default void locationManagerDidVisit​(CLLocationManager manager,
                                             CLVisit visit)
        locationManager:didVisit: Discussion: Invoked when the CLLocationManager determines that the device has visited a location, if visit monitoring is currently started (possibly from a prior launch).
      • locationManagerMonitoringDidFailForRegionWithError

        default void locationManagerMonitoringDidFailForRegionWithError​(CLLocationManager manager,
                                                                        CLRegion region,
                                                                        NSError error)
        locationManager:monitoringDidFailForRegion:withError: Discussion: Invoked when a region monitoring error has occurred. Error types are defined in "CLError.h".
      • locationManagerRangingBeaconsDidFailForRegionWithError

        default void locationManagerRangingBeaconsDidFailForRegionWithError​(CLLocationManager manager,
                                                                            CLBeaconRegion region,
                                                                            NSError error)
        locationManager:rangingBeaconsDidFailForRegion:withError: Discussion: Invoked when an error has occurred ranging beacons in a region. Error types are defined in "CLError.h".
      • locationManagerDidPauseLocationUpdates

        default void locationManagerDidPauseLocationUpdates​(CLLocationManager manager)
        Discussion: Invoked when location updates are automatically paused.
      • locationManagerDidResumeLocationUpdates

        default void locationManagerDidResumeLocationUpdates​(CLLocationManager manager)
        Discussion: Invoked when location updates are automatically resumed. In the event that your application is terminated while suspended, you will not receive this notification.
      • locationManagerShouldDisplayHeadingCalibration

        default boolean locationManagerShouldDisplayHeadingCalibration​(CLLocationManager manager)
        locationManagerShouldDisplayHeadingCalibration: Discussion: Invoked when a new heading is available. Return YES to display heading calibration info. The display will remain until heading is calibrated, unless dismissed early via dismissHeadingCalibrationDisplay.
      • locationManagerDidChangeAuthorization

        default void locationManagerDidChangeAuthorization​(CLLocationManager manager)
        locationManagerDidChangeAuthorization: Discussion: Invoked when either the authorizationStatus or accuracyAuthorization properties change