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

Side by Side Diff: content/browser/appcache/appcache_storage.h

Issue 879393002: Expire appcaches that fail to update for "too long". (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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_APPCACHE_APPCACHE_STORAGE_H_ 5 #ifndef CONTENT_BROWSER_APPCACHE_APPCACHE_STORAGE_H_
6 #define CONTENT_BROWSER_APPCACHE_APPCACHE_STORAGE_H_ 6 #define CONTENT_BROWSER_APPCACHE_APPCACHE_STORAGE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 // will be marked. There is no delegate completion callback. 144 // will be marked. There is no delegate completion callback.
145 virtual void MarkEntryAsForeign(const GURL& entry_url, int64 cache_id) = 0; 145 virtual void MarkEntryAsForeign(const GURL& entry_url, int64 cache_id) = 0;
146 146
147 // Schedules a task to update persistent storage and doom the group and all 147 // Schedules a task to update persistent storage and doom the group and all
148 // related caches and responses for deletion. Upon completion the in-memory 148 // related caches and responses for deletion. Upon completion the in-memory
149 // instance is marked as obsolete and the delegate callback is called. 149 // instance is marked as obsolete and the delegate callback is called.
150 virtual void MakeGroupObsolete(AppCacheGroup* group, 150 virtual void MakeGroupObsolete(AppCacheGroup* group,
151 Delegate* delegate, 151 Delegate* delegate,
152 int response_code) = 0; 152 int response_code) = 0;
153 153
154 // Schedules a tast to update persistent storage with the times of the first
jsbell 2015/05/27 22:38:18 typo: tast->task
155 // evictable error and last successful full update check.
156 virtual void StoreEvictionTimes(AppCacheGroup* group) {}
157
154 // Cancels all pending callbacks for the delegate. The delegate callbacks 158 // Cancels all pending callbacks for the delegate. The delegate callbacks
155 // will not be invoked after, however any scheduled operations will still 159 // will not be invoked after, however any scheduled operations will still
156 // take place. The callbacks for subsequently scheduled operations are 160 // take place. The callbacks for subsequently scheduled operations are
157 // unaffected. 161 // unaffected.
158 void CancelDelegateCallbacks(Delegate* delegate) { 162 void CancelDelegateCallbacks(Delegate* delegate) {
159 DelegateReference* delegate_reference = GetDelegateReference(delegate); 163 DelegateReference* delegate_reference = GetDelegateReference(delegate);
160 if (delegate_reference) 164 if (delegate_reference)
161 delegate_reference->CancelReference(); 165 delegate_reference->CancelReference();
162 } 166 }
163 167
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 328
325 FRIEND_TEST_ALL_PREFIXES(content::AppCacheStorageTest, DelegateReferences); 329 FRIEND_TEST_ALL_PREFIXES(content::AppCacheStorageTest, DelegateReferences);
326 FRIEND_TEST_ALL_PREFIXES(content::AppCacheStorageTest, UsageMap); 330 FRIEND_TEST_ALL_PREFIXES(content::AppCacheStorageTest, UsageMap);
327 331
328 DISALLOW_COPY_AND_ASSIGN(AppCacheStorage); 332 DISALLOW_COPY_AND_ASSIGN(AppCacheStorage);
329 }; 333 };
330 334
331 } // namespace content 335 } // namespace content
332 336
333 #endif // CONTENT_BROWSER_APPCACHE_APPCACHE_STORAGE_H_ 337 #endif // CONTENT_BROWSER_APPCACHE_APPCACHE_STORAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698