1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #include
"nsISupports.idl"
9 interface nsIPrincipal
;
12 * Methods specific to LocalStorage, see nsIDOMStorageManager for methods shared
13 * with SessionStorage. Methods may migrate there as SessionStorage is
16 [scriptable
, builtinclass
, uuid(d4f534da
-2744-4db3
-8774-8b187c64ade9
)]
17 interface nsILocalStorageManager
: nsISupports
19 readonly attribute
boolean nextGenLocalStorageEnabled
;
22 * Trigger preload of LocalStorage for the given principal. For use by
23 * ContentParent::AboutToLoadHttpDocumentForChild to maximize the
24 * amount of time we have to load the data off disk before the page might
25 * attempt to touch LocalStorage.
27 * This method will not create a QuotaManager-managed directory on disk if
28 * one does not already exist for the principal.
31 Promise preload
(in nsIPrincipal aPrincipal
);
34 Promise isPreloaded
(in nsIPrincipal aPrincipal
);
37 Promise getState
(in nsIPrincipal aPrincipal
);