Java Code Examples for com.activeandroid.ActiveAndroid#dispose()
The following examples show how to use
com.activeandroid.ActiveAndroid#dispose() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Sensor.java From xDrip with GNU General Public License v3.0 | 5 votes |
public static void DeleteAndInitDb(Context context) {//KS Configuration dbConfiguration = new Configuration.Builder(context).create(); try { ActiveAndroid.dispose(); context.deleteDatabase("DexDrip.db"); //ActiveAndroid.initialize(dbConfiguration); Log.d("wearSENSOR", "DeleteAndInitDb DexDrip.db deleted and initialized."); } catch (Exception e) { Log.e("wearSENSOR", "DeleteAndInitDb CATCH Error."); } }
Example 2
Source File: JoH.java From xDrip with GNU General Public License v3.0 | 5 votes |
public static void fullDatabaseReset() { try { clearCache(); ActiveAndroid.dispose(); ActiveAndroid.initialize(xdrip.getAppContext()); } catch (Exception e) { Log.e(TAG,"Error restarting active android db"); } }
Example 3
Source File: Sensor.java From xDrip-plus with GNU General Public License v3.0 | 5 votes |
public static void DeleteAndInitDb(Context context) {//KS Configuration dbConfiguration = new Configuration.Builder(context).create(); try { ActiveAndroid.dispose(); context.deleteDatabase("DexDrip.db"); //ActiveAndroid.initialize(dbConfiguration); Log.d("wearSENSOR", "DeleteAndInitDb DexDrip.db deleted and initialized."); } catch (Exception e) { Log.e("wearSENSOR", "DeleteAndInitDb CATCH Error."); } }
Example 4
Source File: JoH.java From xDrip-plus with GNU General Public License v3.0 | 5 votes |
public static void fullDatabaseReset() { try { clearCache(); ActiveAndroid.dispose(); ActiveAndroid.initialize(xdrip.getAppContext()); } catch (Exception e) { Log.e(TAG,"Error restarting active android db"); } }
Example 5
Source File: PerfTestActiveAndroid.java From android-database-performance with Apache License 2.0 | 5 votes |
@Override public void tearDown() throws Exception { if (Cache.isInitialized()) { ActiveAndroid.dispose(); } getTargetContext().deleteDatabase(DATABASE_NAME); super.tearDown(); }
Example 6
Source File: Application.java From mobile-android-survey-app with MIT License | 5 votes |
@Override public void deleteDatabase() { Log.i(this, "deleteDatabase"); Prefs.clear(); deleteDatabase(getManifest("AA_DB_NAME")); ActiveAndroid.clearCache(); ActiveAndroid.dispose(); ActiveAndroid.initialize(this); HttpQueue.getInstance().cancel(); HttpQueue.getInstance().clear(); }
Example 7
Source File: JGApplication.java From o2oa with GNU Affero General Public License v3.0 | 4 votes |
@Override public void onTerminate() { super.onTerminate(); ActiveAndroid.dispose(); }
Example 8
Source File: Application.java From clear-todolist with GNU General Public License v3.0 | 4 votes |
@Override public void onTerminate() { super.onTerminate(); ActiveAndroid.dispose(); }
Example 9
Source File: Application.java From mobile-android-survey-app with MIT License | 4 votes |
@Override public void onTerminate() { super.onTerminate(); ActiveAndroid.dispose(); }
Example 10
Source File: AATest.java From Storm with Apache License 2.0 | 4 votes |
@Override protected void tearDown() { ActiveAndroid.dispose(); }
Example 11
Source File: AAApplication.java From 30-android-libraries-in-30-days with Apache License 2.0 | 4 votes |
@Override public void onTerminate() { super.onTerminate(); ActiveAndroid.dispose(); }
Example 12
Source File: ToasterApp.java From multi-column-list-adapter with Apache License 2.0 | 4 votes |
@Override public void onTerminate() { super.onTerminate(); ActiveAndroid.dispose(); }