Index: webkit/quota/quota_manager.h |
diff --git a/webkit/quota/quota_manager.h b/webkit/quota/quota_manager.h |
index 255c0e63426e24d29da9bcc4f7bdda2a2d3e4314..0007f950dc1851889435ba42a1681cdcd8ac7abb 100644 |
--- a/webkit/quota/quota_manager.h |
+++ b/webkit/quota/quota_manager.h |
@@ -74,6 +74,16 @@ class QuotaEvictionHandler { |
GetUsageAndQuotaForEvictionCallback* callback) = 0; |
}; |
+struct UsageInfo { |
+ UsageInfo(const std::string& host, StorageType type, int64 usage) |
+ : host(host), |
+ type(type), |
+ usage(usage) {} |
+ std::string host; |
+ StorageType type; |
+ int usage; |
kinuko
2011/10/03 07:49:20
int64?
mnaganov (inactive)
2011/10/04 03:00:40
Done. Thanks!
|
+}; |
+ |
// The quota manager class. This class is instantiated per profile and |
// held by the profile. With the exception of the constructor and the |
// proxy() method, all methods should only be called on the IO thread. |
@@ -97,6 +107,9 @@ class QuotaManager : public QuotaTaskObserver, |
// Returns a proxy object that can be used on any thread. |
QuotaManagerProxy* proxy() { return proxy_.get(); } |
+ // Called by clients or webapps. Returns usage per host. |
+ void GetUsage(GetUsageCallback* callback); |
+ |
// Called by clients or webapps. |
// This method is declared as virtual to allow test code to override it. |
// note: returns host usage and quota |
@@ -188,6 +201,7 @@ class QuotaManager : public QuotaTaskObserver, |
class UpdateModifiedTimeTask; |
class GetModifiedSinceTask; |
+ class GetUsageTask; |
class UsageAndQuotaDispatcherTask; |
class UsageAndQuotaDispatcherTaskForTemporary; |
class UsageAndQuotaDispatcherTaskForPersistent; |