Class SQLiteGlobal

  • All Implemented Interfaces:

    
    public final class SQLiteGlobal
    
                        

    Provides access to SQLite functions that affect all database connection, such as memory management. The native code associated with SQLiteGlobal is also sets global configuration options using sqlite3_config() then calls sqlite3_initialize() to ensure that the SQLite library is properly initialized exactly once before any other framework or application code has a chance to run. Verbose SQLite logging is enabled if the "log.tag.SQLiteLog" property is set to "V". (per DEBUG_SQL_LOG).

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      static int releaseMemory() Attempts to release memory by pruning the SQLite page cache and other internal data structures.
      static int getDefaultPageSize() Gets the default page size to use when creating a database.
      static String getDefaultJournalMode() Gets the default journal mode when WAL is not in use.
      static int getJournalSizeLimit() Gets the journal size limit in bytes.
      static String getDefaultSyncMode() Gets the default database synchronization mode when WAL is not in use.
      static String getWALSyncMode() Gets the database synchronization mode when in WAL mode.
      static int getWALAutoCheckpoint() Gets the WAL auto-checkpoint integer in database pages.
      static void setWALConnectionPoolSize(int value) Sets the connection pool size for WAL mode.
      static int getWALConnectionPoolSize() Gets the connection pool size when in WAL mode.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • releaseMemory

         static int releaseMemory()

        Attempts to release memory by pruning the SQLite page cache and other internal data structures.

        Returns:

        The number of bytes that were freed.

      • getDefaultPageSize

         static int getDefaultPageSize()

        Gets the default page size to use when creating a database.

      • getDefaultSyncMode

         static String getDefaultSyncMode()

        Gets the default database synchronization mode when WAL is not in use.

      • getWALSyncMode

         static String getWALSyncMode()

        Gets the database synchronization mode when in WAL mode.

      • getWALAutoCheckpoint

         static int getWALAutoCheckpoint()

        Gets the WAL auto-checkpoint integer in database pages.

      • setWALConnectionPoolSize

         static void setWALConnectionPoolSize(int value)

        Sets the connection pool size for WAL mode.