summaryrefslogtreecommitdiffstats
path: root/net/disk_cache/mem_backend_impl.h
diff options
context:
space:
mode:
authorerg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-07 23:02:11 +0000
committererg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-07 23:02:11 +0000
commit4b3c95dd199586b4c540800be8cd223e948e5e3f (patch)
treec97ef865a3c85f09e920d8b1bc4024a56bb8e8cf /net/disk_cache/mem_backend_impl.h
parentd160ec0e875e98829684f040d843e6a292dbb3ba (diff)
downloadchromium_src-4b3c95dd199586b4c540800be8cd223e948e5e3f.zip
chromium_src-4b3c95dd199586b4c540800be8cd223e948e5e3f.tar.gz
chromium_src-4b3c95dd199586b4c540800be8cd223e948e5e3f.tar.bz2
Start reordering the methods in headers in net/.
This patch also starts reordering some of the cc files to match their headers. More of both cleanups will be done in future patches. BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6085013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70799 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/disk_cache/mem_backend_impl.h')
-rw-r--r--net/disk_cache/mem_backend_impl.h42
1 files changed, 21 insertions, 21 deletions
diff --git a/net/disk_cache/mem_backend_impl.h b/net/disk_cache/mem_backend_impl.h
index c78c670..9b920ac5 100644
--- a/net/disk_cache/mem_backend_impl.h
+++ b/net/disk_cache/mem_backend_impl.h
@@ -34,25 +34,6 @@ class MemBackendImpl : public Backend {
// Performs general initialization for this current instance of the cache.
bool Init();
- // Backend interface.
- virtual int32 GetEntryCount() const;
- virtual int OpenEntry(const std::string& key, Entry** entry,
- CompletionCallback* callback);
- virtual int CreateEntry(const std::string& key, Entry** entry,
- CompletionCallback* callback);
- virtual int DoomEntry(const std::string& key, CompletionCallback* callback);
- virtual int DoomAllEntries(CompletionCallback* callback);
- virtual int DoomEntriesBetween(const base::Time initial_time,
- const base::Time end_time,
- CompletionCallback* callback);
- virtual int DoomEntriesSince(const base::Time initial_time,
- CompletionCallback* callback);
- virtual int OpenNextEntry(void** iter, Entry** next_entry,
- CompletionCallback* callback);
- virtual void EndEnumeration(void** iter);
- virtual void GetStats(
- std::vector<std::pair<std::string, std::string> >* stats) {}
-
// Sets the maximum size for the total amount of data stored by this instance.
bool SetMaxSize(int max_bytes);
@@ -77,7 +58,28 @@ class MemBackendImpl : public Backend {
// MemEntryImpl to remove a child entry from the ranking list.
void RemoveFromRankingList(MemEntryImpl* entry);
+ // Backend interface.
+ virtual int32 GetEntryCount() const;
+ virtual int OpenEntry(const std::string& key, Entry** entry,
+ CompletionCallback* callback);
+ virtual int CreateEntry(const std::string& key, Entry** entry,
+ CompletionCallback* callback);
+ virtual int DoomEntry(const std::string& key, CompletionCallback* callback);
+ virtual int DoomAllEntries(CompletionCallback* callback);
+ virtual int DoomEntriesBetween(const base::Time initial_time,
+ const base::Time end_time,
+ CompletionCallback* callback);
+ virtual int DoomEntriesSince(const base::Time initial_time,
+ CompletionCallback* callback);
+ virtual int OpenNextEntry(void** iter, Entry** next_entry,
+ CompletionCallback* callback);
+ virtual void EndEnumeration(void** iter);
+ virtual void GetStats(
+ std::vector<std::pair<std::string, std::string> >* stats) {}
+
private:
+ typedef base::hash_map<std::string, MemEntryImpl*> EntryMap;
+
// Old Backend interface.
bool OpenEntry(const std::string& key, Entry** entry);
bool CreateEntry(const std::string& key, Entry** entry);
@@ -97,8 +99,6 @@ class MemBackendImpl : public Backend {
void AddStorageSize(int32 bytes);
void SubstractStorageSize(int32 bytes);
- typedef base::hash_map<std::string, MemEntryImpl*> EntryMap;
-
EntryMap entries_;
MemRankings rankings_; // Rankings to be able to trim the cache.
int32 max_size_; // Maximum data size for this instance.