findContactByNameAndPhoneNumber

fun Collection<Contact>.findContactByNameAndPhoneNumber(displayName: String, phoneNumber: String): Contact?

Finds a contact with the specified displayName and phoneNumber.

If no contact with both the specified displayName and phoneNumber is found, but a contact with a different displayName has the specified phoneNumber, then that contact is returned.

Return

The first matching contact or null if none of the contacts in this collection has the specified phone number.