Skip to content

IDBTransaction

Generated from idl/indexeddb.webidl when the site was built at 7aa23e2.

IDBTransaction is an interface in idl/indexeddb.webidl, inheriting EventTarget, exposed in Window, Worker. What it does is on MDN; this page says what niso has of it.

The web features its members belong to, each with its Baseline status on the web and how much of the feature’s WPT suite passes in niso (see Web platform support).

Feature On the web In niso Members
IndexedDB Widely available Partial 95% 2929 of 3061 subtests pass 12
attribute
readonly attribute DOMStringList objectStoreNames;
int32_t niso_idb_transaction_get_object_store_names(niso_dom* dom, niso_handle self, niso_handle* out);
attribute
readonly attribute IDBTransactionMode mode;
int32_t niso_idb_transaction_get_mode(niso_dom* dom, niso_handle self, niso_str* out);
attribute
readonly attribute IDBTransactionDurability durability;
int32_t niso_idb_transaction_get_durability(niso_dom* dom, niso_handle self, niso_str* out);
attribute
[SameObject] readonly attribute IDBDatabase db;
int32_t niso_idb_transaction_get_db(niso_dom* dom, niso_handle self, niso_handle* out);
attribute
[NisoGlue] readonly attribute DOMException? error;
operation
IDBObjectStore objectStore(DOMString name);
int32_t niso_idb_transaction_object_store(niso_dom* dom, niso_handle self, const char* name, size_t name_len, niso_handle* out);
operation
undefined commit();
int32_t niso_idb_transaction_commit(niso_dom* dom, niso_handle self);
operation
undefined abort();
int32_t niso_idb_transaction_abort(niso_dom* dom, niso_handle self);
attribute
attribute EventHandler onabort;
int32_t niso_idb_transaction_get_onabort(niso_dom* dom, niso_handle self, void** out);
int32_t niso_idb_transaction_set_onabort(niso_dom* dom, niso_handle self, niso_event_handler_non_null_fn value_fn, void* value_userdata, niso_drop_fn value_drop);

Event handlers:

attribute
attribute EventHandler oncomplete;
int32_t niso_idb_transaction_get_oncomplete(niso_dom* dom, niso_handle self, void** out);
int32_t niso_idb_transaction_set_oncomplete(niso_dom* dom, niso_handle self, niso_event_handler_non_null_fn value_fn, void* value_userdata, niso_drop_fn value_drop);
attribute
attribute EventHandler onerror;
int32_t niso_idb_transaction_get_onerror(niso_dom* dom, niso_handle self, void** out);
int32_t niso_idb_transaction_set_onerror(niso_dom* dom, niso_handle self, niso_event_handler_non_null_fn value_fn, void* value_userdata, niso_drop_fn value_drop);
operation not in JS
[NisoInternal] any errorInfo();
int32_t niso_idb_transaction_error_info(niso_dom* dom, niso_handle self, niso_bytes* out);

As IDBRequest’s.

operation not in JS
[NisoInternal] undefined cloning(boolean started);
int32_t niso_idb_transaction_cloning(niso_dom* dom, niso_handle self, bool started);

Makes the active transaction inactive while the binding clones a value for it (true), and active again after (false): “clone a value”.

Members the web has, by the BCD keys web-features 3.45.0 lists, that idl/ doesn’t declare. The list is partial: web-features lists only the keys it maps to a feature.

  • worker_support (IndexedDB)