Home
last modified time | relevance | path

Searched refs:contactId (Results 1 – 25 of 91) sorted by relevance

1234

/packages/providers/ContactsProvider/src/com/android/providers/contacts/aggregation/util/
DContactMatcher.java163 private MatchScore getMatchingScore(long contactId) { in getMatchingScore() argument
164 MatchScore matchingScore = mScores.get(contactId); in getMatchingScore()
168 matchingScore.reset(contactId); in getMatchingScore()
170 matchingScore = new MatchScore(contactId); in getMatchingScore()
174 mScores.put(contactId, matchingScore); in getMatchingScore()
182 public void matchIdentity(long contactId) { in matchIdentity() argument
183 updatePrimaryScore(contactId, MatchScore.MAX_SCORE); in matchIdentity()
193 public void matchName(long contactId, int candidateNameType, String candidateName, in matchName() argument
201 updatePrimaryScore(contactId, maxScore); in matchName()
241 updatePrimaryScore(contactId, score); in matchName()
[all …]
DRawContactMatcher.java168 private MatchScore getMatchingScore(long rawContactId, long contactId, long accountId) { in getMatchingScore() argument
173 matchingScore.reset(rawContactId, contactId, accountId); in getMatchingScore()
175 matchingScore = new MatchScore(rawContactId, contactId, accountId); in getMatchingScore()
191 public void matchName(long rawContactId, long contactId, long accountId, int in matchName() argument
199 updatePrimaryScore(rawContactId, contactId, accountId, maxScore); in matchName()
239 updatePrimaryScore(rawContactId, contactId, accountId, score); in matchName()
242 public void matchIdentity(long rawContactId, long contactId, long accountId) { in matchIdentity() argument
243 updateSecondaryScore(rawContactId, contactId, accountId, IDENTITY_MATCH_SCORE); in matchIdentity()
246 public void updateScoreWithPhoneNumberMatch(long rawContactId, long contactId, long accountId) { in updateScoreWithPhoneNumberMatch() argument
247 updateSecondaryScore(rawContactId, contactId, accountId, PHONE_MATCH_SCORE); in updateScoreWithPhoneNumberMatch()
[all …]
DMatchScore.java38 public MatchScore(long rawContactId, long contactId, long accountId) { in MatchScore() argument
40 this.mContactId = contactId; in MatchScore()
44 public MatchScore(long contactId) { in MatchScore() argument
46 this.mContactId = contactId; in MatchScore()
50 public void reset(long rawContactId, long contactId, long accountId) { in reset() argument
52 this.mContactId = contactId; in reset()
61 public void reset(long contactId) { in reset() argument
62 this.reset(0l, contactId, 0l); in reset()
/packages/providers/ContactsProvider/src/com/android/providers/contacts/aggregation/
DContactAggregator.java94 long contactId = -1; // Best matching contact ID. in aggregateContact() local
104 contactId = pickBestMatchBasedOnExceptions(db, rawContactId, matcher); in aggregateContact()
105 if (contactId == -1) { in aggregateContact()
111 contactId = pickBestMatchBasedOnData(db, rawContactId, candidates, matcher); in aggregateContact()
116 if (contactId != -1 && contactId != currentContactId) { in aggregateContact()
123 mSelectionArgs2[0] = String.valueOf(contactId); in aggregateContact()
159 contactId = -1; in aggregateContact()
181 if (contactId == -1 in aggregateContact()
185 contactId = currentContactId; in aggregateContact()
188 if (contactId == currentContactId) { in aggregateContact()
[all …]
DAbstractContactAggregator.java516 long contactId = mDbHelper.getContactId(rawContactId); in triggerAggregation() local
518 if (contactId != 0) { in triggerAggregation()
519 updateAggregateData(txContext, contactId); in triggerAggregation()
574 protected final void markContactForAggregation(SQLiteDatabase db, long contactId) { in markContactForAggregation() argument
575 mSelectionArgs1[0] = String.valueOf(contactId); in markContactForAggregation()
643 long contactId = insertContact(db, rawContactId); in onRawContactInsert() local
644 setContactId(rawContactId, contactId); in onRawContactInsert()
645 mDbHelper.updateContactVisible(txContext, contactId); in onRawContactInsert()
646 return contactId; in onRawContactInsert()
678 long contactId = 0; in aggregateContact() local
[all …]
DContactAggregator2.java333 Long contactId = null; in reAggregateRawContacts() local
342 contactId = currentCidForRawContact; in reAggregateRawContacts()
345 if (cid != null && !cid.equals(contactId)) { in reAggregateRawContacts()
358 contactId = currentContactId; in reAggregateRawContacts()
367 createContactForRawContacts(db, txContext, connectedRawContactIds, contactId); in reAggregateRawContacts()
399 private boolean canBeReused(SQLiteDatabase db, Long contactId, in canBeReused() argument
404 mSelectionArgs1[0] = String.valueOf(contactId); in canBeReused()
459 public void updateAggregationAfterVisibilityChange(long contactId) { in updateAggregationAfterVisibilityChange() argument
461 boolean visible = mDbHelper.isContactInDefaultDirectory(db, contactId); in updateAggregationAfterVisibilityChange()
463 markContactForAggregation(db, contactId); in updateAggregationAfterVisibilityChange()
[all …]
/packages/apps/Contacts/tests/src/com/android/contacts/tests/allintents/
DAllIntentsActivity.java268 long contactId = findArbitraryContactWithPhoneNumber(); in onListItemClick() local
269 if (contactId != -1) { in onListItemClick()
270 Uri contactUri = ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId); in onListItemClick()
278 final long contactId = findArbitraryContactWithPhoneNumber(); in onListItemClick() local
279 if (contactId != -1) { in onListItemClick()
280 final Uri uri = ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId); in onListItemClick()
287 final long contactId = findArbitraryContactWithPhoneNumber(); in onListItemClick() local
288 if (contactId != -1) { in onListItemClick()
289 final Uri uri = ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId); in onListItemClick()
300 final long contactId = findArbitraryContactWithPhoneNumber(); in onListItemClick() local
[all …]
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/testutil/
DDatabaseAsserts.java60 long contactId = RawContactUtil.queryContactIdByRawContactId(resolver, rawContactId); in assertAndCreateContact() local
61 MoreAsserts.assertNotEqual(CommonDatabaseUtils.NOT_FOUND, contactId); in assertAndCreateContact()
63 return new ContactIdPair(contactId, rawContactId); in assertAndCreateContact()
75 long contactId = RawContactUtil.queryContactIdByRawContactId(resolver, rawContactId); in assertAndCreateContactWithName() local
76 MoreAsserts.assertNotEqual(CommonDatabaseUtils.NOT_FOUND, contactId); in assertAndCreateContactWithName()
78 return new ContactIdPair(contactId, rawContactId); in assertAndCreateContactWithName()
88 public static void assertHasDeleteLogGreaterThan(ContentResolver resolver, long contactId, in assertHasDeleteLogGreaterThan() argument
90 Assert.assertFalse(ContactUtil.recordExistsForContactId(resolver, contactId)); in assertHasDeleteLogGreaterThan()
93 contactId); in assertHasDeleteLogGreaterThan()
105 public ContactIdPair(long contactId, long rawContactId) { in ContactIdPair() argument
[all …]
DContactUtil.java33 public static void update(ContentResolver resolver, long contactId, in update() argument
35 Uri uri = ContentUris.withAppendedId(URI, contactId); in update()
39 public static void delete(ContentResolver resolver, long contactId) { in delete() argument
40 Uri uri = ContentUris.withAppendedId(URI, contactId); in delete()
44 public static boolean recordExistsForContactId(ContentResolver resolver, long contactId) { in recordExistsForContactId() argument
48 Uri uri = ContentUris.withAppendedId(URI, contactId); in recordExistsForContactId()
56 public static long queryContactLastUpdatedTimestamp(ContentResolver resolver, long contactId) { in queryContactLastUpdatedTimestamp() argument
61 Uri uri = ContentUris.withAppendedId(ContactsContract.Contacts.CONTENT_URI, contactId); in queryContactLastUpdatedTimestamp()
/packages/services/Car/car-cluster-demo-renderer/src/android/car/cluster/demorenderer/
DPhoneBook.java128 public void getContactPictureAsync(int contactId, ContactPhotoLoadedListener listener) { in getContactPictureAsync() argument
130 if (mContactsWithoutImage != null && mContactsWithoutImage.contains(contactId)) { in getContactPictureAsync()
131 listener.onPhotoLoaded(contactId, null); in getContactPictureAsync()
143 Bitmap photo = mContactPhotoById.get(contactId); in getContactPictureAsync()
145 listener.onPhotoLoaded(contactId, photo); in getContactPictureAsync()
151 fetchPhotoAsync(contactId, listener); in getContactPictureAsync()
173 void onPhotoLoaded(int contactId, @Nullable Bitmap picture); in onPhotoLoaded() argument
186 private void fetchPhotoAsync(int contactId, ContactPhotoLoadedListener listener) { in fetchPhotoAsync() argument
187 LoadPhotoAsyncTask.createAndExecute(this, contactId, listener); in fetchPhotoAsync()
190 private void cacheContactPhoto(int contactId, Bitmap bitmap) { in cacheContactPhoto() argument
[all …]
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/
DContactLookupKeyTest.java54 long contactId = queryContactId(rawContactId1); in testLookupKeyUsingDisplayNameAndNoAccount() local
55 assertStoredValue(ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId), in testLookupKeyUsingDisplayNameAndNoAccount()
60 assertStoredValue(lookupUri, Contacts._ID, contactId); in testLookupKeyUsingDisplayNameAndNoAccount()
63 assertStoredValue(ContentUris.withAppendedId(lookupUri, contactId), in testLookupKeyUsingDisplayNameAndNoAccount()
64 Contacts._ID, contactId); in testLookupKeyUsingDisplayNameAndNoAccount() local
67 assertStoredValue(ContentUris.withAppendedId(lookupUri, contactId + 1), in testLookupKeyUsingDisplayNameAndNoAccount()
68 Contacts._ID, contactId); in testLookupKeyUsingDisplayNameAndNoAccount() local
89 long contactId = queryContactId(rawContactId1); in testLookupKeyUsingSourceIdAndNoAccount() local
90 assertStoredValue(ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId), in testLookupKeyUsingSourceIdAndNoAccount()
94 assertStoredValue(lookupUri, Contacts._ID, contactId); in testLookupKeyUsingSourceIdAndNoAccount()
[all …]
DSearchIndexManagerTest.java53 long contactId = queryContactId(rawContactId); in testSearchIndexForStructuredName() local
69 contactId, null, "John Doe Bob I Parr Helen I Parr PhD par helen parhelen", null); in testSearchIndexForStructuredName()
74 long contactId = queryContactId(rawContactId); in testSearchIndexForStructuredName_phoneticOnly() local
89 assertSearchIndex(contactId, null, "yamada taro", null); in testSearchIndexForStructuredName_phoneticOnly()
99 long contactId = queryContactId(rawContactId); in testSearchIndexForChineseName() local
105 contactId, null, "\u695A\u8FAD \u695A\u8FAD CI \u8FAD CHUCI CC C", null); in testSearchIndexForChineseName()
135 long contactId = queryContactId(rawContactId); in testSearchIndexForKoreanName() local
140 assertSearchIndex(contactId, null, in testSearchIndexForKoreanName()
199 long contactId = queryContactId(rawContactId); in testSearchIndexForOrganization() local
210 assertSearchIndex(contactId, in testSearchIndexForOrganization()
[all …]
DGroupsTest.java232 final long contactId = this.queryContactId(rawContactId); in assertRawContactVisible() local
233 assertContactVisible(contactId, expected); in assertRawContactVisible()
236 public void assertContactVisible(long contactId, boolean expected) { in assertContactVisible() argument
239 }, Contacts._ID + "=" + contactId, null, null); in assertContactVisible()
246 public ContentProviderOperation buildVisibleAssert(long contactId, boolean visible) { in buildVisibleAssert() argument
248 Contacts._ID + "=" + contactId + " AND " + Contacts.IN_VISIBLE_GROUP + "=" in buildVisibleAssert()
260 final long contactId = this.queryContactId(rawContactId); in testDelayVisibleTransaction() local
261 final Uri contactUri = ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId); in testDelayVisibleTransaction()
269 oper.add(buildVisibleAssert(contactId, true)); in testDelayVisibleTransaction()
272 oper.add(buildVisibleAssert(contactId, true)); in testDelayVisibleTransaction()
[all …]
DContactsProvider2Test.java971 long contactId = queryContactId(rawContactId); in testDataDirectoryWithLookupUri() local
972 String lookupKey = queryLookupKey(contactId); in testDataDirectoryWithLookupUri()
975 Uri lookupUri = ContactsContract.Contacts.getLookupUri(contactId, lookupKey); in testDataDirectoryWithLookupUri()
981 lookupUri = ContactsContract.Contacts.getLookupUri(contactId + 1, lookupKey); in testDataDirectoryWithLookupUri()
1023 long contactId = queryContactId(rawContactId1); in testContactEntitiesWithIdBasedUri() local
1025 Uri contactUri = ContentUris.withAppendedId(Contacts.CONTENT_URI, contactId); in testContactEntitiesWithIdBasedUri()
1028 assertEntityRows(entityUri, contactId, rawContactId1, rawContactId2); in testContactEntitiesWithIdBasedUri()
1045 long contactId = queryContactId(rawContactId1); in testContactEntitiesWithLookupUri() local
1046 String lookupKey = queryLookupKey(contactId); in testContactEntitiesWithLookupUri()
1049 Uri contactLookupUri = ContactsContract.Contacts.getLookupUri(contactId, lookupKey); in testContactEntitiesWithLookupUri()
[all …]
/packages/apps/Contacts/src/com/android/contacts/list/
DMultiSelectEntryContactListAdapter.java97 public void toggleSelectionOfContactId(long contactId) { in toggleSelectionOfContactId() argument
98 if (mSelectedContactIds.contains(contactId)) { in toggleSelectionOfContactId()
99 mSelectedContactIds.remove(contactId); in toggleSelectionOfContactId()
101 mSelectedContactIds.add(contactId); in toggleSelectionOfContactId()
129 final long contactId = cursor.getLong(ContactQuery.CONTACT_ID); in bindCheckBox() local
130 checkBox.setChecked(mSelectedContactIds.contains(contactId)); in bindCheckBox()
131 checkBox.setTag(contactId); in bindCheckBox()
139 final Long contactId = (Long) checkBox.getTag();
141 mSelectedContactIds.add(contactId);
143 mSelectedContactIds.remove(contactId);
/packages/apps/Messaging/src/com/android/messaging/util/
DContactUtil.java195 public static void showOrAddContact(final View view, final long contactId, in showOrAddContact() argument
198 if (contactId > ParticipantData.PARTICIPANT_CONTACT_ID_NOT_RESOLVED in showOrAddContact()
201 ContactsContract.Contacts.getLookupUri(contactId, contactLookupKey); in showOrAddContact()
413 private static CursorQueryData lookupStructuredName(final Context context, final long contactId, in lookupStructuredName() argument
421 .appendPath(String.valueOf(contactId)) in lookupStructuredName()
443 public static String lookupFirstName(final Context context, final long contactId) { in lookupFirstName() argument
444 if (isEnterpriseContactId(contactId)) { in lookupFirstName()
450 nameCursor = ContactUtil.lookupStructuredName(context, contactId, true) in lookupFirstName()
469 final String destinationLabel, final long contactId, final String lookupKey, in createRecipientEntry() argument
473 destination, destinationType, destinationLabel, contactId, null, dataId, in createRecipientEntry()
[all …]
/packages/apps/Contacts/src/com/android/contacts/editor/
DAggregationSuggestionEngine.java74 public long contactId; field in AggregationSuggestionEngine.Suggestion
86 return "ID: " + contactId + " rawContacts: " + rawContacts + " name: " + name in toString()
146 public void setContactId(long contactId) { in setContactId() argument
147 if (contactId != mContactId) { in setContactId()
148 mContactId = contactId; in setContactId()
366 final long contactId = cursor.getLong(0); in updateSuggestedContactIds() local
368 Arrays.binarySearch(mSuggestedContactIds, contactId) < 0) { in updateSuggestedContactIds()
371 newIds.add(contactId); in updateSuggestedContactIds()
412 final long contactId = contactCursor.getLong(0); in getSuggestions() local
413 visibleContacts.add(contactId); in getSuggestions()
[all …]
/packages/providers/ContactsProvider/src/com/android/providers/contacts/database/
DContactsTableUtil.java58 public static void updateContactLastUpdateByContactId(SQLiteDatabase db, long contactId) { in updateContactLastUpdateByContactId() argument
63 new String[] {String.valueOf(contactId)}); in updateContactLastUpdateByContactId()
112 public static int deleteContact(SQLiteDatabase db, long contactId) { in deleteContact() argument
113 DeletedContactsTableUtil.insertDeletedContact(db, contactId); in deleteContact()
114 return db.delete(Tables.CONTACTS, Contacts._ID + " = ?", new String[]{contactId + ""}); in deleteContact()
134 long contactId = cursor.getLong(0); in deleteContactIfSingleton() local
139 return deleteContact(db, contactId); in deleteContactIfSingleton()
/packages/apps/Messaging/src/com/android/messaging/datamodel/
DBugleRecipientEntry.java32 final long contactId, final Long directoryId, final long dataId, in BugleRecipientEntry() argument
35 super(entryType, displayName, destination, destinationType, destinationLabel, contactId, in BugleRecipientEntry()
41 final String destinationLabel, final long contactId, final Long directoryId, in constructTopLevelEntry() argument
45 destinationLabel, contactId, directoryId, dataId, (thumbnailUriAsString != null in constructTopLevelEntry()
51 final String destinationLabel, final long contactId, final Long directoryId, in constructSecondLevelEntry() argument
55 destinationLabel, contactId, directoryId, dataId, (thumbnailUriAsString != null in constructSecondLevelEntry()
/packages/providers/ContactsProvider/src/com/android/providers/contacts/enterprise/
DEnterpriseContactsCursorWrapper.java82 final long contactId = super.getLong(contactIdIndices[0]); in getString() local
88 return getCorpThumbnailUri(contactId, getWrappedCursor()); in getString()
94 return getCorpDisplayPhotoUri(contactId, getWrappedCursor()); in getString()
168 private static String getCorpThumbnailUri(long contactId, Cursor originalCursor) { in getCorpThumbnailUri() argument
178 return ContentUris.appendId(Contacts.CORP_CONTENT_URI.buildUpon(), contactId) in getCorpThumbnailUri()
194 private static String getCorpDisplayPhotoUri(long contactId, Cursor originalCursor) { in getCorpDisplayPhotoUri() argument
203 return ContentUris.appendId(Contacts.CORP_CONTENT_URI.buildUpon(), contactId) in getCorpDisplayPhotoUri()
207 return ContentUris.appendId(Contacts.CORP_CONTENT_URI.buildUpon(), contactId) in getCorpDisplayPhotoUri()
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/util/
DAccountImageChangeObserver.java147 long contactId = getContactIdForAccount(context, thisAccount); in registerChangeUriIfPresent() local
148 if (contactId != -1) { in registerChangeUriIfPresent()
150 contactId); in registerChangeUriIfPresent()
174 long contactId = -1; in getContactIdForAccount() local
180 contactId = c.getLong(1); in getContactIdForAccount()
189 if (contactId != -1 && !TextUtils.isEmpty(lookupKey)) { in getContactIdForAccount()
190 return contactId; in getContactIdForAccount()
/packages/providers/ContactsProvider/src/com/android/providers/contacts/
DGlobalSearchSupport.java72 long contactId; field in GlobalSearchSupport.SearchSuggestion
101 list.add(contactId); // _id in asList()
121 list.add(contactId); in addColumnValue()
146 return Contacts.getLookupUri(contactId, lookupKey).toString(); in buildUri()
150 contactId = 0; in reset()
211 long contactId; in handleSearchShortcutRefresh() local
213 contactId = mContactsProvider.lookupContactIdByLookupKey(db, lookupKey); in handleSearchShortcutRefresh()
215 contactId = -1L; in handleSearchShortcutRefresh()
220 db, projection, ContactsColumns.CONCRETE_ID + "=" + contactId, filter, null, in handleSearchShortcutRefresh()
259 suggestion.contactId = c.getLong(0); in addSearchSuggestionsBasedOnFilter()
DContactLookupKey.java40 public long contactId; field in ContactLookupKey.LookupKeySegment
43 if (contactId > another.contactId) { in compareTo()
46 if (contactId < another.contactId) { in compareTo()
251 segment.contactId = -1; in parse()
/packages/apps/Contacts/src/com/android/contacts/group/
DSuggestedMemberListAdapter.java118 public void addNewMember(long contactId) { in addNewMember() argument
119 mExistingMemberContactIds.add(contactId); in addNewMember()
122 public void removeMember(long contactId) { in removeMember() argument
123 if (mExistingMemberContactIds.contains(contactId)) { in removeMember()
124 mExistingMemberContactIds.remove(contactId); in removeMember()
218 long contactId = cursor.getLong(CONTACT_ID_COLUMN_INDEX); in performFiltering() local
220 if (mExistingMemberContactIds.contains(contactId)) { in performFiltering()
226 contactId); in performFiltering()
333 public SuggestedMember(long rawContactId, String displayName, long contactId) { in SuggestedMember() argument
336 mContactId = contactId; in SuggestedMember()
/packages/apps/ContactsCommon/src/com/android/contacts/common/compat/
DContactsCompat.java52 public static boolean isEnterpriseContactId(long contactId) { in isEnterpriseContactId() argument
54 return Contacts.isEnterpriseContactId(contactId); in isEnterpriseContactId()
57 return (contactId >= ENTERPRISE_CONTACT_ID_BASE) && in isEnterpriseContactId()
58 (contactId < ContactsContract.Profile.MIN_ID); in isEnterpriseContactId()

1234