【发布时间】:2024-04-23 15:25:02
【问题描述】:
我试图理解 objC 中方法名称之前的“某物”的含义。举个例子:
- (BOOL)peoplePickerNavigationController:(ABPeoplePickerNavigationController *)peoplePicker
shouldContinueAfterSelectingPerson:(ABRecordRef)person
property:(ABPropertyID)property
identifier:(ABMultiValueIdentifier)identifier
方法名是shouldContinueAfterSelectingPerson,方法有三个参数,有一个返回值(BOOL),但是peoplePickerNavigationController:(ABPeoplePickerNavigationController *)的作用是什么?
不是返回值,也不是方法参数(因为在方法名之前),那又是什么呢?
【问题讨论】:
标签: objective-c syntax methods