Class CLAuthorizationStatus


  • public final class CLAuthorizationStatus
    extends java.lang.Object
    CLAuthorizationStatus Discussion: Represents the current authorization state of the application.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int Authorized
      User has authorized this application to use location services.
      static int AuthorizedAlways
      User has granted authorization to use their location at any time.
      static int AuthorizedWhenInUse
      User has granted authorization to use their location only while they are using your app.
      static int Denied
      User has explicitly denied authorization for this application, or location services are disabled in Settings.
      static int NotDetermined
      User has not yet made a choice with regards to this application
      static int Restricted
      This application is not authorized to use location services.
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • NotDetermined

        public static final int NotDetermined
        User has not yet made a choice with regards to this application
        See Also:
        Constant Field Values
      • Restricted

        public static final int Restricted
        This application is not authorized to use location services. Due to active restrictions on location services, the user cannot change this status, and may not have personally denied authorization
        See Also:
        Constant Field Values
      • Denied

        public static final int Denied
        User has explicitly denied authorization for this application, or location services are disabled in Settings.
        See Also:
        Constant Field Values
      • AuthorizedAlways

        public static final int AuthorizedAlways
        User has granted authorization to use their location at any time. Your app may be launched into the background by monitoring APIs such as visit monitoring, region monitoring, and significant location change monitoring. This value should be used on iOS, tvOS and watchOS. It is available on MacOS, but kCLAuthorizationStatusAuthorized is synonymous and preferred.
        See Also:
        Constant Field Values
      • AuthorizedWhenInUse

        public static final int AuthorizedWhenInUse
        User has granted authorization to use their location only while they are using your app. Note: You can reflect the user's continued engagement with your app using -allowsBackgroundLocationUpdates. This value is not available on MacOS. It should be used on iOS, tvOS and watchOS.
        See Also:
        Constant Field Values
      • Authorized

        public static final int Authorized
        User has authorized this application to use location services. This value is deprecated or prohibited on iOS, tvOS and watchOS. It should be used on MacOS.
        See Also:
        Constant Field Values