2017-03-22 14:13:38 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
|
|
|
/* 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/. */
|
|
|
|
|
|
|
|
#ifndef mozilla_dom_quota_QuotaResults_h
|
|
|
|
#define mozilla_dom_quota_QuotaResults_h
|
|
|
|
|
|
|
|
#include "nsIQuotaResults.h"
|
|
|
|
|
|
|
|
namespace mozilla {
|
|
|
|
namespace dom {
|
|
|
|
namespace quota {
|
|
|
|
|
2017-03-22 14:14:04 +03:00
|
|
|
class UsageResult
|
|
|
|
: public nsIQuotaUsageResult
|
|
|
|
{
|
|
|
|
nsCString mOrigin;
|
|
|
|
uint64_t mUsage;
|
|
|
|
bool mPersisted;
|
|
|
|
|
|
|
|
public:
|
|
|
|
UsageResult(const nsACString& aOrigin,
|
|
|
|
bool aPersisted,
|
|
|
|
uint64_t aUsage);
|
|
|
|
|
|
|
|
private:
|
|
|
|
virtual ~UsageResult()
|
|
|
|
{ }
|
|
|
|
|
|
|
|
NS_DECL_ISUPPORTS
|
|
|
|
NS_DECL_NSIQUOTAUSAGERESULT
|
|
|
|
};
|
|
|
|
|
2017-03-22 14:13:48 +03:00
|
|
|
class OriginUsageResult
|
|
|
|
: public nsIQuotaOriginUsageResult
|
2017-03-22 14:13:38 +03:00
|
|
|
{
|
|
|
|
uint64_t mUsage;
|
|
|
|
uint64_t mFileUsage;
|
|
|
|
uint64_t mLimit;
|
|
|
|
|
|
|
|
public:
|
2017-03-22 14:13:48 +03:00
|
|
|
OriginUsageResult(uint64_t aUsage,
|
|
|
|
uint64_t aFileUsage,
|
|
|
|
uint64_t aLimit);
|
2017-03-22 14:13:38 +03:00
|
|
|
|
|
|
|
private:
|
2017-03-22 14:13:48 +03:00
|
|
|
virtual ~OriginUsageResult()
|
2017-03-22 14:13:38 +03:00
|
|
|
{ }
|
|
|
|
|
|
|
|
NS_DECL_ISUPPORTS
|
2017-03-22 14:13:48 +03:00
|
|
|
NS_DECL_NSIQUOTAORIGINUSAGERESULT
|
2017-03-22 14:13:38 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace quota
|
|
|
|
} // namespace dom
|
|
|
|
} // namespace mozilla
|
|
|
|
|
|
|
|
#endif // mozilla_dom_quota_QuotaResults_h
|