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

Side by Side Diff: net/disk_cache/backend_impl.h

Issue 8794003: base::Bind: Convert disk_cache_based_ssl_host_info. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove an OldCompletionCallback. Created 9 years 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
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 // 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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 net::NetLog* net_log, Backend** backend, 58 net::NetLog* net_log, Backend** backend,
59 OldCompletionCallback* callback); 59 OldCompletionCallback* callback);
60 60
61 // Performs general initialization for this current instance of the cache. 61 // Performs general initialization for this current instance of the cache.
62 int Init(OldCompletionCallback* callback); 62 int Init(OldCompletionCallback* callback);
63 63
64 // Performs the actual initialization and final cleanup on destruction. 64 // Performs the actual initialization and final cleanup on destruction.
65 int SyncInit(); 65 int SyncInit();
66 void CleanupCache(); 66 void CleanupCache();
67 67
68 // Same bahavior as OpenNextEntry but walks the list from back to front. 68 // Same behavior as OpenNextEntry but walks the list from back to front.
69 int OpenPrevEntry(void** iter, Entry** prev_entry, 69 int OpenPrevEntry(void** iter, Entry** prev_entry,
70 OldCompletionCallback* callback); 70 OldCompletionCallback* callback);
71 71
72 // Synchronous implementation of the asynchronous interface. 72 // Synchronous implementation of the asynchronous interface.
73 int SyncOpenEntry(const std::string& key, Entry** entry); 73 int SyncOpenEntry(const std::string& key, Entry** entry);
74 int SyncCreateEntry(const std::string& key, Entry** entry); 74 int SyncCreateEntry(const std::string& key, Entry** entry);
75 int SyncDoomEntry(const std::string& key); 75 int SyncDoomEntry(const std::string& key);
76 int SyncDoomAllEntries(); 76 int SyncDoomAllEntries();
77 int SyncDoomEntriesBetween(const base::Time initial_time, 77 int SyncDoomEntriesBetween(const base::Time initial_time,
78 const base::Time end_time); 78 const base::Time end_time);
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 void TrimDeletedListForTest(bool empty); 253 void TrimDeletedListForTest(bool empty);
254 254
255 // Peforms a simple self-check, and returns the number of dirty items 255 // Peforms a simple self-check, and returns the number of dirty items
256 // or an error code (negative value). 256 // or an error code (negative value).
257 int SelfCheck(); 257 int SelfCheck();
258 258
259 // Backend interface. 259 // Backend interface.
260 virtual int32 GetEntryCount() const OVERRIDE; 260 virtual int32 GetEntryCount() const OVERRIDE;
261 virtual int OpenEntry(const std::string& key, Entry** entry, 261 virtual int OpenEntry(const std::string& key, Entry** entry,
262 OldCompletionCallback* callback) OVERRIDE; 262 OldCompletionCallback* callback) OVERRIDE;
263 virtual int OpenEntry(const std::string& key, Entry** entry,
264 const net::CompletionCallback& callback) OVERRIDE;
263 virtual int CreateEntry(const std::string& key, Entry** entry, 265 virtual int CreateEntry(const std::string& key, Entry** entry,
264 OldCompletionCallback* callback) OVERRIDE; 266 OldCompletionCallback* callback) OVERRIDE;
267 virtual int CreateEntry(const std::string& key, Entry** entry,
268 const net::CompletionCallback& callback) OVERRIDE;
265 virtual int DoomEntry(const std::string& key, 269 virtual int DoomEntry(const std::string& key,
266 OldCompletionCallback* callback) OVERRIDE; 270 OldCompletionCallback* callback) OVERRIDE;
267 virtual int DoomAllEntries(OldCompletionCallback* callback) OVERRIDE; 271 virtual int DoomAllEntries(OldCompletionCallback* callback) OVERRIDE;
268 virtual int DoomEntriesBetween(const base::Time initial_time, 272 virtual int DoomEntriesBetween(const base::Time initial_time,
269 const base::Time end_time, 273 const base::Time end_time,
270 OldCompletionCallback* callback) OVERRIDE; 274 OldCompletionCallback* callback) OVERRIDE;
271 virtual int DoomEntriesSince(const base::Time initial_time, 275 virtual int DoomEntriesSince(const base::Time initial_time,
272 OldCompletionCallback* callback) OVERRIDE; 276 OldCompletionCallback* callback) OVERRIDE;
273 virtual int OpenNextEntry(void** iter, Entry** next_entry, 277 virtual int OpenNextEntry(void** iter, Entry** next_entry,
274 OldCompletionCallback* callback) OVERRIDE; 278 OldCompletionCallback* callback) OVERRIDE;
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 394
391 DISALLOW_COPY_AND_ASSIGN(BackendImpl); 395 DISALLOW_COPY_AND_ASSIGN(BackendImpl);
392 }; 396 };
393 397
394 // Returns the prefered max cache size given the available disk space. 398 // Returns the prefered max cache size given the available disk space.
395 NET_EXPORT_PRIVATE int PreferedCacheSize(int64 available); 399 NET_EXPORT_PRIVATE int PreferedCacheSize(int64 available);
396 400
397 } // namespace disk_cache 401 } // namespace disk_cache
398 402
399 #endif // NET_DISK_CACHE_BACKEND_IMPL_H_ 403 #endif // NET_DISK_CACHE_BACKEND_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698