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

Side by Side Diff: webkit/quota/usage_tracker.h

Issue 15695003: [Quota][Clean up] Drop StorageType in GlobalUsageCallback (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: testfix Created 7 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/quota/quota_types.h ('k') | webkit/quota/usage_tracker.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef WEBKIT_QUOTA_USAGE_TRACKER_H_ 5 #ifndef WEBKIT_QUOTA_USAGE_TRACKER_H_
6 #define WEBKIT_QUOTA_USAGE_TRACKER_H_ 6 #define WEBKIT_QUOTA_USAGE_TRACKER_H_
7 7
8 #include <list> 8 #include <list>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 struct TrackingInfo { 56 struct TrackingInfo {
57 TrackingInfo() : pending_clients(0), usage(0), unlimited_usage(0) {} 57 TrackingInfo() : pending_clients(0), usage(0), unlimited_usage(0) {}
58 int pending_clients; 58 int pending_clients;
59 int64 usage; 59 int64 usage;
60 int64 unlimited_usage; 60 int64 unlimited_usage;
61 }; 61 };
62 62
63 typedef std::map<QuotaClient::ID, ClientUsageTracker*> ClientTrackerMap; 63 typedef std::map<QuotaClient::ID, ClientUsageTracker*> ClientTrackerMap;
64 64
65 friend class ClientUsageTracker; 65 friend class ClientUsageTracker;
66 void DidGetClientGlobalUsage(StorageType type, int64 usage, 66 void DidGetClientGlobalUsage(int64 usage,
67 int64 unlimited_usage); 67 int64 unlimited_usage);
68 void DidGetClientHostUsage(const std::string& host, 68 void DidGetClientHostUsage(const std::string& host,
69 StorageType type,
70 int64 usage); 69 int64 usage);
71 70
72 const StorageType type_; 71 const StorageType type_;
73 ClientTrackerMap client_tracker_map_; 72 ClientTrackerMap client_tracker_map_;
74 TrackingInfo global_usage_; 73 TrackingInfo global_usage_;
75 std::map<std::string, TrackingInfo> outstanding_host_usage_; 74 std::map<std::string, TrackingInfo> outstanding_host_usage_;
76 75
77 GlobalUsageCallbackQueue global_usage_callbacks_; 76 GlobalUsageCallbackQueue global_usage_callbacks_;
78 HostUsageCallbackMap host_usage_callbacks_; 77 HostUsageCallbackMap host_usage_callbacks_;
79 78
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 HostUsageCallbackMap host_usage_callbacks_; 152 HostUsageCallbackMap host_usage_callbacks_;
154 153
155 scoped_refptr<SpecialStoragePolicy> special_storage_policy_; 154 scoped_refptr<SpecialStoragePolicy> special_storage_policy_;
156 155
157 DISALLOW_COPY_AND_ASSIGN(ClientUsageTracker); 156 DISALLOW_COPY_AND_ASSIGN(ClientUsageTracker);
158 }; 157 };
159 158
160 } // namespace quota 159 } // namespace quota
161 160
162 #endif // WEBKIT_QUOTA_USAGE_TRACKER_H_ 161 #endif // WEBKIT_QUOTA_USAGE_TRACKER_H_
OLDNEW
« no previous file with comments | « webkit/quota/quota_types.h ('k') | webkit/quota/usage_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698