IDBTransaction

Overview

The IDBTransaction interface of the IndexedDB API provides a static, asynchronous transaction on a database using event handler attributes. All reading and writing of data is done within transactions. You use IDBDatabase to start transactions, IDBTransaction to set the mode of the transaction (e.g. is it readonly or readwrite), and you access an IDBObjectStore to make a request. You can also use an IDBTransaction object to abort transactions.

Location

 

commit

For an active transaction, commits the transaction. Note that this doesn't normally have to be called — a transaction will automatically commit when all outstanding requests have been satisfied and no new requests have been made. commit() can be used to start the commit process without waiting for events from outstanding requests to be dispatched.

 

method commit

 

void commit()

 

func commit()

 

void commit()

 

Sub commit()

db

 

property db: IDBDatabase read;

 

IDBDatabase db { get; }

 

var db: IDBDatabase { get{} }

 

IDBDatabase db { __get; }

 

ReadOnly Property db() As IDBDatabase

error

 

property error: DOMException read;

 

DOMException error { get; }

 

var error: DOMException { get{} }

 

DOMException error { __get; }

 

ReadOnly Property error() As DOMException

mode

 

property mode: dynamic read;

 

dynamic mode { get; }

 

var mode: dynamic { get{} }

 

dynamic mode { __get; }

 

ReadOnly Property mode() As dynamic

objectStore

Returns an IDBObjectStore object representing an object store that is part of the scope of this transaction.

 

method objectStore(parname: dynamic): dynamic

 

dynamic objectStore(dynamic parname)

 

func objectStore(_ parname: dynamic) -> dynamic

 

dynamic objectStore(dynamic parname)

 

Function objectStore(parname As dynamic) As dynamic

Parameters:

  • parname:

objectStoreNames

 

property objectStoreNames: String read;

 

String objectStoreNames { get; }

 

var objectStoreNames: String { get{} }

 

String objectStoreNames { __get; }

 

ReadOnly Property objectStoreNames() As String

 

db

 

property db: IDBDatabase read;

 

IDBDatabase db { get; }

 

var db: IDBDatabase { get{} }

 

IDBDatabase db { __get; }

 

ReadOnly Property db() As IDBDatabase

error

 

property error: DOMException read;

 

DOMException error { get; }

 

var error: DOMException { get{} }

 

DOMException error { __get; }

 

ReadOnly Property error() As DOMException

mode

 

property mode: dynamic read;

 

dynamic mode { get; }

 

var mode: dynamic { get{} }

 

dynamic mode { __get; }

 

ReadOnly Property mode() As dynamic

objectStoreNames

 

property objectStoreNames: String read;

 

String objectStoreNames { get; }

 

var objectStoreNames: String { get{} }

 

String objectStoreNames { __get; }

 

ReadOnly Property objectStoreNames() As String

 

commit

For an active transaction, commits the transaction. Note that this doesn't normally have to be called — a transaction will automatically commit when all outstanding requests have been satisfied and no new requests have been made. commit() can be used to start the commit process without waiting for events from outstanding requests to be dispatched.

 

method commit

 

void commit()

 

func commit()

 

void commit()

 

Sub commit()

objectStore

Returns an IDBObjectStore object representing an object store that is part of the scope of this transaction.

 

method objectStore(parname: dynamic): dynamic

 

dynamic objectStore(dynamic parname)

 

func objectStore(_ parname: dynamic) -> dynamic

 

dynamic objectStore(dynamic parname)

 

Function objectStore(parname As dynamic) As dynamic

Parameters:

  • parname: