core-ktx / androidx.database.sqlite / android.database.sqlite.SQLiteDatabase

Extensions for android.database.sqlite.SQLiteDatabase

transaction

fun <T> SQLiteDatabase.transaction(exclusive: Boolean = true, body: SQLiteDatabase.() -> T): T

Run body in a transaction marking it as successful if it completes without exception.