2015-11-22 12:43:55 +03:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
|
|
* You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
|
|
|
include protocol PQuota;
|
|
|
|
|
|
|
|
namespace mozilla {
|
|
|
|
namespace dom {
|
|
|
|
namespace quota {
|
|
|
|
|
2017-03-22 14:14:04 +03:00
|
|
|
struct OriginUsage
|
|
|
|
{
|
|
|
|
nsCString origin;
|
|
|
|
bool persisted;
|
|
|
|
uint64_t usage;
|
2018-02-20 16:54:17 +03:00
|
|
|
uint64_t lastAccessed;
|
2017-03-22 14:14:04 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
struct AllUsageResponse
|
|
|
|
{
|
|
|
|
OriginUsage[] originUsages;
|
|
|
|
};
|
|
|
|
|
2017-03-22 14:13:48 +03:00
|
|
|
struct OriginUsageResponse
|
2015-11-22 12:43:55 +03:00
|
|
|
{
|
|
|
|
uint64_t usage;
|
|
|
|
uint64_t fileUsage;
|
|
|
|
};
|
|
|
|
|
|
|
|
union UsageRequestResponse
|
|
|
|
{
|
|
|
|
nsresult;
|
2017-03-22 14:14:04 +03:00
|
|
|
AllUsageResponse;
|
2017-03-22 14:13:48 +03:00
|
|
|
OriginUsageResponse;
|
2015-11-22 12:43:55 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
protocol PQuotaUsageRequest
|
|
|
|
{
|
|
|
|
manager PQuota;
|
|
|
|
|
|
|
|
parent:
|
2016-01-27 00:51:53 +03:00
|
|
|
async Cancel();
|
2015-11-22 12:43:55 +03:00
|
|
|
|
|
|
|
child:
|
2016-01-27 00:51:53 +03:00
|
|
|
async __delete__(UsageRequestResponse response);
|
2015-11-22 12:43:55 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace quota
|
|
|
|
} // namespace dom
|
|
|
|
} // namespace mozilla
|