AddressBookUI Changes for Swift
AddressBookUI
Modified ABNewPersonViewController
| Declaration | Deprecation | |
|---|---|---|
| From | class ABNewPersonViewController : UIViewController {
unowned(unsafe) var newPersonViewDelegate: ABNewPersonViewControllerDelegate!
var addressBook: ABAddressBook!
var displayedPerson: ABRecord!
var parentGroup: ABRecord!
} | -- |
| To | class ABNewPersonViewController : UIViewController {
unowned(unsafe) var newPersonViewDelegate: ABNewPersonViewControllerDelegate?
var addressBook: ABAddressBook?
var displayedPerson: ABRecord?
var parentGroup: ABRecord?
} | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var addressBook: ABAddressBook! | -- |
| To | var addressBook: ABAddressBook? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var displayedPerson: ABRecord! | -- |
| To | var displayedPerson: ABRecord? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | unowned(unsafe) var newPersonViewDelegate: ABNewPersonViewControllerDelegate! | -- |
| To | unowned(unsafe) var newPersonViewDelegate: ABNewPersonViewControllerDelegate? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var parentGroup: ABRecord! | -- |
| To | var parentGroup: ABRecord? | iOS 9.0 |
Modified ABNewPersonViewControllerDelegate
| Declaration | |
|---|---|
| From | protocol ABNewPersonViewControllerDelegate : NSObjectProtocol {
func newPersonViewController(_ newPersonView: ABNewPersonViewController!, didCompleteWithNewPerson person: ABRecord!)
} |
| To | protocol ABNewPersonViewControllerDelegate : NSObjectProtocol {
func newPersonViewController(_ newPersonView: ABNewPersonViewController, didCompleteWithNewPerson person: ABRecord?)
} |
| Declaration | Introduction | |
|---|---|---|
| From | func newPersonViewController(_ newPersonView: ABNewPersonViewController!, didCompleteWithNewPerson person: ABRecord!) | iOS 8.0 |
| To | func newPersonViewController(_ newPersonView: ABNewPersonViewController, didCompleteWithNewPerson person: ABRecord?) | iOS 2.0 |
Modified ABPeoplePickerNavigationController
| Declaration | Deprecation | |
|---|---|---|
| From | class ABPeoplePickerNavigationController : UINavigationController {
unowned(unsafe) var peoplePickerDelegate: ABPeoplePickerNavigationControllerDelegate!
var displayedProperties: [AnyObject]!
var addressBook: ABAddressBook!
@NSCopying var predicateForEnablingPerson: NSPredicate!
@NSCopying var predicateForSelectionOfPerson: NSPredicate!
@NSCopying var predicateForSelectionOfProperty: NSPredicate!
} | -- |
| To | class ABPeoplePickerNavigationController : UINavigationController {
unowned(unsafe) var peoplePickerDelegate: ABPeoplePickerNavigationControllerDelegate?
var displayedProperties: [NSNumber]?
var addressBook: ABAddressBook?
@NSCopying var predicateForEnablingPerson: NSPredicate?
@NSCopying var predicateForSelectionOfPerson: NSPredicate?
@NSCopying var predicateForSelectionOfProperty: NSPredicate?
} | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var addressBook: ABAddressBook! | -- |
| To | var addressBook: ABAddressBook? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var displayedProperties: [AnyObject]! | -- |
| To | var displayedProperties: [NSNumber]? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | unowned(unsafe) var peoplePickerDelegate: ABPeoplePickerNavigationControllerDelegate! | -- |
| To | unowned(unsafe) var peoplePickerDelegate: ABPeoplePickerNavigationControllerDelegate? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | @NSCopying var predicateForEnablingPerson: NSPredicate! | -- |
| To | @NSCopying var predicateForEnablingPerson: NSPredicate? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | @NSCopying var predicateForSelectionOfPerson: NSPredicate! | -- |
| To | @NSCopying var predicateForSelectionOfPerson: NSPredicate? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | @NSCopying var predicateForSelectionOfProperty: NSPredicate! | -- |
| To | @NSCopying var predicateForSelectionOfProperty: NSPredicate? | iOS 9.0 |
| Declaration | |
|---|---|
| From | protocol ABPeoplePickerNavigationControllerDelegate : NSObjectProtocol {
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, didSelectPerson person: ABRecord!)
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, didSelectPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier)
optional func peoplePickerNavigationControllerDidCancel(_ peoplePicker: ABPeoplePickerNavigationController!)
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, shouldContinueAfterSelectingPerson person: ABRecord!) -> Bool
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, shouldContinueAfterSelectingPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| To | protocol ABPeoplePickerNavigationControllerDelegate : NSObjectProtocol {
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, didSelectPerson person: ABRecord)
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, didSelectPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier)
optional func peoplePickerNavigationControllerDidCancel(_ peoplePicker: ABPeoplePickerNavigationController)
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, shouldContinueAfterSelectingPerson person: ABRecord) -> Bool
optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, shouldContinueAfterSelectingPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| Declaration | |
|---|---|
| From | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, didSelectPerson person: ABRecord!) |
| To | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, didSelectPerson person: ABRecord) |
| Declaration | |
|---|---|
| From | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, didSelectPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) |
| To | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, didSelectPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) |
| Declaration | |
|---|---|
| From | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, shouldContinueAfterSelectingPerson person: ABRecord!) -> Bool |
| To | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, shouldContinueAfterSelectingPerson person: ABRecord) -> Bool |
| Declaration | |
|---|---|
| From | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController!, shouldContinueAfterSelectingPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool |
| To | optional func peoplePickerNavigationController(_ peoplePicker: ABPeoplePickerNavigationController, shouldContinueAfterSelectingPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool |
| Declaration | Introduction | |
|---|---|---|
| From | optional func peoplePickerNavigationControllerDidCancel(_ peoplePicker: ABPeoplePickerNavigationController!) | iOS 8.0 |
| To | optional func peoplePickerNavigationControllerDidCancel(_ peoplePicker: ABPeoplePickerNavigationController) | iOS 2.0 |
Modified ABPersonViewController
| Declaration | Deprecation | |
|---|---|---|
| From | class ABPersonViewController : UIViewController, UIViewControllerRestoration {
unowned(unsafe) var personViewDelegate: ABPersonViewControllerDelegate!
var addressBook: ABAddressBook!
var displayedPerson: ABRecord!
var displayedProperties: [AnyObject]!
var allowsEditing: Bool
var allowsActions: Bool
var shouldShowLinkedPeople: Bool
func setHighlightedItemForProperty(_ property: ABPropertyID, withIdentifier identifier: ABMultiValueIdentifier)
} | -- |
| To | class ABPersonViewController : UIViewController, UIViewControllerRestoration {
unowned(unsafe) var personViewDelegate: ABPersonViewControllerDelegate?
var addressBook: ABAddressBook?
var displayedPerson: ABRecord
var displayedProperties: [NSNumber]?
var allowsEditing: Bool
var allowsActions: Bool
var shouldShowLinkedPeople: Bool
func setHighlightedItemForProperty(_ property: ABPropertyID, withIdentifier identifier: ABMultiValueIdentifier)
} | iOS 9.0 |
Modified ABPersonViewController.addressBook
| Declaration | Deprecation | |
|---|---|---|
| From | var addressBook: ABAddressBook! | -- |
| To | var addressBook: ABAddressBook? | iOS 9.0 |
Modified ABPersonViewController.allowsActions
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
Modified ABPersonViewController.allowsEditing
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var displayedPerson: ABRecord! | -- |
| To | var displayedPerson: ABRecord | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var displayedProperties: [AnyObject]! | -- |
| To | var displayedProperties: [NSNumber]? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | unowned(unsafe) var personViewDelegate: ABPersonViewControllerDelegate! | -- |
| To | unowned(unsafe) var personViewDelegate: ABPersonViewControllerDelegate? | iOS 9.0 |
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
Modified ABPersonViewControllerDelegate
| Declaration | |
|---|---|
| From | protocol ABPersonViewControllerDelegate : NSObjectProtocol {
func personViewController(_ personViewController: ABPersonViewController!, shouldPerformDefaultActionForPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| To | protocol ABPersonViewControllerDelegate : NSObjectProtocol {
func personViewController(_ personViewController: ABPersonViewController, shouldPerformDefaultActionForPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| Declaration | Introduction | |
|---|---|---|
| From | func personViewController(_ personViewController: ABPersonViewController!, shouldPerformDefaultActionForPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool | iOS 8.0 |
| To | func personViewController(_ personViewController: ABPersonViewController, shouldPerformDefaultActionForPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool | iOS 2.0 |
Modified ABUnknownPersonViewController
| Declaration | Deprecation | |
|---|---|---|
| From | class ABUnknownPersonViewController : UIViewController {
unowned(unsafe) var unknownPersonViewDelegate: ABUnknownPersonViewControllerDelegate!
var addressBook: ABAddressBook!
var displayedPerson: ABRecord!
var alternateName: String!
var message: String!
var allowsActions: Bool
var allowsAddingToAddressBook: Bool
} | -- |
| To | class ABUnknownPersonViewController : UIViewController {
unowned(unsafe) var unknownPersonViewDelegate: ABUnknownPersonViewControllerDelegate?
var addressBook: ABAddressBook?
var displayedPerson: ABRecord
var alternateName: String?
var message: String?
var allowsActions: Bool
var allowsAddingToAddressBook: Bool
} | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var addressBook: ABAddressBook! | -- |
| To | var addressBook: ABAddressBook? | iOS 9.0 |
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
| Deprecation | |
|---|---|
| From | -- |
| To | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var alternateName: String! | -- |
| To | var alternateName: String? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var displayedPerson: ABRecord! | -- |
| To | var displayedPerson: ABRecord | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | var message: String! | -- |
| To | var message: String? | iOS 9.0 |
| Declaration | Deprecation | |
|---|---|---|
| From | unowned(unsafe) var unknownPersonViewDelegate: ABUnknownPersonViewControllerDelegate! | -- |
| To | unowned(unsafe) var unknownPersonViewDelegate: ABUnknownPersonViewControllerDelegate? | iOS 9.0 |
| Declaration | |
|---|---|
| From | protocol ABUnknownPersonViewControllerDelegate : NSObjectProtocol {
func unknownPersonViewController(_ unknownCardViewController: ABUnknownPersonViewController!, didResolveToPerson person: ABRecord!)
optional func unknownPersonViewController(_ personViewController: ABUnknownPersonViewController!, shouldPerformDefaultActionForPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| To | protocol ABUnknownPersonViewControllerDelegate : NSObjectProtocol {
func unknownPersonViewController(_ unknownCardViewController: ABUnknownPersonViewController, didResolveToPerson person: ABRecord?)
optional func unknownPersonViewController(_ personViewController: ABUnknownPersonViewController, shouldPerformDefaultActionForPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool
} |
| Declaration | Introduction | |
|---|---|---|
| From | func unknownPersonViewController(_ unknownCardViewController: ABUnknownPersonViewController!, didResolveToPerson person: ABRecord!) | iOS 8.0 |
| To | func unknownPersonViewController(_ unknownCardViewController: ABUnknownPersonViewController, didResolveToPerson person: ABRecord?) | iOS 2.0 |
| Declaration | |
|---|---|
| From | optional func unknownPersonViewController(_ personViewController: ABUnknownPersonViewController!, shouldPerformDefaultActionForPerson person: ABRecord!, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool |
| To | optional func unknownPersonViewController(_ personViewController: ABUnknownPersonViewController, shouldPerformDefaultActionForPerson person: ABRecord, property property: ABPropertyID, identifier identifier: ABMultiValueIdentifier) -> Bool |
| Declaration | Introduction | Deprecation | |
|---|---|---|---|
| From | func ABCreateStringWithAddressDictionary(_ address: [NSObject : AnyObject]!, _ addCountryName: Bool) -> String! | iOS 8.0 | -- |
| To | func ABCreateStringWithAddressDictionary(_ address: [NSObject : AnyObject], _ addCountryName: Bool) -> String | iOS 2.0 | iOS 9.0 |