Manage a transaction over an ObjectStore collection


new GDBTransaction()

Name Type Description
revisionID string
disposition string
stores Array
database GraphDatabase

View Source graph-database.js, line 536



Abort a transaction by delegating to the transaction's object stores to roll back changes in all attached objects

View Source graph-database.js, line 661


Upon commit completion, set all attached objects to clean.

View Source graph-database.js, line 653


Commmit accumulated changes to the remote store. Iterate over the owned object stores, collect their delete/post/put patches, delegate to the database with this collected patch. When that completes, clear the state on all registered objects and record the new revision id in the database.

This returns no additional asynchronous control thread as, when invoked from a control thread in the database, this invocation is either already in an asynchronous, as a promise's then function. For an explicit invocation from the application thread return a request instance which can bind an onsuccess property to recieve control when the patch request completes.

View Source graph-database.js, line 595


Invoked as the final step in promise chains for transaction-scoped operations, such as get and put. Iff no request is still pending, then there is no pending control in the application which xcould add to the transaction and it should be completed by delegating th ecommit to the remote store in the form of a patch.

View Source graph-database.js, line 639