/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/ |
D | ContactsDatabaseHelperTest.java | 49 private ContactsDatabaseHelper mDbHelper; field in ContactsDatabaseHelperTest 55 mDbHelper = getContactsProvider().getDatabaseHelper(); in setUp() 56 mDb = mDbHelper.getWritableDatabase(); in setUp() 67 assertNull(mDbHelper.getAccountIdOrNull(a1)); in testGetOrCreateAccountId() 68 assertNull(mDbHelper.getAccountIdOrNull(a2)); in testGetOrCreateAccountId() 69 assertNull(mDbHelper.getAccountIdOrNull(a3)); in testGetOrCreateAccountId() 70 assertNull(mDbHelper.getAccountIdOrNull(a4)); in testGetOrCreateAccountId() 71 assertNull(mDbHelper.getAccountIdOrNull(a5)); in testGetOrCreateAccountId() 74 final long a1id = mDbHelper.getOrCreateAccountIdInTransaction(a1); in testGetOrCreateAccountId() 75 final long a2id = mDbHelper.getOrCreateAccountIdInTransaction(a2); in testGetOrCreateAccountId() [all …]
|
D | CallLogProviderTestable.java | 25 private CallLogDatabaseHelperTestable mDbHelper; field in CallLogProviderTestable 32 mDbHelper); in setContactsDbForMigration() 38 if (mDbHelper == null) { in getDatabaseHelper() 39 mDbHelper = new CallLogDatabaseHelperTestable(context, mContactsDbForMigration); in getDatabaseHelper() 41 return mDbHelper; in getDatabaseHelper()
|
D | SecondaryUserContactsProvider2.java | 25 private ContactsDatabaseHelper mDbHelper; field in SecondaryUserContactsProvider2 33 if (mDbHelper == null) { in newDatabaseHelper() 34 mDbHelper = ContactsDatabaseHelper.getNewInstanceForTest(context, in newDatabaseHelper() 37 return mDbHelper; in newDatabaseHelper()
|
/packages/providers/ContactsProvider/src/com/android/providers/contacts/ |
D | DataRowHandler.java | 79 protected final ContactsDatabaseHelper mDbHelper; field in DataRowHandler 89 mDbHelper = dbHelper; in DataRowHandler() 104 mMimetypeId = mDbHelper.getMimeTypeId(mMimetype); in getMimeTypeId() 123 mDbHelper.setIsPrimary(rawContactId, dataId, mimeTypeId); in insert() 130 mDbHelper.setIsSuperPrimary(rawContactId, dataId, mimeTypeId); in insert() 132 mDbHelper.clearSuperPrimary(rawContactId, mimeTypeId); in insert() 137 if (mDbHelper.rawContactHasSuperPrimary(rawContactId, mimeTypeId)) { in insert() 138 mDbHelper.setIsSuperPrimary(rawContactId, dataId, mimeTypeId); in insert() 200 final String photoHashId= mDbHelper.getPhotoHashId(); in handleHashIdForInsert() 206 hashId = mDbHelper.generateHashId(data1, data2); in handleHashIdForInsert() [all …]
|
D | ContactMetadataProvider.java | 90 private ContactsDatabaseHelper mDbHelper; field in ContactMetadataProvider 98 mDbHelper = getDatabaseHelper(context); in onCreate() 115 mDbHelper = helper; in setDatabaseHelper() 155 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in query() 183 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in insert() 201 throw new IllegalArgumentException(mDbHelper.exceptionMessage( in insert() 214 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in delete() 249 throw new IllegalArgumentException(mDbHelper.exceptionMessage( in delete() 262 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in update() 272 throw new IllegalArgumentException(mDbHelper.exceptionMessage( in update() [all …]
|
D | SearchIndexManager.java | 243 private final ContactsDatabaseHelper mDbHelper; field in SearchIndexManager 251 mDbHelper = (ContactsDatabaseHelper) mContactsProvider.getDatabaseHelper(); in SearchIndexManager() 262 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in updateIndex() 282 mDbHelper.createSearchIndexTable(db, true); in rebuildIndex() 328 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in updateIndexForRawContacts() 349 mSb.append(mDbHelper.getMimeTypeId(Nickname.CONTENT_ITEM_TYPE)); in buildAndInsertIndex() 352 mSb.append(mDbHelper.getMimeTypeId(Organization.CONTENT_ITEM_TYPE)); in buildAndInsertIndex() 355 mSb.append(mDbHelper.getMimeTypeId(StructuredPostal.CONTENT_ITEM_TYPE)); in buildAndInsertIndex() 358 mSb.append(mDbHelper.getMimeTypeId(Email.CONTENT_ITEM_TYPE)); in buildAndInsertIndex() 406 return Integer.parseInt(mDbHelper.getProperty(PROPERTY_SEARCH_INDEX_VERSION, "0")); in getSearchIndexVersion() [all …]
|
D | VoicemailStatusTable.java | 62 private final CallLogDatabaseHelper mDbHelper; field in VoicemailStatusTable 69 mDbHelper = dbHelper; in VoicemailStatusTable() 76 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in insert() 115 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in delete() 132 SQLiteDatabase db = mDbHelper.getReadableDatabase(); in query() 146 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in update() 173 return mDbHelper.selectDistinctColumn(mTableName, Status.SOURCE_PACKAGE); in getSourcePackages()
|
D | VoicemailContentTable.java | 91 private final CallLogDatabaseHelper mDbHelper; field in VoicemailContentTable 101 mDbHelper = dbHelper; in VoicemailContentTable() 146 DatabaseModifier modifier = createDatabaseModifier(mDbHelper.getWritableDatabase()); in insert() 153 DatabaseModifier modifier = createDatabaseModifier(mDbHelper.getWritableDatabase()); in bulkInsert() 191 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in insertRow() 232 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in delete() 274 SQLiteDatabase db = mDbHelper.getReadableDatabase(); in query() 289 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in update() 322 return mDbHelper.selectDistinctColumn(mTableName, Voicemails.SOURCE_PACKAGE); in getSourcePackages()
|
D | ContactsProvider2.java | 1381 private final ThreadLocal<ContactsDatabaseHelper> mDbHelper = field in ContactsProvider2 1535 mDbHelper.set(mContactsHelper); in initialize() 1776 final SQLiteDatabase db = mDbHelper.get().getWritableDatabase(); in performBackgroundTask() 1925 final SQLiteDatabase db = mDbHelper.get().getWritableDatabase(); in cleanupPhotoStore() 1930 long photoMimeTypeId = mDbHelper.get().getMimeTypeId(Photo.CONTENT_ITEM_TYPE); in cleanupPhotoStore() 2163 mDbHelper.set(mProfileHelper); in switchToProfileMode() 2178 mDbHelper.set(mContactsHelper); in switchToContactMode() 2250 undemoteContact(mDbHelper.get().getWritableDatabase(), id); in call() 2269 final SQLiteDatabase db = mDbHelper.get().getWritableDatabase(); in preAuthorizeUri() 2289 final SQLiteDatabase db = mDbHelper.get().getWritableDatabase(); in isValidPreAuthorizedUri() [all …]
|
D | CallLogProvider.java | 183 private CallLogDatabaseHelper mDbHelper; field in CallLogProvider 213 mDbHelper = getDatabaseHelper(context); in onCreate() 353 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in queryInternal() 479 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in insertInternal() 514 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in updateInternal() 543 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in deleteInternal() 728 mDbHelper.getWritableDatabase().execSQL( in adjustForNewPhoneAccountInternal() 738 mDbHelper.getWritableDatabase().execSQL(UNHIDE_BY_ADDRESS_QUERY, in adjustForNewPhoneAccountInternal() 758 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in copyEntriesFromCursor() 815 return Long.valueOf(mDbHelper.getProperty(getLastSyncTimePropertyName(forShadow), "0")); in getLastSyncTime() [all …]
|
D | DataRowHandlerForEmail.java | 44 String address = mDbHelper.insertNameLookupForEmail(rawContactId, dataId, email); in insert() 63 mDbHelper.deleteNameLookup(dataId); in update() 64 mDbHelper.insertNameLookupForEmail(rawContactId, dataId, address); in update() 79 mDbHelper.deleteNameLookup(dataId); in delete()
|
D | DataRowHandlerForNickname.java | 47 mDbHelper.insertNameLookupForNickname(rawContactId, dataId, nickname); in insert() 65 mDbHelper.deleteNameLookup(dataId); in update() 66 mDbHelper.insertNameLookupForNickname(rawContactId, dataId, nickname); in update() 81 mDbHelper.deleteNameLookup(dataId); in delete()
|
D | AbstractContactsProvider.java | 85 private ContactsDatabaseHelper mDbHelper; field in AbstractContactsProvider 124 mDbHelper = newDatabaseHelper(context); in onCreate() 130 return mDbHelper; in getDatabaseHelper() 427 if (mDbHelper == null) { in dump() 434 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in dump()
|
D | LegacyApiSupport.java | 469 private final ContactsDatabaseHelper mDbHelper; field in LegacyApiSupport 492 mDbHelper = contactsDatabaseHelper; in LegacyApiSupport() 499 SQLiteDatabase db = mDbHelper.getReadableDatabase(); in LegacyApiSupport() 510 mMimetypeEmail = mDbHelper.getMimeTypeId(Email.CONTENT_ITEM_TYPE); in LegacyApiSupport() 511 mMimetypeIm = mDbHelper.getMimeTypeId(Im.CONTENT_ITEM_TYPE); in LegacyApiSupport() 512 mMimetypePostal = mDbHelper.getMimeTypeId(StructuredPostal.CONTENT_ITEM_TYPE); in LegacyApiSupport() 809 throw new UnsupportedOperationException(mDbHelper.exceptionMessage(uri)); in insert() 938 throw new UnsupportedOperationException(mDbHelper.exceptionMessage(uri)); in update() 1189 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in updateSettings() 1270 SQLiteDatabase db = mDbHelper.getWritableDatabase(); in copySettingsToLegacySettings() [all …]
|
/packages/providers/TelephonyProvider/tests/src/com/android/providers/telephony/ |
D | CarrierProviderTestable.java | 31 private InMemoryCarrierProviderDbHelper mDbHelper; field in CarrierProviderTestable 36 mDbHelper = new InMemoryCarrierProviderDbHelper(); in onCreate() 42 mDbHelper.close(); in closeDatabase() 47 Log.d(TAG, "getReadableDatabase called" + mDbHelper.getReadableDatabase()); in getReadableDatabase() 48 return mDbHelper.getReadableDatabase(); in getReadableDatabase() 53 Log.d(TAG, "getWritableDatabase called" + mDbHelper.getWritableDatabase()); in getWritableDatabase() 54 return mDbHelper.getWritableDatabase(); in getWritableDatabase()
|
D | CarrierIdProviderTestable.java | 30 private InMemoryCarrierIdProviderDbHelper mDbHelper; field in CarrierIdProviderTestable 35 mDbHelper = new InMemoryCarrierIdProviderDbHelper(); in onCreate() 41 mDbHelper.close(); in closeDatabase() 46 Log.d(TAG, "getReadableDatabase called" + mDbHelper.getReadableDatabase()); in getReadableDatabase() 47 return mDbHelper.getReadableDatabase(); in getReadableDatabase() 52 Log.d(TAG, "getWritableDatabase called" + mDbHelper.getWritableDatabase()); in getWritableDatabase() 53 return mDbHelper.getWritableDatabase(); in getWritableDatabase()
|
D | TelephonyProviderTestable.java | 42 private InMemoryTelephonyProviderDbHelper mDbHelper; field in TelephonyProviderTestable 57 mDbHelper = new InMemoryTelephonyProviderDbHelper(); in onCreate() 64 mDbHelper.close(); in closeDatabase() 70 return mDbHelper.getReadableDatabase(); in getReadableDatabase() 76 return mDbHelper.getWritableDatabase(); in getWritableDatabase()
|
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/ |
D | FileCache.java | 60 private DatabaseHelper mDbHelper; field in FileCache 92 mDbHelper = new DatabaseHelper(context, dbName); in FileCache() 97 mDbHelper.close(); in close() 124 mDbHelper.getWritableDatabase(), entry); in store() 150 mDbHelper.getWritableDatabase().delete( in lookup() 168 Cursor cursor = mDbHelper.getReadableDatabase().query(TABLE_NAME, in queryDatabase() 185 mDbHelper.getWritableDatabase().update(TABLE_NAME, in updateLastAccess() 203 Cursor cursor = mDbHelper.getReadableDatabase().query( in initialize() 219 Cursor cursor = mDbHelper.getReadableDatabase().query( in freeSomeSpaceIfNeed() 238 mDbHelper.getWritableDatabase().delete(TABLE_NAME, in freeSomeSpaceIfNeed()
|
/packages/providers/CalendarProvider/tests/src/com/android/providers/calendar/ |
D | CalendarCacheTest.java | 31 private SQLiteOpenHelper mDbHelper; field in CalendarCacheTest 40 mDbHelper = CalendarDatabaseHelper.getInstance(getContext()); in setUp() 41 mCalendarCache = new CalendarCache(mDbHelper); in setUp() 46 if (mDbHelper != null) { in tearDown() 47 mDbHelper.close(); in tearDown() 48 mDbHelper = null; in tearDown()
|
/packages/providers/ContactsProvider/src/com/android/providers/contacts/aggregation/ |
D | AbstractContactAggregator.java | 146 protected final ContactsDatabaseHelper mDbHelper; field in AbstractContactAggregator 279 mDbHelper = contactsDatabaseHelper; in AbstractContactAggregator() 284 SQLiteDatabase db = mDbHelper.getReadableDatabase(); in AbstractContactAggregator() 387 mMimeTypeIdEmail = mDbHelper.getMimeTypeId(Email.CONTENT_ITEM_TYPE); in AbstractContactAggregator() 388 mMimeTypeIdIdentity = mDbHelper.getMimeTypeId(Identity.CONTENT_ITEM_TYPE); in AbstractContactAggregator() 389 mMimeTypeIdPhoto = mDbHelper.getMimeTypeId(Photo.CONTENT_ITEM_TYPE); in AbstractContactAggregator() 390 mMimeTypeIdPhone = mDbHelper.getMimeTypeId(Phone.CONTENT_ITEM_TYPE); in AbstractContactAggregator() 395 mDbHelper.getMimeTypeIdForStructuredName(), mMimeTypeIdPhoto, mMimeTypeIdPhone); in AbstractContactAggregator() 399 mDbHelper.getMimeTypeIdForStructuredName(), mMimeTypeIdPhoto, mMimeTypeIdPhone); in AbstractContactAggregator() 506 int aggregationMode = mDbHelper.getAggregationMode(rawContactId); in triggerAggregation() [all …]
|
/packages/services/Car/car-usb-handler/src/android/car/usb/handler/ |
D | UsbSettingsStorage.java | 46 private final UsbSettingsDbHelper mDbHelper; field in UsbSettingsStorage 49 mDbHelper = new UsbSettingsDbHelper(context); in UsbSettingsStorage() 79 try (SQLiteDatabase db = mDbHelper.getReadableDatabase(); in getSettings() 98 try (SQLiteDatabase db = mDbHelper.getWritableDatabase()) { in saveSettings() 113 try (SQLiteDatabase db = mDbHelper.getWritableDatabase()) { in deleteSettings() 134 try (SQLiteDatabase db = mDbHelper.getReadableDatabase(); in getAllSettings()
|
/packages/providers/TelephonyProvider/src/com/android/providers/telephony/ |
D | CarrierProvider.java | 41 private CarrierDatabaseHelper mDbHelper; field in CarrierProvider 51 mDbHelper = new CarrierDatabaseHelper(getContext()); in onCreate() 130 return mDbHelper.getReadableDatabase(); in getReadableDatabase() 133 return mDbHelper.getWritableDatabase(); in getWritableDatabase()
|
D | HbpcdLookupProvider.java | 146 private HbpcdLookupDatabaseHelper mDbHelper; field in HbpcdLookupProvider 153 mDbHelper = new HbpcdLookupDatabaseHelper(getContext()); in onCreate() 155 mDbHelper.getReadableDatabase(); in onCreate() 304 SQLiteDatabase db = mDbHelper.getReadableDatabase(); in query() 326 final SQLiteDatabase db = mDbHelper.getWritableDatabase(); in update()
|
/packages/providers/CalendarProvider/src/com/android/providers/calendar/ |
D | CalendarProvider2.java | 193 private CalendarDatabaseHelper mDbHelper; field in CalendarProvider2 502 if (mDbHelper != null) { in shutdown() 503 mDbHelper.close(); in shutdown() 504 mDbHelper = null; in shutdown() 527 mDbHelper = (CalendarDatabaseHelper)getDatabaseHelper(); in initialize() 528 mDb = mDbHelper.getWritableDatabase(); in initialize() 530 mMetaData = new MetaData(mDbHelper); in initialize() 531 mInstancesHelper = new CalendarInstancesHelper(mDbHelper, mMetaData); in initialize() 546 mCalendarCache = new CalendarCache(mDbHelper); in initialize() 972 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in queryInternal() [all …]
|
D | CalendarInstancesHelper.java | 61 private final CalendarDatabaseHelper mDbHelper; field in CalendarInstancesHelper 131 mDbHelper = calendarDbHelper; in CalendarInstancesHelper() 133 mCalendarCache = new CalendarCache(mDbHelper); in CalendarInstancesHelper() 522 mDbHelper.instancesReplace(values); in performInstanceExpansion() 593 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in getEntries() 713 mDbHelper.instancesInsert(instanceValues); in updateInstancesLocked() 860 final SQLiteDatabase db = mDbHelper.getReadableDatabase(); in getRelevantRecurrenceEntries()
|