Returns a predicate to find the contacts matching the specified name.
SDKs
- iOS 9.0+
- macOS 10.11+
- Mac Catalyst 13.0+
- watchOS 2.0+
Framework
- Contacts
Declaration
class func predicateForContacts(matchingName name: String) -> NSPredicate
Parameters
name
The contact name to be matched.
Return Value
A predicate that you can use to fetch contacts from CNContact
.
Discussion
The name can contain any number of words.