Interface

IDBIndex

IDBIndex

IDBIndex interface of the IndexedDB API provides asynchronous access to an index in a database. An index is a kind of object store for looking up records in another object store, called the referenced object store. You use this interface to retrieve data.

View Source js/lib.dom.d.ts, line 4390

Members

IDBRequest.<number>

# count

Retrieves the number of records matching the given key or key range in query.

If successful, request's result will be the count.

View Source js/lib.dom.d.ts, line 4403

IDBRequest.<(any|undefined)>

# get

Retrieves the value of the first record matching the given key or key range in query.

If successful, request's result will be the value, or undefined if there was no matching record.

View Source js/lib.dom.d.ts, line 4410

IDBRequest.<Array>

# getAll

Retrieves the values of the records matching the given key or key range in query (up to count if given).

If successful, request's result will be an Array of the values.

View Source js/lib.dom.d.ts, line 4417

IDBRequest.<Array>

# getAllKeys

Retrieves the keys of records matching the given key or key range in query (up to count if given).

If successful, request's result will be an Array of the keys.

View Source js/lib.dom.d.ts, line 4424

IDBRequest.<(IDBValidKey|undefined)>

# getKey

Retrieves the key of the first record matching the given key or key range in query.

If successful, request's result will be the key, or undefined if there was no matching record.

View Source js/lib.dom.d.ts, line 4431

string

# name

Returns the name of the index.

View Source js/lib.dom.d.ts, line 4393

IDBObjectStore

# objectStore

Returns the IDBObjectStore the index belongs to.

View Source js/lib.dom.d.ts, line 4398

IDBRequest.<(IDBCursorWithValue|null)>

# openCursor

Opens a cursor over the records matching query, ordered by direction. If query is null, all records in index are matched.

If successful, request's result will be an IDBCursorWithValue, or null if there were no matching records.

View Source js/lib.dom.d.ts, line 4438

IDBRequest.<(IDBCursor|null)>

# openKeyCursor

Opens a cursor with key only flag set over the records matching query, ordered by direction. If query is null, all records in index are matched.

If successful, request's result will be an IDBCursor, or null if there were no matching records.

View Source js/lib.dom.d.ts, line 4445