indexeddbshim 11.0.0 → 12.0.0-pre.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/badges/licenses-badge.svg +1 -1
- package/dist/CFG.d.ts +80 -0
- package/dist/CFG.d.ts.map +1 -0
- package/dist/DOMException.d.ts +71 -0
- package/dist/DOMException.d.ts.map +1 -0
- package/dist/DOMStringList.d.ts +20 -0
- package/dist/DOMStringList.d.ts.map +1 -0
- package/dist/Event.d.ts +21 -0
- package/dist/Event.d.ts.map +1 -0
- package/dist/IDBCursor.d.ts +289 -0
- package/dist/IDBCursor.d.ts.map +1 -0
- package/dist/IDBDatabase.d.ts +144 -0
- package/dist/IDBDatabase.d.ts.map +1 -0
- package/dist/IDBFactory.d.ts +96 -0
- package/dist/IDBFactory.d.ts.map +1 -0
- package/dist/IDBIndex.d.ts +243 -0
- package/dist/IDBIndex.d.ts.map +1 -0
- package/dist/IDBKeyRange.d.ts +79 -0
- package/dist/IDBKeyRange.d.ts.map +1 -0
- package/dist/IDBObjectStore.d.ts +273 -0
- package/dist/IDBObjectStore.d.ts.map +1 -0
- package/dist/IDBRequest.d.ts +90 -0
- package/dist/IDBRequest.d.ts.map +1 -0
- package/dist/IDBTransaction.d.ts +271 -0
- package/dist/IDBTransaction.d.ts.map +1 -0
- package/dist/IDBVersionChangeEvent.d.ts +23 -0
- package/dist/IDBVersionChangeEvent.d.ts.map +1 -0
- package/dist/Key.d.ts +214 -0
- package/dist/Key.d.ts.map +1 -0
- package/dist/Sca.d.ts +31 -0
- package/dist/Sca.d.ts.map +1 -0
- package/dist/UnicodeIdentifiers.d.ts +3 -0
- package/dist/UnicodeIdentifiers.d.ts.map +1 -0
- package/dist/browser-UnicodeIdentifiers.d.ts +2 -0
- package/dist/browser-UnicodeIdentifiers.d.ts.map +1 -0
- package/dist/browser-noninvasive.d.ts +3 -0
- package/dist/browser-noninvasive.d.ts.map +1 -0
- package/dist/browser.d.ts +2 -0
- package/dist/browser.d.ts.map +1 -0
- package/dist/cmp.d.ts +9 -0
- package/dist/cmp.d.ts.map +1 -0
- package/dist/indexeddbshim-Key.js +491 -189
- package/dist/indexeddbshim-Key.js.map +1 -1
- package/dist/indexeddbshim-Key.min.js +2 -2
- package/dist/indexeddbshim-Key.min.js.map +1 -1
- package/dist/indexeddbshim-UnicodeIdentifiers-node.cjs +17263 -1396
- package/dist/indexeddbshim-UnicodeIdentifiers-node.cjs.map +1 -1
- package/dist/indexeddbshim-UnicodeIdentifiers.js +3892 -1271
- package/dist/indexeddbshim-UnicodeIdentifiers.js.map +1 -1
- package/dist/indexeddbshim-UnicodeIdentifiers.min.js +2 -2
- package/dist/indexeddbshim-UnicodeIdentifiers.min.js.map +1 -1
- package/dist/indexeddbshim-node.cjs +17259 -1396
- package/dist/indexeddbshim-node.cjs.map +1 -1
- package/dist/indexeddbshim-noninvasive.js +3887 -1271
- package/dist/indexeddbshim-noninvasive.js.map +1 -1
- package/dist/indexeddbshim-noninvasive.min.js +2 -2
- package/dist/indexeddbshim-noninvasive.min.js.map +1 -1
- package/dist/indexeddbshim.js +3887 -1271
- package/dist/indexeddbshim.js.map +1 -1
- package/dist/indexeddbshim.min.js +2 -2
- package/dist/indexeddbshim.min.js.map +1 -1
- package/dist/node-UnicodeIdentifiers.d.ts +8 -0
- package/dist/node-UnicodeIdentifiers.d.ts.map +1 -0
- package/dist/node.d.ts +8 -0
- package/dist/node.d.ts.map +1 -0
- package/dist/nodeWebSQL.d.ts +3 -0
- package/dist/nodeWebSQL.d.ts.map +1 -0
- package/dist/setGlobalVars.d.ts +79 -0
- package/dist/setGlobalVars.d.ts.map +1 -0
- package/dist/unicode-regex.d.ts +3 -0
- package/dist/unicode-regex.d.ts.map +1 -0
- package/dist/util.d.ts +174 -0
- package/dist/util.d.ts.map +1 -0
- package/package.json +40 -27
- package/src/CFG.js +89 -11
- package/src/DOMException.js +116 -29
- package/src/DOMStringList.js +92 -2
- package/src/Event.js +19 -4
- package/src/IDBCursor.js +339 -67
- package/src/IDBDatabase.js +87 -10
- package/src/IDBFactory.js +319 -56
- package/src/IDBIndex.js +385 -96
- package/src/IDBKeyRange.js +86 -13
- package/src/IDBObjectStore.js +326 -68
- package/src/IDBRequest.js +59 -1
- package/src/IDBTransaction.js +247 -38
- package/src/IDBVersionChangeEvent.js +28 -3
- package/src/Key.js +273 -156
- package/src/Sca.js +29 -4
- package/src/browser-UnicodeIdentifiers.js +5 -1
- package/src/cmp.js +5 -5
- package/src/node-UnicodeIdentifiers.js +9 -0
- package/src/node.js +5 -0
- package/src/nodeWebSQL.js +11 -5
- package/src/setGlobalVars.js +156 -21
- package/src/unicode-regex.js +9 -1
- package/src/util.js +228 -40
- package/typings/shimIndexedDB.d.ts +9 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" width="593" height="
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="593" height="140"><defs><style>text{font-size:11px;font-family:Verdana,DejaVu Sans,Geneva,sans-serif}text.shadow{fill:#010101;fill-opacity:.3}text.high{fill:#fff}</style><linearGradient id="smooth" x2="0" y2="100%"><stop offset="0" stop-color="#aaa" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="round"><rect width="100%" height="100%" rx="3" fill="#fff"/></mask></defs><g id="bg" mask="url(#round)"><path fill="navy" d="M0 0h227v140H0z"/><path fill="#006400" d="M227 0h183v140H227z"/><path fill="green" d="M410 0h183v140H410z"/><path fill="url(#smooth)" d="M0 0h593v140H0z"/></g><g id="fg"><text class="shadow" x="5.5" y="15">License types</text><text class="high" x="5" y="14">License types</text><text class="shadow" x="5.5" y="27">(project, deps, and bundled devDeps)</text><text class="high" x="5" y="26">(project, deps, and bundled devDeps)</text><text class="shadow" x="232.5" y="15">Public</text><text class="high" x="232" y="14">Public</text><text class="shadow" x="232.5" y="27">domain</text><text class="high" x="232" y="26">domain</text><text class="shadow" x="232.5" y="51">1. (Unlicense OR Apache-2.0)</text><text class="high" x="232" y="50">1. (Unlicense OR Apache-2.0)</text><text class="shadow" x="415.5" y="15">Permissive</text><text class="high" x="415" y="14">Permissive</text><text class="shadow" x="415.5" y="39">1. (MIT OR Apache-2.0)</text><text class="high" x="415" y="38">1. (MIT OR Apache-2.0)</text><text class="shadow" x="415.5" y="51">2. (Unlicense OR Apache-2.0)</text><text class="high" x="415" y="50">2. (Unlicense OR Apache-2.0)</text><text class="shadow" x="415.5" y="63">3. Apache-2.0</text><text class="high" x="415" y="62">3. Apache-2.0</text><text class="shadow" x="415.5" y="75">4. BSD-2-Clause</text><text class="high" x="415" y="74">4. BSD-2-Clause</text><text class="shadow" x="415.5" y="87">5. BSD-3-Clause</text><text class="high" x="415" y="86">5. BSD-3-Clause</text><text class="shadow" x="415.5" y="99">6. BlueOak-1.0.0</text><text class="high" x="415" y="98">6. BlueOak-1.0.0</text><text class="shadow" x="415.5" y="111">7. ISC</text><text class="high" x="415" y="110">7. ISC</text><text class="shadow" x="415.5" y="123">8. MIT</text><text class="high" x="415" y="122">8. MIT</text><text class="shadow" x="415.5" y="135">9. WTFPL</text><text class="high" x="415" y="134">9. WTFPL</text></g></svg>
|
package/dist/CFG.d.ts
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
export default CFG;
|
|
2
|
+
/**
|
|
3
|
+
* <T>
|
|
4
|
+
*/
|
|
5
|
+
export type ValueOf<T> = T[keyof T];
|
|
6
|
+
export type FSApi = {
|
|
7
|
+
unlink: (path: string, cb: import('fs').NoParamCallback) => void;
|
|
8
|
+
};
|
|
9
|
+
export type ConfigValues = {
|
|
10
|
+
DEBUG: boolean;
|
|
11
|
+
cacheDatabaseInstances: boolean;
|
|
12
|
+
autoName: boolean;
|
|
13
|
+
fullIDLSupport: boolean;
|
|
14
|
+
checkOrigin: boolean;
|
|
15
|
+
cursorPreloadPackSize: number;
|
|
16
|
+
UnicodeIDStart: string;
|
|
17
|
+
UnicodeIDContinue: string;
|
|
18
|
+
registerSCA: (preset: import('typeson').Preset) => import('typeson').Preset;
|
|
19
|
+
avoidAutoShim: boolean;
|
|
20
|
+
win: {
|
|
21
|
+
openDatabase: (name: string, version: string, displayName: string, estimatedSize: number) => any;
|
|
22
|
+
};
|
|
23
|
+
DEFAULT_DB_SIZE: number;
|
|
24
|
+
useSQLiteIndexes: boolean;
|
|
25
|
+
fs: FSApi;
|
|
26
|
+
addNonIDBGlobals: boolean;
|
|
27
|
+
replaceNonIDBGlobals: boolean;
|
|
28
|
+
escapeDatabaseName: (name: string) => string;
|
|
29
|
+
unescapeDatabaseName: (name: string) => string;
|
|
30
|
+
databaseCharacterEscapeList: string | false;
|
|
31
|
+
databaseNameLengthLimit: number | false;
|
|
32
|
+
escapeNFDForDatabaseNames: boolean;
|
|
33
|
+
addSQLiteExtension: boolean;
|
|
34
|
+
memoryDatabase: string;
|
|
35
|
+
deleteDatabaseFiles: boolean;
|
|
36
|
+
databaseBasePath: string;
|
|
37
|
+
sysDatabaseBasePath: string;
|
|
38
|
+
sqlBusyTimeout: number;
|
|
39
|
+
sqlTrace: () => void;
|
|
40
|
+
sqlProfile: () => void;
|
|
41
|
+
createIndexes: boolean;
|
|
42
|
+
};
|
|
43
|
+
export type ConfigValue = ValueOf<ConfigValues>;
|
|
44
|
+
export type KeyofConfigValues = keyof ConfigValues;
|
|
45
|
+
export type Config = KeyofConfigValues[];
|
|
46
|
+
declare namespace CFG {
|
|
47
|
+
const DEBUG: boolean;
|
|
48
|
+
const cacheDatabaseInstances: boolean;
|
|
49
|
+
const autoName: boolean;
|
|
50
|
+
const fullIDLSupport: boolean;
|
|
51
|
+
const checkOrigin: boolean;
|
|
52
|
+
const cursorPreloadPackSize: number;
|
|
53
|
+
const UnicodeIDStart: string;
|
|
54
|
+
const UnicodeIDContinue: string;
|
|
55
|
+
const registerSCA: (preset: import("typeson").Preset) => import("typeson").Preset;
|
|
56
|
+
const avoidAutoShim: boolean;
|
|
57
|
+
const win: {
|
|
58
|
+
openDatabase: (name: string, version: string, displayName: string, estimatedSize: number) => any;
|
|
59
|
+
};
|
|
60
|
+
const DEFAULT_DB_SIZE: number;
|
|
61
|
+
const useSQLiteIndexes: boolean;
|
|
62
|
+
const fs: FSApi;
|
|
63
|
+
const addNonIDBGlobals: boolean;
|
|
64
|
+
const replaceNonIDBGlobals: boolean;
|
|
65
|
+
const escapeDatabaseName: (name: string) => string;
|
|
66
|
+
const unescapeDatabaseName: (name: string) => string;
|
|
67
|
+
const databaseCharacterEscapeList: string | false;
|
|
68
|
+
const databaseNameLengthLimit: number | false;
|
|
69
|
+
const escapeNFDForDatabaseNames: boolean;
|
|
70
|
+
const addSQLiteExtension: boolean;
|
|
71
|
+
const memoryDatabase: string;
|
|
72
|
+
const deleteDatabaseFiles: boolean;
|
|
73
|
+
const databaseBasePath: string;
|
|
74
|
+
const sysDatabaseBasePath: string;
|
|
75
|
+
const sqlBusyTimeout: number;
|
|
76
|
+
const sqlTrace: () => void;
|
|
77
|
+
const sqlProfile: () => void;
|
|
78
|
+
const createIndexes: boolean;
|
|
79
|
+
}
|
|
80
|
+
//# sourceMappingURL=CFG.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CFG.d.ts","sourceRoot":"","sources":["../src/CFG.js"],"names":[],"mappings":";;;;yBAEa,CAAC,CAAC,MAAM,CAAC,CAAC;;mBAMM,MAAM,MAAM,OAAO,IAAI,EAAE,eAAe,KAAK,IAAI;;;WAKlE,OAAO;4BACU,OAAO;cACrB,OAAO;oBACD,OAAO;iBACV,OAAO;2BACG,MAAM;oBACb,MAAM;uBACH,MAAM;0BAEf,OAAO,SAAS,EAAE,MAAM,KAC7B,OAAO,SAAS,EAAE,MAAM;mBACd,OAAO;;6BAEC,MAAM,WAAW,MAAM,eAAe,MAAM,iBAAiB,MAAM;;qBAEzE,MAAM;sBACL,OAAO;QACrB,KAAK;sBACS,OAAO;0BACH,OAAO;+BACF,MAAM,KAAK,MAAM;iCACf,MAAM,KAAK,MAAM;iCACjB,MAAM,GAAC,KAAK;6BAChB,MAAM,GAAC,KAAK;+BACV,OAAO;wBACd,OAAO;oBACX,MAAM;yBACD,OAAO;sBACV,MAAM;yBACH,MAAM;oBACX,MAAM;cACZ,MAAM,IAAI;gBACR,MAAM,IAAI;mBACP,OAAO;;0BAKd,QAAQ,YAAY,CAAC;gCASrB,MAAM,YAAY;qBAIlB,iBAAiB,EAAE;;iBAnDpB,OAAO;kCACU,OAAO;oBACrB,OAAO;0BACD,OAAO;uBACV,OAAO;iCACG,MAAM;0BACb,MAAM;6BACH,MAAM;;yBAIV,OAAO;;;;2BAIL,MAAM;4BACL,OAAO;cACrB,KAAK;4BACS,OAAO;gCACH,OAAO;;;uCAGA,MAAM,GAAC,KAAK;mCAChB,MAAM,GAAC,KAAK;qCACV,OAAO;8BACd,OAAO;0BACX,MAAM;+BACD,OAAO;4BACV,MAAM;+BACH,MAAM;0BACX,MAAM;oBACZ,MAAM,IAAI;sBACR,MAAM,IAAI;yBACP,OAAO"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
export type ErrorLike = {
|
|
2
|
+
message: string | DOMString;
|
|
3
|
+
};
|
|
4
|
+
export type ArbitraryValue = any;
|
|
5
|
+
export type Code = "IndexSizeError" | "HierarchyRequestError" | "WrongDocumentError" | "InvalidCharacterError" | "NoModificationAllowedError" | "NotFoundError" | "NotSupportedError" | "InUseAttributeError" | "InvalidStateError" | "SyntaxError" | "InvalidModificationError" | "NamespaceError" | "InvalidAccessError" | "TypeMismatchError" | "SecurityError" | "NetworkError" | "AbortError" | "URLMismatchError" | "QuotaExceededError" | "TimeoutError" | "InvalidNodeTypeError" | "DataCloneError" | "EncodingError" | "NotReadableError" | "UnknownError" | "ConstraintError" | "DataError" | "TransactionInactiveError" | "ReadOnlyError" | "VersionError" | "OperationError" | "NotAllowedError";
|
|
6
|
+
export type LegacyCode = "INDEX_SIZE_ERR" | "DOMSTRING_SIZE_ERR" | "HIERARCHY_REQUEST_ERR" | "WRONG_DOCUMENT_ERR" | "INVALID_CHARACTER_ERR" | "NO_DATA_ALLOWED_ERR" | "NO_MODIFICATION_ALLOWED_ERR" | "NOT_FOUND_ERR" | "NOT_SUPPORTED_ERR" | "INUSE_ATTRIBUTE_ERR" | "INVALID_STATE_ERR" | "SYNTAX_ERR" | "INVALID_MODIFICATION_ERR" | "NAMESPACE_ERR" | "INVALID_ACCESS_ERR" | "VALIDATION_ERR" | "TYPE_MISMATCH_ERR" | "SECURITY_ERR" | "NETWORK_ERR" | "ABORT_ERR" | "URL_MISMATCH_ERR" | "QUOTA_EXCEEDED_ERR" | "TIMEOUT_ERR" | "INVALID_NODE_TYPE_ERR" | "DATA_CLONE_ERR";
|
|
7
|
+
/**
|
|
8
|
+
* @typedef {{
|
|
9
|
+
* message: string|DOMString
|
|
10
|
+
* }} ErrorLike
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Logs detailed error information to the console.
|
|
14
|
+
* @param {string} name
|
|
15
|
+
* @param {string} message
|
|
16
|
+
* @param {string|ErrorLike|boolean|null} [error]
|
|
17
|
+
* @returns {void}
|
|
18
|
+
*/
|
|
19
|
+
export function logError(name: string, message: string, error?: string | boolean | ErrorLike | null | undefined): void;
|
|
20
|
+
/**
|
|
21
|
+
* Finds the error argument. This is useful because some WebSQL callbacks
|
|
22
|
+
* pass the error as the first argument, and some pass it as the second
|
|
23
|
+
* argument.
|
|
24
|
+
* @param {(Error|{message?: string, name?: string}|any)[]} args
|
|
25
|
+
* @returns {Error|DOMException|undefined}
|
|
26
|
+
*/
|
|
27
|
+
export function findError(args: (Error | {
|
|
28
|
+
message?: string;
|
|
29
|
+
name?: string;
|
|
30
|
+
} | any)[]): Error | DOMException | undefined;
|
|
31
|
+
export const ShimDOMException: {
|
|
32
|
+
new (message?: string | undefined, name?: string | undefined): DOMException;
|
|
33
|
+
prototype: DOMException;
|
|
34
|
+
readonly INDEX_SIZE_ERR: 1;
|
|
35
|
+
readonly DOMSTRING_SIZE_ERR: 2;
|
|
36
|
+
readonly HIERARCHY_REQUEST_ERR: 3;
|
|
37
|
+
readonly WRONG_DOCUMENT_ERR: 4;
|
|
38
|
+
readonly INVALID_CHARACTER_ERR: 5;
|
|
39
|
+
readonly NO_DATA_ALLOWED_ERR: 6;
|
|
40
|
+
readonly NO_MODIFICATION_ALLOWED_ERR: 7;
|
|
41
|
+
readonly NOT_FOUND_ERR: 8;
|
|
42
|
+
readonly NOT_SUPPORTED_ERR: 9;
|
|
43
|
+
readonly INUSE_ATTRIBUTE_ERR: 10;
|
|
44
|
+
readonly INVALID_STATE_ERR: 11;
|
|
45
|
+
readonly SYNTAX_ERR: 12;
|
|
46
|
+
readonly INVALID_MODIFICATION_ERR: 13;
|
|
47
|
+
readonly NAMESPACE_ERR: 14;
|
|
48
|
+
readonly INVALID_ACCESS_ERR: 15;
|
|
49
|
+
readonly VALIDATION_ERR: 16;
|
|
50
|
+
readonly TYPE_MISMATCH_ERR: 17;
|
|
51
|
+
readonly SECURITY_ERR: 18;
|
|
52
|
+
readonly NETWORK_ERR: 19;
|
|
53
|
+
readonly ABORT_ERR: 20;
|
|
54
|
+
readonly URL_MISMATCH_ERR: 21;
|
|
55
|
+
readonly QUOTA_EXCEEDED_ERR: 22;
|
|
56
|
+
readonly TIMEOUT_ERR: 23;
|
|
57
|
+
readonly INVALID_NODE_TYPE_ERR: 24;
|
|
58
|
+
readonly DATA_CLONE_ERR: 25;
|
|
59
|
+
};
|
|
60
|
+
export const createDOMException: ((name: string, message: string, error?: ErrorLike | undefined) => DOMException) | ((name: string, message: string, error?: ErrorLike | undefined) => Error);
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @param {SQLError} webSQLErr
|
|
64
|
+
* @returns {(DOMException|Error) & {
|
|
65
|
+
* sqlError: SQLError
|
|
66
|
+
* }}
|
|
67
|
+
*/
|
|
68
|
+
export function webSQLErrback(webSQLErr: SQLError): (DOMException | Error) & {
|
|
69
|
+
sqlError: SQLError;
|
|
70
|
+
};
|
|
71
|
+
//# sourceMappingURL=DOMException.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DOMException.d.ts","sourceRoot":"","sources":["../src/DOMException.js"],"names":[],"mappings":"wBAyPa;IACZ,OAAW,EAAE,MAAM,GAAC,SAAS,CAAA;CAC1B;6BAuBS,GAAG;mBA9PH,gBAAgB,GAAC,uBAAuB,GAAC,oBAAoB,GACzE,uBAAyB,GAAC,4BAA4B,GAAC,eAAe,GACtE,mBAAqB,GAAC,qBAAqB,GAAC,mBAAmB,GAC/D,aAAe,GAAC,0BAA0B,GAAC,gBAAgB,GAC3D,oBAAsB,GAAC,mBAAmB,GAAC,eAAe,GAC1D,cAAgB,GAAC,YAAY,GAAC,kBAAkB,GAAC,oBAAoB,GACrE,cAAgB,GAAC,sBAAsB,GAAC,gBAAgB,GAAC,eAAe,GACxE,kBAAoB,GAAC,cAAc,GAAC,iBAAiB,GAAC,WAAW,GACjE,0BAA4B,GAAC,eAAe,GAAC,cAAc,GAC3D,gBAAkB,GAAC,iBAAiB;yBAwCxB,gBAAgB,GAAC,oBAAoB,GAAC,uBAAuB,GACzE,oBAAsB,GAAC,uBAAuB,GAAC,qBAAqB,GACpE,6BAA+B,GAAC,eAAe,GAAC,mBAAmB,GACnE,qBAAuB,GAAC,mBAAmB,GAAC,YAAY,GACxD,0BAA4B,GAAC,eAAe,GAAC,oBAAoB,GACjE,gBAAkB,GAAC,mBAAmB,GAAC,cAAc,GAAC,aAAa,GACnE,WAAa,GAAC,kBAAkB,GAAC,oBAAoB,GAAC,aAAa,GACnE,uBAAyB,GAAC,gBAAgB;AA4K3C;;;;GAIG;AAEH;;;;;;GAMG;AACH,+BALW,MAAM,WACN,MAAM,4DAEJ,IAAI,CAYhB;AAeD;;;;;;GAMG;AACH,gCAHW,CAAC,KAAK,GAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAA;CAAC,GAAC,GAAG,CAAC,EAAE,GAC7C,KAAK,GAAC,YAAY,GAAC,SAAS,CAkBxC;AAiFD;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEgC;AA1BhC,yCAGe,MAAM,WACN,MAAM,oCAEJ,YAAY,YAQf,MAAM,WACN,MAAM,oCAEJ,KAAK,EAKf;AA7EN;;;;;;GAMG;AACH,yCALW,QAAQ,GACN,CAAC,YAAY,GAAC,KAAK,CAAC,GAAG;IACnC,QAAY,EAAE,QAAQ,CAAA;CACnB,CAqCH"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export default DOMStringList;
|
|
2
|
+
export type Integer = number;
|
|
3
|
+
export type DOMStringListFull = {
|
|
4
|
+
[key: number]: string;
|
|
5
|
+
_items: string[];
|
|
6
|
+
_length: Integer;
|
|
7
|
+
addIndexes: () => void;
|
|
8
|
+
sortList: () => string[];
|
|
9
|
+
push: (item: string) => void;
|
|
10
|
+
clone: () => DOMStringListFull;
|
|
11
|
+
contains: (str: string) => boolean;
|
|
12
|
+
indexOf: (str: string) => Integer;
|
|
13
|
+
splice: (index: Integer, howmany: Integer, ...args: any) => void;
|
|
14
|
+
length: Integer;
|
|
15
|
+
};
|
|
16
|
+
export type AnyValue = any;
|
|
17
|
+
declare class DOMStringList {
|
|
18
|
+
get length(): any;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=DOMStringList.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DOMStringList.d.ts","sourceRoot":"","sources":["../src/DOMStringList.js"],"names":[],"mappings":";sBACa,MAAM;;;YAKN,MAAM,EAAE;aACP,OAAO;gBAEJ,MAAM,IAAI;cACZ,MAAM,MAAM,EAAE;iBACX,MAAM,KAAK,IAAI;WACrB,MAAM,iBAAiB;oBACd,MAAM,KAAK,OAAO;mBACnB,MAAM,KAAK,OAAO;oBACjB,OAAO,WAAW,OAAO,WAAW,GAAG,KAAK,IAAI;YACxD,OAAO;;uBAiKP,GAAG"}
|
package/dist/Event.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export type DebuggingError = Error;
|
|
2
|
+
/**
|
|
3
|
+
* @typedef {Error} DebuggingError
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
*
|
|
7
|
+
* @param {string} type
|
|
8
|
+
* @param {DebuggingError|null} [debug]
|
|
9
|
+
* @param {EventInit} [evInit]
|
|
10
|
+
* @returns {Event & {
|
|
11
|
+
* __legacyOutputDidListenersThrowError?: boolean
|
|
12
|
+
* }}
|
|
13
|
+
*/
|
|
14
|
+
export function createEvent(type: string, debug?: Error | null | undefined, evInit?: EventInit | undefined): Event & {
|
|
15
|
+
__legacyOutputDidListenersThrowError?: boolean;
|
|
16
|
+
};
|
|
17
|
+
import { ShimEvent } from 'eventtargeter';
|
|
18
|
+
import { ShimCustomEvent } from 'eventtargeter';
|
|
19
|
+
import { ShimEventTarget } from 'eventtargeter';
|
|
20
|
+
export { ShimEvent, ShimCustomEvent, ShimEventTarget };
|
|
21
|
+
//# sourceMappingURL=Event.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Event.d.ts","sourceRoot":"","sources":["../src/Event.js"],"names":[],"mappings":"6BAIa,KAAK;AADlB;;GAEG;AAEH;;;;;;;;GAQG;AACH,kCAPW,MAAM,qEAGJ,KAAK,GAAG;IACpB,oCAAwC,CAAC,EAAE,OAAO,CAAA;CAC/C,CAOH;0BArByD,eAAe;gCAAf,eAAe;gCAAf,eAAe"}
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
export type Integer = number;
|
|
2
|
+
export type IDBCursorFull = IDBCursor & {
|
|
3
|
+
primaryKey: import('./Key.js').Key;
|
|
4
|
+
key: import('./Key.js').Key;
|
|
5
|
+
direction: string;
|
|
6
|
+
source: import('./IDBObjectStore.js').IDBObjectStoreFull | import('./IDBIndex.js').IDBIndexFull;
|
|
7
|
+
__request: import('./IDBRequest.js').IDBRequestFull;
|
|
8
|
+
__advanceCount: Integer | undefined;
|
|
9
|
+
__indexSource: boolean;
|
|
10
|
+
__key: import('./Key.js').Key;
|
|
11
|
+
__primaryKey: import('./Key.js').Key;
|
|
12
|
+
__value: import('./Key.js').Value;
|
|
13
|
+
__store: import('./IDBObjectStore.js').IDBObjectStoreFull;
|
|
14
|
+
__range: import('./IDBKeyRange.js').IDBKeyRangeFull | undefined;
|
|
15
|
+
__keyColumnName: string;
|
|
16
|
+
__valueColumnName: string;
|
|
17
|
+
__keyOnly: boolean;
|
|
18
|
+
__valueDecoder: {
|
|
19
|
+
decode: (str: string) => any;
|
|
20
|
+
};
|
|
21
|
+
__count: boolean;
|
|
22
|
+
__prefetchedIndex: Integer;
|
|
23
|
+
__prefetchedData: SQLResultSetRowList | {
|
|
24
|
+
data: RowItemNonNull[];
|
|
25
|
+
length: Integer;
|
|
26
|
+
item: (index: Integer) => RowItemNonNull;
|
|
27
|
+
} | null;
|
|
28
|
+
__multiEntryIndex: boolean;
|
|
29
|
+
__unique: boolean;
|
|
30
|
+
__sqlDirection: "DESC" | "ASC";
|
|
31
|
+
__matchedKeys: {
|
|
32
|
+
[key: string]: true;
|
|
33
|
+
};
|
|
34
|
+
__invalidateCache: () => void;
|
|
35
|
+
};
|
|
36
|
+
export type IDBCursorWithValueFull = IDBCursorFull & {
|
|
37
|
+
__request: import('./IDBRequest.js').IDBRequestFull;
|
|
38
|
+
};
|
|
39
|
+
export type KeySuccess = (k: import('./Key.js').Key, val: import('./Key.js').Value, primKey: import('./Key.js').Key) => void;
|
|
40
|
+
export type FindError = (tx: SQLTransaction | Error | DOMException | SQLError, err?: SQLError) => void;
|
|
41
|
+
export type StructuredCloneValue = any;
|
|
42
|
+
export type IndexedDBKey = any;
|
|
43
|
+
export type SuccessArg = (value: StructuredCloneValue, req: import('./IDBRequest.js').IDBRequestFull) => void;
|
|
44
|
+
export type SuccessCallback = (key: IndexedDBKey, value: StructuredCloneValue, primaryKey: IndexedDBKey) => void;
|
|
45
|
+
export type RowItemNonNull = {
|
|
46
|
+
[k: string]: string;
|
|
47
|
+
matchingKey: string;
|
|
48
|
+
key: string;
|
|
49
|
+
};
|
|
50
|
+
export type AnyValue = any;
|
|
51
|
+
/**
|
|
52
|
+
* @typedef {number} Integer
|
|
53
|
+
*/
|
|
54
|
+
/**
|
|
55
|
+
* @typedef {IDBCursor & {
|
|
56
|
+
* primaryKey: import('./Key.js').Key,
|
|
57
|
+
* key: import('./Key.js').Key,
|
|
58
|
+
* direction: string,
|
|
59
|
+
* source: import('./IDBObjectStore.js').IDBObjectStoreFull|
|
|
60
|
+
* import('./IDBIndex.js').IDBIndexFull,
|
|
61
|
+
* __request: import('./IDBRequest.js').IDBRequestFull,
|
|
62
|
+
* __advanceCount: Integer|undefined,
|
|
63
|
+
* __indexSource: boolean,
|
|
64
|
+
* __key: import('./Key.js').Key,
|
|
65
|
+
* __primaryKey: import('./Key.js').Key,
|
|
66
|
+
* __value: import('./Key.js').Value,
|
|
67
|
+
* __store: import('./IDBObjectStore.js').IDBObjectStoreFull,
|
|
68
|
+
* __range: import('./IDBKeyRange.js').IDBKeyRangeFull|undefined,
|
|
69
|
+
* __keyColumnName: string,
|
|
70
|
+
* __valueColumnName: string,
|
|
71
|
+
* __keyOnly: boolean,
|
|
72
|
+
* __valueDecoder: {
|
|
73
|
+
* decode: (str: string) => any,
|
|
74
|
+
* },
|
|
75
|
+
* __count: boolean,
|
|
76
|
+
* __prefetchedIndex: Integer,
|
|
77
|
+
* __prefetchedData: null|SQLResultSetRowList|{
|
|
78
|
+
* data: RowItemNonNull[],
|
|
79
|
+
* length: Integer,
|
|
80
|
+
* item: (index: Integer) => RowItemNonNull
|
|
81
|
+
* },
|
|
82
|
+
* __multiEntryIndex: boolean,
|
|
83
|
+
* __unique: boolean,
|
|
84
|
+
* __sqlDirection: "DESC"|"ASC",
|
|
85
|
+
* __matchedKeys: {[key: string]: true},
|
|
86
|
+
* __invalidateCache: () => void
|
|
87
|
+
* }} IDBCursorFull
|
|
88
|
+
*/
|
|
89
|
+
/**
|
|
90
|
+
* @typedef {IDBCursorFull & {
|
|
91
|
+
* __request: import('./IDBRequest.js').IDBRequestFull,
|
|
92
|
+
* }} IDBCursorWithValueFull
|
|
93
|
+
*/
|
|
94
|
+
/**
|
|
95
|
+
* @class
|
|
96
|
+
*/
|
|
97
|
+
export function IDBCursor(): void;
|
|
98
|
+
export class IDBCursor {
|
|
99
|
+
/**
|
|
100
|
+
*
|
|
101
|
+
* @param {...any} args
|
|
102
|
+
* @this {IDBCursorFull}
|
|
103
|
+
* @returns {void}
|
|
104
|
+
*/
|
|
105
|
+
__find(this: IDBCursorFull, ...args: any[]): void;
|
|
106
|
+
/**
|
|
107
|
+
* @typedef {(
|
|
108
|
+
* k: import('./Key.js').Key,
|
|
109
|
+
* val: import('./Key.js').Value,
|
|
110
|
+
* primKey: import('./Key.js').Key
|
|
111
|
+
* ) => void} KeySuccess
|
|
112
|
+
*/
|
|
113
|
+
/**
|
|
114
|
+
* @typedef {(tx: SQLTransaction|Error|DOMException|SQLError, err?: SQLError) => void} FindError
|
|
115
|
+
*/
|
|
116
|
+
/**
|
|
117
|
+
*
|
|
118
|
+
* @param {undefined|import('./Key.js').Key} key
|
|
119
|
+
* @param {undefined|import('./Key.js').Key} primaryKey
|
|
120
|
+
* @param {SQLTransaction} tx
|
|
121
|
+
* @param {KeySuccess} success
|
|
122
|
+
* @param {FindError} error
|
|
123
|
+
* @param {Integer|undefined} recordsToLoad
|
|
124
|
+
* @this {IDBCursorFull}
|
|
125
|
+
* @returns {void}
|
|
126
|
+
*/
|
|
127
|
+
__findBasic(this: IDBCursorFull, key: undefined | import('./Key.js').Key, primaryKey: undefined | import('./Key.js').Key, tx: SQLTransaction, success: KeySuccess, error: FindError, recordsToLoad: Integer | undefined): void;
|
|
128
|
+
/**
|
|
129
|
+
*
|
|
130
|
+
* @param {undefined|import('./Key.js').Key} key
|
|
131
|
+
* @param {undefined|import('./Key.js').Key} primaryKey
|
|
132
|
+
* @param {SQLTransaction} tx
|
|
133
|
+
* @param {KeySuccess} success
|
|
134
|
+
* @param {FindError} error
|
|
135
|
+
* @this {IDBCursorFull}
|
|
136
|
+
* @returns {void}
|
|
137
|
+
*/
|
|
138
|
+
__findMultiEntry(this: IDBCursorFull, key: undefined | import('./Key.js').Key, primaryKey: undefined | import('./Key.js').Key, tx: SQLTransaction, success: KeySuccess, error: FindError): void;
|
|
139
|
+
/**
|
|
140
|
+
* @typedef {any} StructuredCloneValue
|
|
141
|
+
*/
|
|
142
|
+
/**
|
|
143
|
+
* @typedef {any} IndexedDBKey
|
|
144
|
+
*/
|
|
145
|
+
/**
|
|
146
|
+
* @callback SuccessArg
|
|
147
|
+
* @param {StructuredCloneValue} value
|
|
148
|
+
* @param {import('./IDBRequest.js').IDBRequestFull} req
|
|
149
|
+
* @returns {void}
|
|
150
|
+
*/
|
|
151
|
+
/**
|
|
152
|
+
* @callback SuccessCallback
|
|
153
|
+
* @param {IndexedDBKey} key
|
|
154
|
+
* @param {StructuredCloneValue} value
|
|
155
|
+
* @param {IndexedDBKey} primaryKey
|
|
156
|
+
* @returns {void}
|
|
157
|
+
*/
|
|
158
|
+
/**
|
|
159
|
+
* Creates an "onsuccess" callback.
|
|
160
|
+
* @param {SuccessArg} success
|
|
161
|
+
* @this {IDBCursorFull}
|
|
162
|
+
* @returns {SuccessCallback}
|
|
163
|
+
*/
|
|
164
|
+
__onsuccess(this: IDBCursorFull, success: SuccessArg): SuccessCallback;
|
|
165
|
+
/**
|
|
166
|
+
* @typedef {{
|
|
167
|
+
* matchingKey: string,
|
|
168
|
+
* key: string,
|
|
169
|
+
* [k: string]: string
|
|
170
|
+
* }} RowItemNonNull
|
|
171
|
+
*/
|
|
172
|
+
/**
|
|
173
|
+
*
|
|
174
|
+
* @param {RowItemNonNull} rowItem
|
|
175
|
+
* @param {(
|
|
176
|
+
* key: import('./Key.js').Key,
|
|
177
|
+
* val: import('./Key.js').Value,
|
|
178
|
+
* primaryKey: import('./Key.js').Key,
|
|
179
|
+
* encKey?: string
|
|
180
|
+
* ) => void} callback
|
|
181
|
+
* @this {IDBCursorFull}
|
|
182
|
+
* @returns {void}
|
|
183
|
+
*/
|
|
184
|
+
__decode(this: IDBCursorFull, rowItem: RowItemNonNull, callback: (key: import('./Key.js').Key, val: import('./Key.js').Value, primaryKey: import('./Key.js').Key, encKey?: string) => void): void;
|
|
185
|
+
/**
|
|
186
|
+
* @this {IDBCursorFull}
|
|
187
|
+
* @returns {void}
|
|
188
|
+
*/
|
|
189
|
+
__sourceOrEffectiveObjStoreDeleted(this: IDBCursorFull): void;
|
|
190
|
+
/**
|
|
191
|
+
* @this {IDBCursorFull}
|
|
192
|
+
* @returns {void}
|
|
193
|
+
*/
|
|
194
|
+
__invalidateCache(this: IDBCursorFull): void;
|
|
195
|
+
__prefetchedData: any;
|
|
196
|
+
/**
|
|
197
|
+
*
|
|
198
|
+
* @param {import('./Key.js').Key} [key]
|
|
199
|
+
* @param {boolean} [advanceContinue]
|
|
200
|
+
* @this {IDBCursorFull}
|
|
201
|
+
* @returns {void}
|
|
202
|
+
*/
|
|
203
|
+
__continue(this: IDBCursorFull, key?: import('./Key.js').Key, advanceContinue?: boolean | undefined): void;
|
|
204
|
+
/**
|
|
205
|
+
*
|
|
206
|
+
* @param {import('./Key.js').Key} key
|
|
207
|
+
* @param {import('./Key.js').Key} primaryKey
|
|
208
|
+
* @param {boolean} advanceState
|
|
209
|
+
* @this {IDBCursorFull}
|
|
210
|
+
* @returns {void}
|
|
211
|
+
*/
|
|
212
|
+
__continueFinish(this: IDBCursorFull, key: import('./Key.js').Key, primaryKey: import('./Key.js').Key, advanceState: boolean): void;
|
|
213
|
+
__gotValue: boolean | undefined;
|
|
214
|
+
/**
|
|
215
|
+
* @this {IDBCursorFull}
|
|
216
|
+
* @returns {void}
|
|
217
|
+
*/
|
|
218
|
+
continue(this: IDBCursorFull, ...args: any[]): void;
|
|
219
|
+
/**
|
|
220
|
+
*
|
|
221
|
+
* @param {import('./Key.js').Key} key
|
|
222
|
+
* @param {import('./Key.js').Key} primaryKey
|
|
223
|
+
* @this {IDBCursorFull}
|
|
224
|
+
* @returns {void}
|
|
225
|
+
*/
|
|
226
|
+
continuePrimaryKey(this: IDBCursorFull, key: import('./Key.js').Key, primaryKey: import('./Key.js').Key): void;
|
|
227
|
+
/**
|
|
228
|
+
*
|
|
229
|
+
* @param {Integer} count
|
|
230
|
+
* @this {IDBCursorFull}
|
|
231
|
+
* @returns {void}
|
|
232
|
+
*/
|
|
233
|
+
advance(this: IDBCursorFull, count: Integer): void;
|
|
234
|
+
/**
|
|
235
|
+
* @typedef {any} AnyValue
|
|
236
|
+
*/
|
|
237
|
+
/**
|
|
238
|
+
*
|
|
239
|
+
* @param {AnyValue} valueToUpdate
|
|
240
|
+
* @this {IDBCursorFull}
|
|
241
|
+
* @returns {IDBRequest}
|
|
242
|
+
*/
|
|
243
|
+
update(this: IDBCursorFull, valueToUpdate: AnyValue, ...args: any[]): IDBRequest;
|
|
244
|
+
/**
|
|
245
|
+
* @this {IDBCursorFull}
|
|
246
|
+
* @returns {IDBRequest}
|
|
247
|
+
*/
|
|
248
|
+
delete(this: IDBCursorFull): IDBRequest;
|
|
249
|
+
}
|
|
250
|
+
export namespace IDBCursor {
|
|
251
|
+
/**
|
|
252
|
+
* The IndexedDB Cursor Object.
|
|
253
|
+
* @see http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#idl-def-IDBCursor
|
|
254
|
+
* @param {IDBKeyRange} query
|
|
255
|
+
* @param {string} direction
|
|
256
|
+
* @param {import('./IDBObjectStore.js').IDBObjectStoreFull} store
|
|
257
|
+
* @param {import('./IDBObjectStore.js').IDBObjectStoreFull|
|
|
258
|
+
* import('./IDBIndex.js').IDBIndexFull} source
|
|
259
|
+
* @param {string} keyColumnName
|
|
260
|
+
* @param {string} valueColumnName
|
|
261
|
+
* @param {boolean} count
|
|
262
|
+
* @this {IDBCursorFull}
|
|
263
|
+
* @returns {void}
|
|
264
|
+
*/
|
|
265
|
+
function __super(this: IDBCursorFull, query: IDBKeyRange, direction: string, store: import("./IDBObjectStore.js").IDBObjectStoreFull, source: import("./IDBObjectStore.js").IDBObjectStoreFull | import("./IDBIndex.js").IDBIndexFull, keyColumnName: string, valueColumnName: string, count: boolean): void;
|
|
266
|
+
/**
|
|
267
|
+
*
|
|
268
|
+
* @param {...any} args
|
|
269
|
+
* @returns {IDBCursorFull}
|
|
270
|
+
*/
|
|
271
|
+
function __createInstance(...args: any[]): IDBCursorFull;
|
|
272
|
+
}
|
|
273
|
+
/**
|
|
274
|
+
* @class
|
|
275
|
+
*/
|
|
276
|
+
export function IDBCursorWithValue(): void;
|
|
277
|
+
export class IDBCursorWithValue {
|
|
278
|
+
constructor: typeof IDBCursorWithValue;
|
|
279
|
+
}
|
|
280
|
+
export namespace IDBCursorWithValue {
|
|
281
|
+
/**
|
|
282
|
+
*
|
|
283
|
+
* @param {...any} args
|
|
284
|
+
* @returns {IDBCursorWithValueFull}
|
|
285
|
+
*/
|
|
286
|
+
function __createInstance(...args: any[]): IDBCursorWithValueFull;
|
|
287
|
+
}
|
|
288
|
+
import { IDBRequest } from './IDBRequest.js';
|
|
289
|
+
//# sourceMappingURL=IDBCursor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IDBCursor.d.ts","sourceRoot":"","sources":["../src/IDBCursor.js"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
export default IDBDatabase;
|
|
2
|
+
export type IDBObjectStoreProperties = {
|
|
3
|
+
name: string;
|
|
4
|
+
keyPath: import('./Key.js').KeyPath;
|
|
5
|
+
autoInc: boolean;
|
|
6
|
+
indexList: {
|
|
7
|
+
[key: string]: import("./IDBIndex.js").IDBIndexProperties;
|
|
8
|
+
};
|
|
9
|
+
idbdb: IDBDatabaseFull;
|
|
10
|
+
cursors?: (import("./IDBCursor.js").IDBCursorFull | import("./IDBCursor.js").IDBCursorWithValueFull)[] | undefined;
|
|
11
|
+
};
|
|
12
|
+
export type Integer = number;
|
|
13
|
+
export type IDBDatabaseFull = IDBDatabase & EventTarget & {
|
|
14
|
+
createObjectStore: (storeName: string) => IDBObjectStore;
|
|
15
|
+
deleteObjectStore: (storeName: string) => void;
|
|
16
|
+
close: () => void;
|
|
17
|
+
transaction: (storeNames: string | string[], mode: string) => IDBTransaction;
|
|
18
|
+
throwIfUpgradeTransactionNull: () => void;
|
|
19
|
+
objectStoreNames: import('./DOMStringList.js').DOMStringListFull;
|
|
20
|
+
name: string;
|
|
21
|
+
__forceClose: (msg: string) => void;
|
|
22
|
+
__db: import('websql-configurable/lib/websql/WebSQLDatabase.js').default;
|
|
23
|
+
__oldVersion: Integer;
|
|
24
|
+
__version: Integer;
|
|
25
|
+
__name: string;
|
|
26
|
+
__upgradeTransaction: null | import('./IDBTransaction.js').IDBTransactionFull;
|
|
27
|
+
__versionTransaction: import('./IDBTransaction.js').IDBTransactionFull;
|
|
28
|
+
__transactions: import('./IDBTransaction.js').IDBTransactionFull[];
|
|
29
|
+
__objectStores: {
|
|
30
|
+
[key: string]: IDBObjectStore;
|
|
31
|
+
};
|
|
32
|
+
__objectStoreNames: import('./DOMStringList.js').DOMStringListFull;
|
|
33
|
+
__oldObjectStoreNames: import('./DOMStringList.js').DOMStringListFull;
|
|
34
|
+
__unblocking: {
|
|
35
|
+
check: () => void;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* @typedef {{
|
|
40
|
+
* name: string,
|
|
41
|
+
* keyPath: import('./Key.js').KeyPath,
|
|
42
|
+
* autoInc: boolean,
|
|
43
|
+
* indexList: {[key: string]: import('./IDBIndex.js').IDBIndexProperties},
|
|
44
|
+
* idbdb: IDBDatabaseFull,
|
|
45
|
+
* cursors?: (import('./IDBCursor.js').IDBCursorFull|
|
|
46
|
+
* import('./IDBCursor.js').IDBCursorWithValueFull)[],
|
|
47
|
+
* }} IDBObjectStoreProperties
|
|
48
|
+
*/
|
|
49
|
+
/**
|
|
50
|
+
* IDB Database Object.
|
|
51
|
+
* @see http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#database-interface
|
|
52
|
+
* @class
|
|
53
|
+
*/
|
|
54
|
+
declare function IDBDatabase(): void;
|
|
55
|
+
declare class IDBDatabase {
|
|
56
|
+
__versionTransaction: any;
|
|
57
|
+
__objectStores: any;
|
|
58
|
+
/**
|
|
59
|
+
* Creates a new object store.
|
|
60
|
+
* @param {string} storeName
|
|
61
|
+
* @this {IDBDatabaseFull}
|
|
62
|
+
* @returns {IDBObjectStore}
|
|
63
|
+
*/
|
|
64
|
+
createObjectStore(this: IDBDatabaseFull, storeName: string, ...args: any[]): IDBObjectStore;
|
|
65
|
+
/**
|
|
66
|
+
* Deletes an object store.
|
|
67
|
+
* @param {string} storeName
|
|
68
|
+
* @throws {TypeError|DOMException}
|
|
69
|
+
* @this {IDBDatabaseFull}
|
|
70
|
+
* @returns {void}
|
|
71
|
+
*/
|
|
72
|
+
deleteObjectStore(this: IDBDatabaseFull, storeName: string, ...args: any[]): void;
|
|
73
|
+
/**
|
|
74
|
+
* @throws {TypeError}
|
|
75
|
+
* @this {IDBDatabaseFull}
|
|
76
|
+
* @returns {void}
|
|
77
|
+
*/
|
|
78
|
+
close(this: IDBDatabaseFull): void;
|
|
79
|
+
__closePending: boolean | undefined;
|
|
80
|
+
/**
|
|
81
|
+
* Starts a new transaction.
|
|
82
|
+
* @param {string|string[]} storeNames
|
|
83
|
+
* @this {IDBDatabaseFull}
|
|
84
|
+
* @returns {import('./IDBTransaction.js').IDBTransactionFull}
|
|
85
|
+
*/
|
|
86
|
+
transaction(this: IDBDatabaseFull, storeNames: string | string[], ...args: any[]): import('./IDBTransaction.js').IDBTransactionFull;
|
|
87
|
+
/**
|
|
88
|
+
* @see https://github.com/w3c/IndexedDB/issues/192
|
|
89
|
+
* @throws {DOMException}
|
|
90
|
+
* @this {IDBDatabaseFull}
|
|
91
|
+
* @returns {void}
|
|
92
|
+
*/
|
|
93
|
+
throwIfUpgradeTransactionNull(this: IDBDatabaseFull): void;
|
|
94
|
+
/**
|
|
95
|
+
*
|
|
96
|
+
* @param {string} msg
|
|
97
|
+
* @this {IDBDatabaseFull}
|
|
98
|
+
* @returns {void}
|
|
99
|
+
*/
|
|
100
|
+
__forceClose(this: IDBDatabaseFull, msg: string): void;
|
|
101
|
+
constructor: typeof IDBDatabase;
|
|
102
|
+
}
|
|
103
|
+
declare namespace IDBDatabase {
|
|
104
|
+
/**
|
|
105
|
+
* @typedef {number} Integer
|
|
106
|
+
*/
|
|
107
|
+
/**
|
|
108
|
+
* @typedef {IDBDatabase & EventTarget & {
|
|
109
|
+
* createObjectStore: (storeName: string) => IDBObjectStore,
|
|
110
|
+
* deleteObjectStore: (storeName: string) => void,
|
|
111
|
+
* close: () => void,
|
|
112
|
+
* transaction: (storeNames: string|string[], mode: string) => IDBTransaction,
|
|
113
|
+
* throwIfUpgradeTransactionNull: () => void,
|
|
114
|
+
* objectStoreNames: import('./DOMStringList.js').DOMStringListFull,
|
|
115
|
+
* name: string,
|
|
116
|
+
* __forceClose: (msg: string) => void,
|
|
117
|
+
* __db: import('websql-configurable/lib/websql/WebSQLDatabase.js').default,
|
|
118
|
+
* __oldVersion: Integer,
|
|
119
|
+
* __version: Integer,
|
|
120
|
+
* __name: string,
|
|
121
|
+
* __upgradeTransaction: null|import('./IDBTransaction.js').IDBTransactionFull,
|
|
122
|
+
* __versionTransaction: import('./IDBTransaction.js').IDBTransactionFull,
|
|
123
|
+
* __transactions: import('./IDBTransaction.js').IDBTransactionFull[],
|
|
124
|
+
* __objectStores: {[key: string]: IDBObjectStore},
|
|
125
|
+
* __objectStoreNames: import('./DOMStringList.js').DOMStringListFull,
|
|
126
|
+
* __oldObjectStoreNames: import('./DOMStringList.js').DOMStringListFull,
|
|
127
|
+
* __unblocking: {
|
|
128
|
+
* check: () => void
|
|
129
|
+
* }
|
|
130
|
+
* }} IDBDatabaseFull
|
|
131
|
+
*/
|
|
132
|
+
/**
|
|
133
|
+
* @param {import('websql-configurable').default} db
|
|
134
|
+
* @param {string} name
|
|
135
|
+
* @param {Integer} oldVersion
|
|
136
|
+
* @param {Integer} version
|
|
137
|
+
* @param {SQLResultSet} storeProperties
|
|
138
|
+
* @returns {IDBDatabaseFull}
|
|
139
|
+
*/
|
|
140
|
+
function __createInstance(db: any, name: string, oldVersion: number, version: number, storeProperties: SQLResultSet): IDBDatabaseFull;
|
|
141
|
+
}
|
|
142
|
+
import IDBObjectStore from './IDBObjectStore.js';
|
|
143
|
+
import IDBTransaction from './IDBTransaction.js';
|
|
144
|
+
//# sourceMappingURL=IDBDatabase.d.ts.map
|