KilnDriver
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun <R> executeQuery(identifier: Int?, sql: String, mapper: (KilnCursor) -> R, parameters: Int, binders: KilnPreparedStatement.() -> Unit? = null): R
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Inside a transaction, records tableName as dirty so its notification is sent once, after the outermost commit — or not at all if the transaction rolls back. Outside a transaction, calls KilnDriver.notifyListeners immediately (preserving the existing per-operation behaviour).
Link copied to clipboard
Link copied to clipboard
suspend fun KilnDriver.withTransaction(context: CoroutineContext = Dispatchers.Default, block: suspend () -> Unit)
Executes block inside a single SQLite transaction.
Link copied to clipboard
suspend fun <T> KilnDriver.withTransactionAwareContext(context: CoroutineContext, block: suspend CoroutineScope.() -> T): T
Runs block like withContext(context, block), unless a transaction is open: