Created
September 5, 2018 17:55
-
-
Save davidseek/46a5a4c476d3e1b08e34a859b0143d9f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class LocationManager: NSObject { | |
| // - Private | |
| private let locationManager = CLLocationManager() | |
| // - API | |
| public var exposedLocation: CLLocation? { | |
| return self.locationManager.location | |
| } | |
| override init() { | |
| super.init() | |
| self.locationManager.delegate = self | |
| self.locationManager.desiredAccuracy = kCLLocationAccuracyBest | |
| self.locationManager.requestWhenInUseAuthorization() | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment