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

Unified Diff: content/browser/cache_storage/cache_storage_manager.h

Issue 1297093002: Cache Storage API: Hook up to chrome://settings/cookies (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase onto https://codereview.chromium.org/1297023004 Created 5 years, 4 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
Index: content/browser/cache_storage/cache_storage_manager.h
diff --git a/content/browser/cache_storage/cache_storage_manager.h b/content/browser/cache_storage/cache_storage_manager.h
index b762a21a30645d6697c90d4e22f797cf18ea965f..0da27973086c7206efb134caee500f5264aa9bd6 100644
--- a/content/browser/cache_storage/cache_storage_manager.h
+++ b/content/browser/cache_storage/cache_storage_manager.h
@@ -14,6 +14,8 @@
#include "base/memory/ref_counted.h"
#include "content/browser/cache_storage/cache_storage.h"
#include "content/common/content_export.h"
+#include "content/public/browser/cache_storage_context.h"
+#include "content/public/browser/cache_storage_usage_info.h"
#include "net/url_request/url_request_context_getter.h"
#include "storage/browser/quota/quota_client.h"
#include "url/gurl.h"
@@ -45,6 +47,10 @@ class CONTENT_EXPORT CacheStorageManager {
static scoped_ptr<CacheStorageManager> Create(
CacheStorageManager* old_manager);
+ // Map a database identifier (computed from an origin) to the path.
+ static base::FilePath ConstructOriginPath(const base::FilePath& root_path,
+ const GURL& origin);
+
virtual ~CacheStorageManager();
// Methods to support the CacheStorage spec. These methods call the
@@ -79,9 +85,10 @@ class CONTENT_EXPORT CacheStorageManager {
}
private:
- friend class CacheStorageQuotaClient;
+ friend class CacheStorageContextImpl;
friend class CacheStorageManagerTest;
friend class CacheStorageMigrationTest;
+ friend class CacheStorageQuotaClient;
typedef std::map<GURL, CacheStorage*> CacheStorageMap;
@@ -93,7 +100,9 @@ class CONTENT_EXPORT CacheStorageManager {
// The returned CacheStorage* is owned by this manager.
CacheStorage* FindOrCreateCacheStorage(const GURL& origin);
- // QuotaClient support
+ // QuotaClient and Browsing Data Deletion support
+ void GetAllOriginsUsage(
+ const CacheStorageContext::GetUsageInfoCallback& callback);
void GetOriginUsage(const GURL& origin_url,
const storage::QuotaClient::GetUsageCallback& callback);
void GetOrigins(const storage::QuotaClient::GetOriginsCallback& callback);
@@ -102,6 +111,7 @@ class CONTENT_EXPORT CacheStorageManager {
const storage::QuotaClient::GetOriginsCallback& callback);
void DeleteOriginData(const GURL& origin,
const storage::QuotaClient::DeletionCallback& callback);
+ void DeleteOriginData(const GURL& origin);
static void DeleteOriginDidClose(
const GURL& origin,
const storage::QuotaClient::DeletionCallback& callback,
@@ -126,10 +136,6 @@ class CONTENT_EXPORT CacheStorageManager {
static base::FilePath ConstructLegacyOriginPath(
const base::FilePath& root_path,
const GURL& origin);
- // Map a database identifier (computed from an origin) to the path. Exposed
- // for testing.
- static base::FilePath ConstructOriginPath(const base::FilePath& root_path,
- const GURL& origin);
// Migrate from old origin-based path to storage identifier-based path.
// TODO(jsbell); Remove method and all calls after a few releases.
« no previous file with comments | « content/browser/cache_storage/cache_storage_context_impl.cc ('k') | content/browser/cache_storage/cache_storage_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698