Documentation Archive Developer
Search

CoreLocation Changes for Swift

CoreLocation

Raw Value Type
From--
ToInt

DeclarationRaw Value Type
From
enum CLAuthorizationStatus : Int32 {
    case NotDetermined
    case Restricted
    case Denied
    case AuthorizedAlways
    case AuthorizedWhenInUse
}
--
To
enum CLAuthorizationStatus : Int32 {
    case NotDetermined
    case Restricted
    case Denied
    case AuthorizedAlways
    case AuthorizedWhenInUse
    static var Authorized: CLAuthorizationStatus { get }
}
Int32

Modified CLBeacon
Declaration
From
class CLBeacon : NSObject, NSCopying, NSSecureCoding, NSCoding {
    var proximityUUID: NSUUID! { get }
    var major: NSNumber! { get }
    var minor: NSNumber! { get }
    var proximity: CLProximity { get }
    var accuracy: CLLocationAccuracy { get }
    var rssi: Int { get }
}
To
class CLBeacon : NSObject, NSCopying, NSSecureCoding, NSCoding {
    var proximityUUID: NSUUID { get }
    var major: NSNumber { get }
    var minor: NSNumber { get }
    var proximity: CLProximity { get }
    var accuracy: CLLocationAccuracy { get }
    var rssi: Int { get }
}

Declaration
From
var major: NSNumber! { get }
To
var major: NSNumber { get }

Declaration
From
var minor: NSNumber! { get }
To
var minor: NSNumber { get }

Declaration
From
var proximityUUID: NSUUID! { get }
To
var proximityUUID: NSUUID { get }

Declaration
From
class CLBeaconRegion : CLRegion {
    init!(proximityUUID proximityUUID: NSUUID!, identifier identifier: String!)
    init!(proximityUUID proximityUUID: NSUUID!, major major: CLBeaconMajorValue, identifier identifier: String!)
    init!(proximityUUID proximityUUID: NSUUID!, major major: CLBeaconMajorValue, minor minor: CLBeaconMinorValue, identifier identifier: String!)
    func peripheralDataWithMeasuredPower(_ measuredPower: NSNumber!) -> NSMutableDictionary!
    var proximityUUID: NSUUID! { get }
    var major: NSNumber! { get }
    var minor: NSNumber! { get }
    var notifyEntryStateOnDisplay: Bool
}
To
class CLBeaconRegion : CLRegion {
    init(proximityUUID proximityUUID: NSUUID, identifier identifier: String)
    init(proximityUUID proximityUUID: NSUUID, major major: CLBeaconMajorValue, identifier identifier: String)
    init(proximityUUID proximityUUID: NSUUID, major major: CLBeaconMajorValue, minor minor: CLBeaconMinorValue, identifier identifier: String)
    func peripheralDataWithMeasuredPower(_ measuredPower: NSNumber?) -> NSMutableDictionary
    var proximityUUID: NSUUID { get }
    var major: NSNumber? { get }
    var minor: NSNumber? { get }
    var notifyEntryStateOnDisplay: Bool
}

Declaration
From
init!(proximityUUID proximityUUID: NSUUID!, identifier identifier: String!)
To
init(proximityUUID proximityUUID: NSUUID, identifier identifier: String)

Declaration
From
init!(proximityUUID proximityUUID: NSUUID!, major major: CLBeaconMajorValue, identifier identifier: String!)
To
init(proximityUUID proximityUUID: NSUUID, major major: CLBeaconMajorValue, identifier identifier: String)

Declaration
From
init!(proximityUUID proximityUUID: NSUUID!, major major: CLBeaconMajorValue, minor minor: CLBeaconMinorValue, identifier identifier: String!)
To
init(proximityUUID proximityUUID: NSUUID, major major: CLBeaconMajorValue, minor minor: CLBeaconMinorValue, identifier identifier: String)

Declaration
From
var major: NSNumber! { get }
To
var major: NSNumber? { get }

Declaration
From
var minor: NSNumber! { get }
To
var minor: NSNumber? { get }

Declaration
From
func peripheralDataWithMeasuredPower(_ measuredPower: NSNumber!) -> NSMutableDictionary!
To
func peripheralDataWithMeasuredPower(_ measuredPower: NSNumber?) -> NSMutableDictionary

Declaration
From
var proximityUUID: NSUUID! { get }
To
var proximityUUID: NSUUID { get }

Declaration
From
class CLCircularRegion : CLRegion {
    init!(center center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String!)
    var center: CLLocationCoordinate2D { get }
    var radius: CLLocationDistance { get }
    func containsCoordinate(_ coordinate: CLLocationCoordinate2D) -> Bool
}
To
class CLCircularRegion : CLRegion {
    init(center center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String)
    var center: CLLocationCoordinate2D { get }
    var radius: CLLocationDistance { get }
    func containsCoordinate(_ coordinate: CLLocationCoordinate2D) -> Bool
}

Declaration
From
init!(center center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String!)
To
init(center center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String)

Raw Value Type
From--
ToInt32

DeclarationProtocolsRaw Value Type
From
enum CLError : Int {
    case LocationUnknown
    case Denied
    case Network
    case HeadingFailure
    case RegionMonitoringDenied
    case RegionMonitoringFailure
    case RegionMonitoringSetupDelayed
    case RegionMonitoringResponseDelayed
    case GeocodeFoundNoResult
    case GeocodeFoundPartialResult
    case GeocodeCanceled
    case DeferredFailed
    case DeferredNotUpdatingLocation
    case DeferredAccuracyTooLow
    case DeferredDistanceFiltered
    case DeferredCanceled
    case RangingUnavailable
    case RangingFailure
}
Equatable, Hashable, RawRepresentable--
To
enum CLError : Int {
    case LocationUnknown
    case Denied
    case Network
    case HeadingFailure
    case RegionMonitoringDenied
    case RegionMonitoringFailure
    case RegionMonitoringSetupDelayed
    case RegionMonitoringResponseDelayed
    case GeocodeFoundNoResult
    case GeocodeFoundPartialResult
    case GeocodeCanceled
    case DeferredFailed
    case DeferredNotUpdatingLocation
    case DeferredAccuracyTooLow
    case DeferredDistanceFiltered
    case DeferredCanceled
    case RangingUnavailable
    case RangingFailure
}
extension CLError : Hashable, Equatable, __BridgedNSError, ErrorType, RawRepresentable, _ObjectiveCBridgeableErrorType, _BridgedNSError {
}
extension CLError : Hashable, Equatable, __BridgedNSError, ErrorType, RawRepresentable, _ObjectiveCBridgeableErrorType, _BridgedNSError {
}
Equatable, ErrorType, Hashable, RawRepresentableInt

Modified CLGeocoder
Declaration
From
class CLGeocoder : NSObject {
    var geocoding: Bool { get }
    func reverseGeocodeLocation(_ location: CLLocation!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
    func geocodeAddressDictionary(_ addressDictionary: [NSObject : AnyObject]!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
    func geocodeAddressString(_ addressString: String!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
    func geocodeAddressString(_ addressString: String!, inRegion region: CLRegion!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
    func cancelGeocode()
}
To
class CLGeocoder : NSObject {
    var geocoding: Bool { get }
    func reverseGeocodeLocation(_ location: CLLocation, completionHandler completionHandler: CLGeocodeCompletionHandler)
    func geocodeAddressDictionary(_ addressDictionary: [NSObject : AnyObject], completionHandler completionHandler: CLGeocodeCompletionHandler)
    func geocodeAddressString(_ addressString: String, completionHandler completionHandler: CLGeocodeCompletionHandler)
    func geocodeAddressString(_ addressString: String, inRegion region: CLRegion?, completionHandler completionHandler: CLGeocodeCompletionHandler)
    func cancelGeocode()
}

Declaration
From
func geocodeAddressDictionary(_ addressDictionary: [NSObject : AnyObject]!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
To
func geocodeAddressDictionary(_ addressDictionary: [NSObject : AnyObject], completionHandler completionHandler: CLGeocodeCompletionHandler)

Declaration
From
func geocodeAddressString(_ addressString: String!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
To
func geocodeAddressString(_ addressString: String, completionHandler completionHandler: CLGeocodeCompletionHandler)

Declaration
From
func geocodeAddressString(_ addressString: String!, inRegion region: CLRegion!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
To
func geocodeAddressString(_ addressString: String, inRegion region: CLRegion?, completionHandler completionHandler: CLGeocodeCompletionHandler)

Declaration
From
func reverseGeocodeLocation(_ location: CLLocation!, completionHandler completionHandler: CLGeocodeCompletionHandler!)
To
func reverseGeocodeLocation(_ location: CLLocation, completionHandler completionHandler: CLGeocodeCompletionHandler)

Modified CLHeading
Declaration
From
class CLHeading : NSObject, NSCopying, NSSecureCoding, NSCoding {
    var magneticHeading: CLLocationDirection { get }
    var trueHeading: CLLocationDirection { get }
    var headingAccuracy: CLLocationDirection { get }
    var x: CLHeadingComponentValue { get }
    var y: CLHeadingComponentValue { get }
    var z: CLHeadingComponentValue { get }
    @NSCopying var timestamp: NSDate! { get }
    var description: String! { get }
}
To
class CLHeading : NSObject, NSCopying, NSSecureCoding, NSCoding {
    var magneticHeading: CLLocationDirection { get }
    var trueHeading: CLLocationDirection { get }
    var headingAccuracy: CLLocationDirection { get }
    var x: CLHeadingComponentValue { get }
    var y: CLHeadingComponentValue { get }
    var z: CLHeadingComponentValue { get }
    @NSCopying var timestamp: NSDate { get }
    var description: String { get }
}

Modified CLHeading.description
Declaration
From
var description: String! { get }
To
var description: String { get }

Declaration
From
@NSCopying var timestamp: NSDate! { get }
To
@NSCopying var timestamp: NSDate { get }

Modified CLLocation
Declaration
From
class CLLocation : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init!(latitude latitude: CLLocationDegrees, longitude longitude: CLLocationDegrees)
    init!(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, timestamp timestamp: NSDate!)
    init!(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, course course: CLLocationDirection, speed speed: CLLocationSpeed, timestamp timestamp: NSDate!)
    var coordinate: CLLocationCoordinate2D { get }
    var altitude: CLLocationDistance { get }
    var horizontalAccuracy: CLLocationAccuracy { get }
    var verticalAccuracy: CLLocationAccuracy { get }
    var course: CLLocationDirection { get }
    var speed: CLLocationSpeed { get }
    @NSCopying var timestamp: NSDate! { get }
    @NSCopying var floor: CLFloor! { get }
    var description: String! { get }
    func getDistanceFrom(_ location: CLLocation!) -> CLLocationDistance
    func distanceFromLocation(_ location: CLLocation!) -> CLLocationDistance
}
extension CLLocation : CKRecordValue, NSObjectProtocol {
}
To
class CLLocation : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init(latitude latitude: CLLocationDegrees, longitude longitude: CLLocationDegrees)
    init(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, timestamp timestamp: NSDate)
    init(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, course course: CLLocationDirection, speed speed: CLLocationSpeed, timestamp timestamp: NSDate)
    var coordinate: CLLocationCoordinate2D { get }
    var altitude: CLLocationDistance { get }
    var horizontalAccuracy: CLLocationAccuracy { get }
    var verticalAccuracy: CLLocationAccuracy { get }
    var course: CLLocationDirection { get }
    var speed: CLLocationSpeed { get }
    @NSCopying var timestamp: NSDate { get }
    @NSCopying var floor: CLFloor? { get }
    var description: String { get }
    func getDistanceFrom(_ location: CLLocation) -> CLLocationDistance
    func distanceFromLocation(_ location: CLLocation) -> CLLocationDistance
}
extension CLLocation : CKRecordValue {
}

Modified CLLocation.description
Declaration
From
var description: String! { get }
To
var description: String { get }

Declaration
From
func distanceFromLocation(_ location: CLLocation!) -> CLLocationDistance
To
func distanceFromLocation(_ location: CLLocation) -> CLLocationDistance

Declaration
From
@NSCopying var floor: CLFloor! { get }
To
@NSCopying var floor: CLFloor? { get }

Declaration
From
init!(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, course course: CLLocationDirection, speed speed: CLLocationSpeed, timestamp timestamp: NSDate!)
To
init(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, course course: CLLocationDirection, speed speed: CLLocationSpeed, timestamp timestamp: NSDate)

Declaration
From
init!(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, timestamp timestamp: NSDate!)
To
init(coordinate coordinate: CLLocationCoordinate2D, altitude altitude: CLLocationDistance, horizontalAccuracy hAccuracy: CLLocationAccuracy, verticalAccuracy vAccuracy: CLLocationAccuracy, timestamp timestamp: NSDate)

Declaration
From
init!(latitude latitude: CLLocationDegrees, longitude longitude: CLLocationDegrees)
To
init(latitude latitude: CLLocationDegrees, longitude longitude: CLLocationDegrees)

Declaration
From
@NSCopying var timestamp: NSDate! { get }
To
@NSCopying var timestamp: NSDate { get }

Declaration
From
class CLLocationManager : NSObject {
    class func locationServicesEnabled() -> Bool
    class func headingAvailable() -> Bool
    class func significantLocationChangeMonitoringAvailable() -> Bool
    class func isMonitoringAvailableForClass(_ regionClass: AnyClass!) -> Bool
    class func regionMonitoringAvailable() -> Bool
    class func regionMonitoringEnabled() -> Bool
    class func isRangingAvailable() -> Bool
    class func authorizationStatus() -> CLAuthorizationStatus
    unowned(unsafe) var delegate: CLLocationManagerDelegate!
    var locationServicesEnabled: Bool { get }
    var purpose: String!
    var activityType: CLActivityType
    var distanceFilter: CLLocationDistance
    var desiredAccuracy: CLLocationAccuracy
    var pausesLocationUpdatesAutomatically: Bool
    @NSCopying var location: CLLocation! { get }
    var headingAvailable: Bool { get }
    var headingFilter: CLLocationDegrees
    var headingOrientation: CLDeviceOrientation
    @NSCopying var heading: CLHeading! { get }
    var maximumRegionMonitoringDistance: CLLocationDistance { get }
    var monitoredRegions: Set<NSObject>! { get }
    var rangedRegions: Set<NSObject>! { get }
    func requestWhenInUseAuthorization()
    func requestAlwaysAuthorization()
    func startUpdatingLocation()
    func stopUpdatingLocation()
    func startUpdatingHeading()
    func stopUpdatingHeading()
    func dismissHeadingCalibrationDisplay()
    func startMonitoringSignificantLocationChanges()
    func stopMonitoringSignificantLocationChanges()
    func startMonitoringForRegion(_ region: CLRegion!, desiredAccuracy accuracy: CLLocationAccuracy)
    func stopMonitoringForRegion(_ region: CLRegion!)
    func startMonitoringForRegion(_ region: CLRegion!)
    func requestStateForRegion(_ region: CLRegion!)
    func startRangingBeaconsInRegion(_ region: CLBeaconRegion!)
    func stopRangingBeaconsInRegion(_ region: CLBeaconRegion!)
    func allowDeferredLocationUpdatesUntilTraveled(_ distance: CLLocationDistance, timeout timeout: NSTimeInterval)
    func disallowDeferredLocationUpdates()
    class func deferredLocationUpdatesAvailable() -> Bool
}
extension CLLocationManager {
    func startMonitoringVisits()
    func stopMonitoringVisits()
}
To
class CLLocationManager : NSObject {
    class func locationServicesEnabled() -> Bool
    class func headingAvailable() -> Bool
    class func significantLocationChangeMonitoringAvailable() -> Bool
    class func isMonitoringAvailableForClass(_ regionClass: AnyClass) -> Bool
    class func regionMonitoringAvailable() -> Bool
    class func regionMonitoringEnabled() -> Bool
    class func isRangingAvailable() -> Bool
    class func authorizationStatus() -> CLAuthorizationStatus
    unowned(unsafe) var delegate: CLLocationManagerDelegate?
    var locationServicesEnabled: Bool { get }
    var purpose: String?
    var activityType: CLActivityType
    var distanceFilter: CLLocationDistance
    var desiredAccuracy: CLLocationAccuracy
    var pausesLocationUpdatesAutomatically: Bool
    var allowsBackgroundLocationUpdates: Bool
    @NSCopying var location: CLLocation? { get }
    var headingAvailable: Bool { get }
    var headingFilter: CLLocationDegrees
    var headingOrientation: CLDeviceOrientation
    @NSCopying var heading: CLHeading? { get }
    var maximumRegionMonitoringDistance: CLLocationDistance { get }
    var monitoredRegions: Set<CLRegion> { get }
    var rangedRegions: Set<CLRegion> { get }
    func requestWhenInUseAuthorization()
    func requestAlwaysAuthorization()
    func startUpdatingLocation()
    func stopUpdatingLocation()
    func requestLocation()
    func startUpdatingHeading()
    func stopUpdatingHeading()
    func dismissHeadingCalibrationDisplay()
    func startMonitoringSignificantLocationChanges()
    func stopMonitoringSignificantLocationChanges()
    func startMonitoringForRegion(_ region: CLRegion, desiredAccuracy accuracy: CLLocationAccuracy)
    func stopMonitoringForRegion(_ region: CLRegion)
    func startMonitoringForRegion(_ region: CLRegion)
    func requestStateForRegion(_ region: CLRegion)
    func startRangingBeaconsInRegion(_ region: CLBeaconRegion)
    func stopRangingBeaconsInRegion(_ region: CLBeaconRegion)
    func allowDeferredLocationUpdatesUntilTraveled(_ distance: CLLocationDistance, timeout timeout: NSTimeInterval)
    func disallowDeferredLocationUpdates()
    class func deferredLocationUpdatesAvailable() -> Bool
}
extension CLLocationManager {
    func startMonitoringVisits()
    func stopMonitoringVisits()
}

Declaration
From
unowned(unsafe) var delegate: CLLocationManagerDelegate!
To
unowned(unsafe) var delegate: CLLocationManagerDelegate?

Declaration
From
@NSCopying var heading: CLHeading! { get }
To
@NSCopying var heading: CLHeading? { get }

Declaration
From
class func isMonitoringAvailableForClass(_ regionClass: AnyClass!) -> Bool
To
class func isMonitoringAvailableForClass(_ regionClass: AnyClass) -> Bool

Declaration
From
@NSCopying var location: CLLocation! { get }
To
@NSCopying var location: CLLocation? { get }

Declaration
From
var monitoredRegions: Set<NSObject>! { get }
To
var monitoredRegions: Set<CLRegion> { get }

Declaration
From
var rangedRegions: Set<NSObject>! { get }
To
var rangedRegions: Set<CLRegion> { get }

Declaration
From
func requestStateForRegion(_ region: CLRegion!)
To
func requestStateForRegion(_ region: CLRegion)

Declaration
From
func startMonitoringForRegion(_ region: CLRegion!)
To
func startMonitoringForRegion(_ region: CLRegion)

Declaration
From
func startRangingBeaconsInRegion(_ region: CLBeaconRegion!)
To
func startRangingBeaconsInRegion(_ region: CLBeaconRegion)

Declaration
From
func stopMonitoringForRegion(_ region: CLRegion!)
To
func stopMonitoringForRegion(_ region: CLRegion)

Declaration
From
func stopRangingBeaconsInRegion(_ region: CLBeaconRegion!)
To
func stopRangingBeaconsInRegion(_ region: CLBeaconRegion)

Declaration
From
protocol CLLocationManagerDelegate : NSObjectProtocol {
    optional func locationManager(_ manager: CLLocationManager!, didUpdateToLocation newLocation: CLLocation!, fromLocation oldLocation: CLLocation!)
    optional func locationManager(_ manager: CLLocationManager!, didUpdateLocations locations: [AnyObject]!)
    optional func locationManager(_ manager: CLLocationManager!, didUpdateHeading newHeading: CLHeading!)
    optional func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager!) -> Bool
    optional func locationManager(_ manager: CLLocationManager!, didDetermineState state: CLRegionState, forRegion region: CLRegion!)
    optional func locationManager(_ manager: CLLocationManager!, didRangeBeacons beacons: [AnyObject]!, inRegion region: CLBeaconRegion!)
    optional func locationManager(_ manager: CLLocationManager!, rangingBeaconsDidFailForRegion region: CLBeaconRegion!, withError error: NSError!)
    optional func locationManager(_ manager: CLLocationManager!, didEnterRegion region: CLRegion!)
    optional func locationManager(_ manager: CLLocationManager!, didExitRegion region: CLRegion!)
    optional func locationManager(_ manager: CLLocationManager!, didFailWithError error: NSError!)
    optional func locationManager(_ manager: CLLocationManager!, monitoringDidFailForRegion region: CLRegion!, withError error: NSError!)
    optional func locationManager(_ manager: CLLocationManager!, didChangeAuthorizationStatus status: CLAuthorizationStatus)
    optional func locationManager(_ manager: CLLocationManager!, didStartMonitoringForRegion region: CLRegion!)
    optional func locationManagerDidPauseLocationUpdates(_ manager: CLLocationManager!)
    optional func locationManagerDidResumeLocationUpdates(_ manager: CLLocationManager!)
    optional func locationManager(_ manager: CLLocationManager!, didFinishDeferredUpdatesWithError error: NSError!)
    optional func locationManager(_ manager: CLLocationManager!, didVisit visit: CLVisit!)
}
To
protocol CLLocationManagerDelegate : NSObjectProtocol {
    optional func locationManager(_ manager: CLLocationManager, didUpdateToLocation newLocation: CLLocation, fromLocation oldLocation: CLLocation)
    optional func locationManager(_ manager: CLLocationManager, didUpdateLocations locations: [CLLocation])
    optional func locationManager(_ manager: CLLocationManager, didUpdateHeading newHeading: CLHeading)
    optional func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager) -> Bool
    optional func locationManager(_ manager: CLLocationManager, didDetermineState state: CLRegionState, forRegion region: CLRegion)
    optional func locationManager(_ manager: CLLocationManager, didRangeBeacons beacons: [CLBeacon], inRegion region: CLBeaconRegion)
    optional func locationManager(_ manager: CLLocationManager, rangingBeaconsDidFailForRegion region: CLBeaconRegion, withError error: NSError)
    optional func locationManager(_ manager: CLLocationManager, didEnterRegion region: CLRegion)
    optional func locationManager(_ manager: CLLocationManager, didExitRegion region: CLRegion)
    optional func locationManager(_ manager: CLLocationManager, didFailWithError error: NSError)
    optional func locationManager(_ manager: CLLocationManager, monitoringDidFailForRegion region: CLRegion?, withError error: NSError)
    optional func locationManager(_ manager: CLLocationManager, didChangeAuthorizationStatus status: CLAuthorizationStatus)
    optional func locationManager(_ manager: CLLocationManager, didStartMonitoringForRegion region: CLRegion)
    optional func locationManagerDidPauseLocationUpdates(_ manager: CLLocationManager)
    optional func locationManagerDidResumeLocationUpdates(_ manager: CLLocationManager)
    optional func locationManager(_ manager: CLLocationManager, didFinishDeferredUpdatesWithError error: NSError?)
    optional func locationManager(_ manager: CLLocationManager, didVisit visit: CLVisit)
}

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didChangeAuthorizationStatus status: CLAuthorizationStatus)
To
optional func locationManager(_ manager: CLLocationManager, didChangeAuthorizationStatus status: CLAuthorizationStatus)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didDetermineState state: CLRegionState, forRegion region: CLRegion!)
To
optional func locationManager(_ manager: CLLocationManager, didDetermineState state: CLRegionState, forRegion region: CLRegion)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didEnterRegion region: CLRegion!)
To
optional func locationManager(_ manager: CLLocationManager, didEnterRegion region: CLRegion)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didExitRegion region: CLRegion!)
To
optional func locationManager(_ manager: CLLocationManager, didExitRegion region: CLRegion)

DeclarationIntroduction
From
optional func locationManager(_ manager: CLLocationManager!, didFailWithError error: NSError!)
iOS 8.0
To
optional func locationManager(_ manager: CLLocationManager, didFailWithError error: NSError)
iOS 2.0

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didFinishDeferredUpdatesWithError error: NSError!)
To
optional func locationManager(_ manager: CLLocationManager, didFinishDeferredUpdatesWithError error: NSError?)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didRangeBeacons beacons: [AnyObject]!, inRegion region: CLBeaconRegion!)
To
optional func locationManager(_ manager: CLLocationManager, didRangeBeacons beacons: [CLBeacon], inRegion region: CLBeaconRegion)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didStartMonitoringForRegion region: CLRegion!)
To
optional func locationManager(_ manager: CLLocationManager, didStartMonitoringForRegion region: CLRegion)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didUpdateHeading newHeading: CLHeading!)
To
optional func locationManager(_ manager: CLLocationManager, didUpdateHeading newHeading: CLHeading)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didUpdateLocations locations: [AnyObject]!)
To
optional func locationManager(_ manager: CLLocationManager, didUpdateLocations locations: [CLLocation])

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, didVisit visit: CLVisit!)
To
optional func locationManager(_ manager: CLLocationManager, didVisit visit: CLVisit)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, monitoringDidFailForRegion region: CLRegion!, withError error: NSError!)
To
optional func locationManager(_ manager: CLLocationManager, monitoringDidFailForRegion region: CLRegion?, withError error: NSError)

Declaration
From
optional func locationManager(_ manager: CLLocationManager!, rangingBeaconsDidFailForRegion region: CLBeaconRegion!, withError error: NSError!)
To
optional func locationManager(_ manager: CLLocationManager, rangingBeaconsDidFailForRegion region: CLBeaconRegion, withError error: NSError)

Declaration
From
optional func locationManagerDidPauseLocationUpdates(_ manager: CLLocationManager!)
To
optional func locationManagerDidPauseLocationUpdates(_ manager: CLLocationManager)

Declaration
From
optional func locationManagerDidResumeLocationUpdates(_ manager: CLLocationManager!)
To
optional func locationManagerDidResumeLocationUpdates(_ manager: CLLocationManager)

Declaration
From
optional func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager!) -> Bool
To
optional func locationManagerShouldDisplayHeadingCalibration(_ manager: CLLocationManager) -> Bool

Modified CLPlacemark
Declaration
From
class CLPlacemark : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init!(placemark placemark: CLPlacemark!)
    @NSCopying var location: CLLocation! { get }
    @NSCopying var region: CLRegion! { get }
    var addressDictionary: [NSObject : AnyObject]! { get }
    var name: String! { get }
    var thoroughfare: String! { get }
    var subThoroughfare: String! { get }
    var locality: String! { get }
    var subLocality: String! { get }
    var administrativeArea: String! { get }
    var subAdministrativeArea: String! { get }
    var postalCode: String! { get }
    var ISOcountryCode: String! { get }
    var country: String! { get }
    var inlandWater: String! { get }
    var ocean: String! { get }
    var areasOfInterest: [AnyObject]! { get }
}
To
class CLPlacemark : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init(placemark placemark: CLPlacemark)
    @NSCopying var location: CLLocation? { get }
    @NSCopying var region: CLRegion? { get }
    @NSCopying var timeZone: NSTimeZone? { get }
    var addressDictionary: [NSObject : AnyObject]? { get }
    var name: String? { get }
    var thoroughfare: String? { get }
    var subThoroughfare: String? { get }
    var locality: String? { get }
    var subLocality: String? { get }
    var administrativeArea: String? { get }
    var subAdministrativeArea: String? { get }
    var postalCode: String? { get }
    var ISOcountryCode: String? { get }
    var country: String? { get }
    var inlandWater: String? { get }
    var ocean: String? { get }
    var areasOfInterest: [String]? { get }
}

Declaration
From
var addressDictionary: [NSObject : AnyObject]! { get }
To
var addressDictionary: [NSObject : AnyObject]? { get }

Declaration
From
var administrativeArea: String! { get }
To
var administrativeArea: String? { get }

Declaration
From
var areasOfInterest: [AnyObject]! { get }
To
var areasOfInterest: [String]? { get }

Declaration
From
var country: String! { get }
To
var country: String? { get }

Declaration
From
init!(placemark placemark: CLPlacemark!)
To
init(placemark placemark: CLPlacemark)

Declaration
From
var inlandWater: String! { get }
To
var inlandWater: String? { get }

Declaration
From
var ISOcountryCode: String! { get }
To
var ISOcountryCode: String? { get }

Declaration
From
var locality: String! { get }
To
var locality: String? { get }

Declaration
From
@NSCopying var location: CLLocation! { get }
To
@NSCopying var location: CLLocation? { get }

Declaration
From
var name: String! { get }
To
var name: String? { get }

Declaration
From
var ocean: String! { get }
To
var ocean: String? { get }

Declaration
From
var postalCode: String! { get }
To
var postalCode: String? { get }

Declaration
From
@NSCopying var region: CLRegion! { get }
To
@NSCopying var region: CLRegion? { get }

Declaration
From
var subAdministrativeArea: String! { get }
To
var subAdministrativeArea: String? { get }

Declaration
From
var subLocality: String! { get }
To
var subLocality: String? { get }

Declaration
From
var subThoroughfare: String! { get }
To
var subThoroughfare: String? { get }

Declaration
From
var thoroughfare: String! { get }
To
var thoroughfare: String? { get }

Raw Value Type
From--
ToInt

Modified CLRegion
Declaration
From
class CLRegion : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init!(circularRegionWithCenter center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String!)
    var center: CLLocationCoordinate2D { get }
    var radius: CLLocationDistance { get }
    var identifier: String! { get }
    var notifyOnEntry: Bool
    var notifyOnExit: Bool
    func containsCoordinate(_ coordinate: CLLocationCoordinate2D) -> Bool
}
To
class CLRegion : NSObject, NSCopying, NSSecureCoding, NSCoding {
    init(circularRegionWithCenter center: CLLocationCoordinate2D, radius radius: CLLocationDistance, identifier identifier: String)
    var center: CLLocationCoordinate2D { get }
    var radius: CLLocationDistance { get }
    var identifier: String { get }
    var notifyOnEntry: Bool
    var notifyOnExit: Bool
    func containsCoordinate(_ coordinate: CLLocationCoordinate2D) -> Bool
}

Declaration
From
var identifier: String! { get }
To
var identifier: String { get }

Raw Value Type
From--
ToInt

Modified CLVisit
Declaration
From
class CLVisit : NSObject, NSSecureCoding, NSCoding, NSCopying {
    @NSCopying var arrivalDate: NSDate! { get }
    @NSCopying var departureDate: NSDate! { get }
    var coordinate: CLLocationCoordinate2D { get }
    var horizontalAccuracy: CLLocationAccuracy { get }
}
To
class CLVisit : NSObject, NSSecureCoding, NSCoding, NSCopying {
    @NSCopying var arrivalDate: NSDate { get }
    @NSCopying var departureDate: NSDate { get }
    var coordinate: CLLocationCoordinate2D { get }
    var horizontalAccuracy: CLLocationAccuracy { get }
}

Declaration
From
@NSCopying var arrivalDate: NSDate! { get }
To
@NSCopying var arrivalDate: NSDate { get }

Declaration
From
@NSCopying var departureDate: NSDate! { get }
To
@NSCopying var departureDate: NSDate { get }

Declaration
From
typealias CLGeocodeCompletionHandler = ([AnyObject]!, NSError!) -> Void
To
typealias CLGeocodeCompletionHandler = ([CLPlacemark]?, NSError?) -> Void