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

Side by Side Diff: content/browser/storage_partition_impl.h

Issue 1741123002: Add removal filter support for Cookies, Storage, and Content Settings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Renamed class, comments Created 4 years, 8 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 5 #ifndef CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
6 #define CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 6 #define CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 net::URLRequestContextGetter* request_context_getter, 80 net::URLRequestContextGetter* request_context_getter,
81 const base::Closure& callback) override; 81 const base::Closure& callback) override;
82 void ClearData(uint32_t remove_mask, 82 void ClearData(uint32_t remove_mask,
83 uint32_t quota_storage_remove_mask, 83 uint32_t quota_storage_remove_mask,
84 const GURL& storage_origin, 84 const GURL& storage_origin,
85 const OriginMatcherFunction& origin_matcher, 85 const OriginMatcherFunction& origin_matcher,
86 const base::Time begin, 86 const base::Time begin,
87 const base::Time end, 87 const base::Time end,
88 const base::Closure& callback) override; 88 const base::Closure& callback) override;
89 89
90 void ClearData(uint32_t remove_mask,
91 uint32_t quota_storage_remove_mask,
92 const OriginMatcherFunction& origin_matcher,
93 const CookieMatcherFunction& cookie_matcher,
94 const base::Time begin,
95 const base::Time end,
96 const base::Closure& callback) override;
97
90 void Flush() override; 98 void Flush() override;
91 99
92 WebRTCIdentityStore* GetWebRTCIdentityStore(); 100 WebRTCIdentityStore* GetWebRTCIdentityStore();
93 101
94 // Can return nullptr while |this| is being destroyed. 102 // Can return nullptr while |this| is being destroyed.
95 BrowserContext* browser_context() const; 103 BrowserContext* browser_context() const;
96 104
97 // Called by each renderer process once. 105 // Called by each renderer process once.
98 void Bind(mojo::InterfaceRequest<mojom::StoragePartitionService> request); 106 void Bind(mojo::InterfaceRequest<mojom::StoragePartitionService> request);
99 107
(...skipping 22 matching lines...) Expand all
122 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 130 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
123 RemoveQuotaManagedUnprotectedOrigins); 131 RemoveQuotaManagedUnprotectedOrigins);
124 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 132 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
125 RemoveQuotaManagedProtectedSpecificOrigin); 133 RemoveQuotaManagedProtectedSpecificOrigin);
126 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 134 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
127 RemoveQuotaManagedProtectedOrigins); 135 RemoveQuotaManagedProtectedOrigins);
128 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 136 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
129 RemoveQuotaManagedIgnoreDevTools); 137 RemoveQuotaManagedIgnoreDevTools);
130 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, RemoveCookieForever); 138 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, RemoveCookieForever);
131 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, RemoveCookieLastHour); 139 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, RemoveCookieLastHour);
140 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, RemoveCookieWithMatcher);
132 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 141 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
133 RemoveUnprotectedLocalStorageForever); 142 RemoveUnprotectedLocalStorageForever);
134 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 143 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
135 RemoveProtectedLocalStorageForever); 144 RemoveProtectedLocalStorageForever);
136 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest, 145 FRIEND_TEST_ALL_PREFIXES(StoragePartitionImplTest,
137 RemoveLocalStorageForLastWeek); 146 RemoveLocalStorageForLastWeek);
138 147
139 // |relative_partition_path| is the relative path under |profile_path| to the 148 // |relative_partition_path| is the relative path under |profile_path| to the
140 // StoragePartition's on-disk-storage. 149 // StoragePartition's on-disk-storage.
141 // 150 //
(...skipping 16 matching lines...) Expand all
158 IndexedDBContextImpl* indexed_db_context, 167 IndexedDBContextImpl* indexed_db_context,
159 CacheStorageContextImpl* cache_storage_context, 168 CacheStorageContextImpl* cache_storage_context,
160 ServiceWorkerContextWrapper* service_worker_context, 169 ServiceWorkerContextWrapper* service_worker_context,
161 WebRTCIdentityStore* webrtc_identity_store, 170 WebRTCIdentityStore* webrtc_identity_store,
162 storage::SpecialStoragePolicy* special_storage_policy, 171 storage::SpecialStoragePolicy* special_storage_policy,
163 GeofencingManager* geofencing_manager, 172 GeofencingManager* geofencing_manager,
164 HostZoomLevelContext* host_zoom_level_context, 173 HostZoomLevelContext* host_zoom_level_context,
165 PlatformNotificationContextImpl* platform_notification_context, 174 PlatformNotificationContextImpl* platform_notification_context,
166 BackgroundSyncContextImpl* background_sync_context); 175 BackgroundSyncContextImpl* background_sync_context);
167 176
177 // We will never have both remove_origin be populated and a cookie_matcher.
168 void ClearDataImpl(uint32_t remove_mask, 178 void ClearDataImpl(uint32_t remove_mask,
169 uint32_t quota_storage_remove_mask, 179 uint32_t quota_storage_remove_mask,
170 const GURL& remove_origin, 180 const GURL& remove_origin,
171 const OriginMatcherFunction& origin_matcher, 181 const OriginMatcherFunction& origin_matcher,
182 const CookieMatcherFunction& cookie_matcher,
172 net::URLRequestContextGetter* rq_context, 183 net::URLRequestContextGetter* rq_context,
173 const base::Time begin, 184 const base::Time begin,
174 const base::Time end, 185 const base::Time end,
175 const base::Closure& callback); 186 const base::Closure& callback);
176 187
177 // Used by StoragePartitionImplMap. 188 // Used by StoragePartitionImplMap.
178 // 189 //
179 // TODO(ajwong): These should be taken in the constructor and in Create() but 190 // TODO(ajwong): These should be taken in the constructor and in Create() but
180 // because the URLRequestContextGetter still lives in Profile with a tangled 191 // because the URLRequestContextGetter still lives in Profile with a tangled
181 // initialization, if we try to retrieve the URLRequestContextGetter() 192 // initialization, if we try to retrieve the URLRequestContextGetter()
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 // StoragePartitionImplMap which then owns StoragePartitionImpl. When the 226 // StoragePartitionImplMap which then owns StoragePartitionImpl. When the
216 // BrowserContext is destroyed, |this| will be destroyed too. 227 // BrowserContext is destroyed, |this| will be destroyed too.
217 BrowserContext* browser_context_; 228 BrowserContext* browser_context_;
218 229
219 DISALLOW_COPY_AND_ASSIGN(StoragePartitionImpl); 230 DISALLOW_COPY_AND_ASSIGN(StoragePartitionImpl);
220 }; 231 };
221 232
222 } // namespace content 233 } // namespace content
223 234
224 #endif // CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_ 235 #endif // CONTENT_BROWSER_STORAGE_PARTITION_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698