Codota Logo
SupportSQLiteDatabase.isWriteAheadLoggingEnabled
Code IndexAdd Codota to your IDE (free)

How to use
isWriteAheadLoggingEnabled
method
in
androidx.sqlite.db.SupportSQLiteDatabase

Best Java code snippets using androidx.sqlite.db.SupportSQLiteDatabase.isWriteAheadLoggingEnabled (Showing top 3 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: commonsguy/cwac-saferoom

@Test
public void wal() throws IOException {
 SafeHelperFactory factory=
  SafeHelperFactory.fromUser(new SpannableStringBuilder(PASSPHRASE));
 SupportSQLiteOpenHelper helper=
  factory.create(InstrumentationRegistry.getTargetContext(), DB_NAME,
   new Callback(1));
 SupportSQLiteDatabase db=helper.getWritableDatabase();
 assertFalse(db.isWriteAheadLoggingEnabled());
 assertTrue(db.enableWriteAheadLogging());
 assertTrue(db.isWriteAheadLoggingEnabled());
 db.close();
 factory=SafeHelperFactory.fromUser(new SpannableStringBuilder(PASSPHRASE));
 helper=
  factory.create(InstrumentationRegistry.getTargetContext(), DB_NAME,
   new Callback(1));
 db=helper.getWritableDatabase();
 assertTrue(db.isWriteAheadLoggingEnabled());
 db.disableWriteAheadLogging();
 assertFalse(db.isWriteAheadLoggingEnabled());
 db.close();
}
origin: commonsguy/cwac-saferoom

@Test
public void notQuiteAsSafeButStillNice() {
 final Context ctxt=InstrumentationRegistry.getTargetContext();
 android.database.sqlite.SQLiteOpenHelper helper = new LessSafeNonRoomHelper(ctxt);
 helper.getWritableDatabase();
 helper.close();
 ImportingLessSafeDatabase room = ImportingLessSafeDatabase.gimme(ctxt);
 SupportSQLiteDatabase db=room.getOpenHelper().getWritableDatabase();
 try {
  assertTrue(db.isWriteAheadLoggingEnabled());
 }
 finally {
  room.close();
 }
}
origin: commonsguy/cwac-saferoom

@Test
public void safe() {
 final Context ctxt=InstrumentationRegistry.getTargetContext();
 SQLiteDatabase.loadLibs(ctxt);
 SQLiteOpenHelper helper = new SafeNonRoomHelper(ctxt);
 helper.getWritableDatabase(PASSPHRASE);
 helper.close();
 ImportingSafeDatabase room = ImportingSafeDatabase.gimme(ctxt);
 SupportSQLiteDatabase db=room.getOpenHelper().getWritableDatabase();
 try {
  assertTrue(db.isWriteAheadLoggingEnabled());
 }
 finally {
  room.close();
 }
}
androidx.sqlite.dbSupportSQLiteDatabaseisWriteAheadLoggingEnabled

Popular methods of SupportSQLiteDatabase

  • execSQL
  • close
  • query
  • beginTransaction
  • disableWriteAheadLogging
  • endTransaction
  • insert
  • setTransactionSuccessful
  • enableWriteAheadLogging
  • getPath
  • inTransaction
  • isOpen
  • inTransaction,
  • isOpen,
  • setForeignKeyConstraintsEnabled,
  • update

Popular in Java

  • Creating JSON documents from java classes using gson
  • onCreateOptionsMenu (Activity)
  • runOnUiThread (Activity)
  • scheduleAtFixedRate (ScheduledExecutorService)
    Creates and executes a periodic action that becomes enabled first after the given initial delay, and
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • JCheckBox (javax.swing)
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now