Home | History | Annotate | Download | only in search

Lines Matching defs:database

52 import android.database.Cursor;
53 import android.database.sqlite.SQLiteDatabase;
54 import android.database.sqlite.SQLiteException;
166 * Drop the currently stored database, and clear the flags which mark the database as indexed.
169 // Drop the database when the locale or build has changed. This eliminates rows which are
176 * Adds new data to the database and verifies the correctness of the ENABLED column.
182 * @param needsReindexing true the database needs to be rebuilt.
188 final SQLiteDatabase database = getWritableDatabase();
189 if (database == null) {
190 Log.w(LOG_TAG, "Cannot indexDatabase Index as I cannot get a writable database");
195 database.beginTransaction();
199 insertIndexData(database, indexData);
204 updateDataInDatabase(database, nonIndexableKeys);
207 database.setTransactionSuccessful();
209 database.endTransaction();
222 * Inserts all of the entries in {@param indexData} into the {@param database}
226 void insertIndexData(SQLiteDatabase database, List<IndexData> indexData) {
255 database.replaceOrThrow(TABLE_PREFS_INDEX, null, values);
265 database.replaceOrThrow(IndexDatabaseHelper.Tables.TABLE_SITE_MAP,
276 * @param database The database to validate.
280 void updateDataInDatabase(SQLiteDatabase database,
285 final Cursor enabledResults = database.query(TABLE_PREFS_INDEX, SELECT_COLUMNS,
307 database.update(TABLE_PREFS_INDEX, enabledToDisabledValue, whereClause, null);
312 final Cursor disabledResults = database.query(TABLE_PREFS_INDEX, SELECT_COLUMNS,
334 database.update(TABLE_PREFS_INDEX, disabledToEnabledValue, whereClause, null);
344 Log.e(LOG_TAG, "Cannot open writable database", e);