DefaultCLLocationProvider
public class DefaultCLLocationProvider : NSObject, ValidatingLocationProvider
extension DefaultCLLocationProvider: CLLocationManagerDelegate
Implementation of LocationProvider
that uses CLLocationManager
as a GPS source provider.
Important
This is a Public Preview API. It may be changed or removed at any time.-
DefaultCLLocationProvider init method.
Declaration
Swift
convenience public init( locationValidationPolicy: LocationUpdateValidator? = nil )
Parameters
locationValidationPolicy
policy for validating incoming location updates, defined by
LocationUpdateValidator
protocol.
-
Declaration
Swift
public var location: GeoLocation?
-
Declaration
Swift
public var validationPolicy: LocationUpdateValidator
-
Declaration
Swift
public func start()
-
Declaration
Swift
public func stop()
-
Declaration
Swift
public func addObserver(_ observer: LocationProviderObservable)
-
Declaration
Swift
public func removeObserver(_ observer: LocationProviderObservable)
-
Declaration
Swift
public func locationManager(_: CLLocationManager, didUpdateLocations locations: [CLLocation])
-
Declaration
Swift
public func locationManager(_: CLLocationManager, didUpdateHeading newHeading: CLHeading)
-
Declaration
Swift
public func locationManager(_: CLLocationManager, didChangeAuthorization status: CLAuthorizationStatus)