SQLiteOpenHelper.OnConfigure(SQLiteDatabase) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Called when the database connection is being configured, to enable features such as write-ahead logging or foreign key support.
[Android.Runtime.Register("onConfigure", "(Landroid/database/sqlite/SQLiteDatabase;)V", "GetOnConfigure_Landroid_database_sqlite_SQLiteDatabase_Handler")]
public virtual void OnConfigure (Android.Database.Sqlite.SQLiteDatabase? db);
[<Android.Runtime.Register("onConfigure", "(Landroid/database/sqlite/SQLiteDatabase;)V", "GetOnConfigure_Landroid_database_sqlite_SQLiteDatabase_Handler")>]
abstract member OnConfigure : Android.Database.Sqlite.SQLiteDatabase -> unit
override this.OnConfigure : Android.Database.Sqlite.SQLiteDatabase -> unit
Parameters
The database.
- Attributes
Remarks
Called when the database connection is being configured, to enable features such as write-ahead logging or foreign key support.
This method is called before #onCreate
, #onUpgrade
, #onDowngrade
, or #onOpen
are called. It should not modify the database except to configure the database connection as required.
This method should only call methods that configure the parameters of the database connection, such as SQLiteDatabase#enableWriteAheadLogging
SQLiteDatabase#setForeignKeyConstraintsEnabled
, SQLiteDatabase#setLocale
, SQLiteDatabase#setMaximumSize
, or executing PRAGMA statements.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.