Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1246)

Unified Diff: webkit/browser/quota/quota_manager.cc

Issue 23240002: Backend for DevTools quota managements. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/browser/quota/quota_manager.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/browser/quota/quota_manager.cc
diff --git a/webkit/browser/quota/quota_manager.cc b/webkit/browser/quota/quota_manager.cc
index ee5f81bdc0a85f46b65dc3776e3f31ad46a1e0f8..c9e02b59139717e9bbe51d033603c5f7b7a8526d 100644
--- a/webkit/browser/quota/quota_manager.cc
+++ b/webkit/browser/quota/quota_manager.cc
@@ -1076,6 +1076,25 @@ void QuotaManager::GetHostUsage(const std::string& host,
GetUsageTracker(type)->GetHostUsage(host, callback);
}
+void QuotaManager::GetHostUsage(const std::string& host,
+ StorageType type,
+ QuotaClient::ID client_id,
+ const UsageCallback& callback) {
+ LazyInitialize();
+ ClientUsageTracker* tracker =
+ GetUsageTracker(type)->GetClientTracker(client_id);
+ if (!tracker) {
+ callback.Run(0);
+ return;
+ }
+ tracker->GetHostUsage(host, callback);
+}
+
+bool QuotaManager::IsTrackingHostUsage(StorageType type,
+ QuotaClient::ID client_id) const {
+ return GetUsageTracker(type)->GetClientTracker(client_id) != NULL;
+}
+
void QuotaManager::GetStatistics(
std::map<std::string, std::string>* statistics) {
DCHECK(statistics);
« no previous file with comments | « webkit/browser/quota/quota_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698