OLD | NEW |
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 // See net/disk_cache/disk_cache.h for the public interface of the cache. | 5 // See net/disk_cache/disk_cache.h for the public interface of the cache. |
6 | 6 |
7 #ifndef NET_DISK_CACHE_BACKEND_IMPL_H_ | 7 #ifndef NET_DISK_CACHE_BACKEND_IMPL_H_ |
8 #define NET_DISK_CACHE_BACKEND_IMPL_H_ | 8 #define NET_DISK_CACHE_BACKEND_IMPL_H_ |
9 #pragma once | 9 #pragma once |
10 | 10 |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 const base::Time end_time, | 274 const base::Time end_time, |
275 OldCompletionCallback* callback) OVERRIDE; | 275 OldCompletionCallback* callback) OVERRIDE; |
276 virtual int DoomEntriesBetween( | 276 virtual int DoomEntriesBetween( |
277 const base::Time initial_time, | 277 const base::Time initial_time, |
278 const base::Time end_time, | 278 const base::Time end_time, |
279 const net::CompletionCallback& callback) OVERRIDE; | 279 const net::CompletionCallback& callback) OVERRIDE; |
280 virtual int DoomEntriesSince(const base::Time initial_time, | 280 virtual int DoomEntriesSince(const base::Time initial_time, |
281 OldCompletionCallback* callback) OVERRIDE; | 281 OldCompletionCallback* callback) OVERRIDE; |
282 virtual int OpenNextEntry(void** iter, Entry** next_entry, | 282 virtual int OpenNextEntry(void** iter, Entry** next_entry, |
283 OldCompletionCallback* callback) OVERRIDE; | 283 OldCompletionCallback* callback) OVERRIDE; |
| 284 virtual int OpenNextEntry(void** iter, Entry** next_entry, |
| 285 const net::CompletionCallback& callback) OVERRIDE; |
284 virtual void EndEnumeration(void** iter) OVERRIDE; | 286 virtual void EndEnumeration(void** iter) OVERRIDE; |
285 virtual void GetStats(StatsItems* stats) OVERRIDE; | 287 virtual void GetStats(StatsItems* stats) OVERRIDE; |
286 virtual void OnExternalCacheHit(const std::string& key) OVERRIDE; | 288 virtual void OnExternalCacheHit(const std::string& key) OVERRIDE; |
287 | 289 |
288 private: | 290 private: |
289 typedef base::hash_map<CacheAddr, EntryImpl*> EntriesMap; | 291 typedef base::hash_map<CacheAddr, EntryImpl*> EntriesMap; |
290 | 292 |
291 // Creates a new backing file for the cache index. | 293 // Creates a new backing file for the cache index. |
292 bool CreateBackingStore(disk_cache::File* file); | 294 bool CreateBackingStore(disk_cache::File* file); |
293 bool InitBackingStore(bool* file_created); | 295 bool InitBackingStore(bool* file_created); |
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
399 | 401 |
400 DISALLOW_COPY_AND_ASSIGN(BackendImpl); | 402 DISALLOW_COPY_AND_ASSIGN(BackendImpl); |
401 }; | 403 }; |
402 | 404 |
403 // Returns the prefered max cache size given the available disk space. | 405 // Returns the prefered max cache size given the available disk space. |
404 NET_EXPORT_PRIVATE int PreferedCacheSize(int64 available); | 406 NET_EXPORT_PRIVATE int PreferedCacheSize(int64 available); |
405 | 407 |
406 } // namespace disk_cache | 408 } // namespace disk_cache |
407 | 409 |
408 #endif // NET_DISK_CACHE_BACKEND_IMPL_H_ | 410 #endif // NET_DISK_CACHE_BACKEND_IMPL_H_ |
OLD | NEW |