IDBDatabase object
Represents a container for object stores, indexes, and other objects associated with data.
![]() |
DOM Information
Inheritance Hierarchy
The IDBDatabase does not inherit from any class or interface.Members
The IDBDatabase object has these types of members:
Methods
The IDBDatabase object has these methods.
| Method | Description |
|---|---|
| addEventListener |
Registers an event handler for the specified event type. |
| close |
Closes the connection to a database. |
| createObjectStore |
Creates an object store. |
| deleteObjectStore |
Deletes an object store (and associated indexes) from the database. |
| dispatchEvent |
Sends an event to the current element. |
| removeEventListener |
Removes an event handler that the addEventListener method registered. |
| setVersion |
Obsolete. No longer supported. |
| transaction |
Begins a transaction for the specified object stores. |
Properties
The IDBDatabase object has these properties.
| Property | Access type | Description |
|---|---|---|
| Read-only |
Returns the names of object stores associated with a database. | |
| Read/write |
Defines a function handler that is executed when an error is encountered during a request, a transaction, or other database operation. | |
| Read-only |
Gets the version of the database. |
Standards information
