diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:13:27 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:13:27 +0000 |
commit | 40a355a42d4a9444dc753c04c6608dade2f06a23 (patch) | |
tree | 871fc667d2de662f171103ce5ec067014ef85e61 /toolkit/components/kvstore/nsIKeyValue.idl | |
parent | Adding upstream version 124.0.1. (diff) | |
download | firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip |
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'toolkit/components/kvstore/nsIKeyValue.idl')
-rw-r--r-- | toolkit/components/kvstore/nsIKeyValue.idl | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/toolkit/components/kvstore/nsIKeyValue.idl b/toolkit/components/kvstore/nsIKeyValue.idl index b90d45fc5a..08cd548af2 100644 --- a/toolkit/components/kvstore/nsIKeyValue.idl +++ b/toolkit/components/kvstore/nsIKeyValue.idl @@ -22,7 +22,7 @@ interface nsIKeyValuePair; * for all use cases. Extension of this API to support transactions is tracked * by bug 1499238. * - * The kvstore.jsm module wraps this API in a more idiomatic, Promise-based + * The kvstore.sys.mjs module wraps this API in a more idiomatic, Promise-based * JS API that supports async/await. In most cases, you're better off using * that API from JS rather than using this one directly. Bug 1512319 tracks * native support for Promise in Rust-implemented XPCOM methods. @@ -33,6 +33,12 @@ interface nsIKeyValuePair; */ [scriptable, builtinclass, rust_sync, uuid(46c893dd-4c14-4de0-b33d-a1be18c6d062)] interface nsIKeyValueService : nsISupports { + cenum RecoveryStrategy: 8 { + ERROR, + DISCARD, + RENAME, + }; + /** * Get a handle to an existing database or a newly-created one * at the specified path and with the given name. @@ -46,6 +52,12 @@ interface nsIKeyValueService : nsISupports { in nsIKeyValueDatabaseCallback callback, in AUTF8String path, in AUTF8String name); + + void getOrCreateWithOptions( + in nsIKeyValueDatabaseCallback callback, + in AUTF8String path, + in AUTF8String name, + [optional] in nsIKeyValueService_RecoveryStrategy recoveryStrategy); }; /** @@ -157,7 +169,7 @@ interface nsIKeyValuePair : nsISupports { * an nsIKeyValuePair rather than an nsISupports, so consumers don't need * to QI it to that interface; but this interface doesn't implement the JS * iteration protocol (because the Rust-XPCOM bindings don't yet support it), - * which is another reason why you should use the kvstore.jsm module from JS + * which is another reason why you should use the kvstore.sys.mjs module from JS * instead of accessing this API directly. */ [scriptable, builtinclass, rust_sync, uuid(b9ba7116-b7ff-4717-9a28-a08e6879b199)] |