SQLiteTransaction
SQLite Transaction
Describes a transaction which is bound to an SQLiteTransactor function, and which is under execution via the SQLite engine against an active database; the transaction may be invoked one or more times, and may be adjusted via the mode methods provided (deferred, immediate, and exclusive).
If no transaction mode is declared explicitly via the methods provided, the connection's default transaction mode is used.
Transaction Behavior
Transaction functions may be executed more than once in order to facilitate retry or rollback logic; the transaction function is expected to be idempotent.
The return value (type R) provided by the SQLiteTransactor, if any, is returned by this transaction object, via invoke.
Object Interop & Cancellation
Transactions are directly executable, either host-side (via invoke), or guest-side (via ProxyExecutable). Transactions can also be used as Future objects which yield their result when the transaction completes.
Cancelling a transaction will make a best-effort attempt to interrupt it (if allowed), by raising an exception within the thread executing the transaction.
Transaction cancellation then propagates to the caller instead of providing a value.
Parameters
Return value type.
See also
Properties
Indicate the type of this transaction; see SQLiteTransactionType for options.
Functions
Applies DEFERRED
mode to this transaction; another transaction object is returned (a copy), applying this mode, but with the same properties otherwise.
Applies EXCLUSIVE
mode to this transaction; another transaction object is returned (a copy), applying this mode, but with the same properties otherwise.
Applies IMMEDIATE
mode to this transaction; another transaction object is returned (a copy), applying this mode, but with the same properties otherwise.
Execute this transaction, invoking the associated SQLiteTransactor function.