dom/src/storage/PStorage.ipdl

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 /* -*- Mode: C++; c-basic-offset: 2; indent-tabs-mode: nil; tab-width: 8 -*- */
     2 /* vim: set sw=4 ts=8 et tw=80 ft=cpp : */
     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 protocol PContent;
     9 namespace mozilla {
    10 namespace dom {
    12 /* This protocol bridges async access to the database thread running on the parent process
    13  * and caches running on the child process.
    14  */
    15 sync protocol PStorage
    16 {
    17   manager PContent;
    19 parent:
    20   async __delete__();
    22   sync  Preload(nsCString scope, uint32_t alreadyLoadedCount)
    23     returns (nsString[] keys, nsString[] values, nsresult rv);
    25   async AsyncPreload(nsCString scope, bool priority);
    26   async AsyncGetUsage(nsCString scope);
    27   async AsyncAddItem(nsCString scope, nsString key, nsString value);
    28   async AsyncUpdateItem(nsCString scope, nsString key, nsString value);
    29   async AsyncRemoveItem(nsCString scope, nsString key);
    30   async AsyncClear(nsCString scope);
    31   async AsyncFlush();
    33 child:
    34   async Observe(nsCString topic, nsCString scopePrefix);
    35   async ScopesHavingData(nsCString[] scopes);
    36   async LoadItem(nsCString scope, nsString key, nsString value);
    37   async LoadDone(nsCString scope, nsresult rv);
    38   async LoadUsage(nsCString scope, int64_t usage);
    39   async Error(nsresult rv);
    40 };
    42 }
    43 }

mercurial