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

Unified Diff: net/disk_cache/simple/simple_entry_impl.h

Issue 1977863003: SimpleCache: open with fewer seeks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@open-speeder-macbetter
Patch Set: actually fix test Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/disk_cache/simple/simple_entry_format.h ('k') | net/disk_cache/simple/simple_entry_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/disk_cache/simple/simple_entry_impl.h
diff --git a/net/disk_cache/simple/simple_entry_impl.h b/net/disk_cache/simple/simple_entry_impl.h
index f528bea580225fcef6c362d34b2be3402d76162f..3a0317c0ddb4e753aaa40d0a2ec731fc669f688a 100644
--- a/net/disk_cache/simple/simple_entry_impl.h
+++ b/net/disk_cache/simple/simple_entry_impl.h
@@ -79,6 +79,11 @@ class NET_EXPORT_PRIVATE SimpleEntryImpl : public Entry,
const std::string& key() const { return key_; }
uint64_t entry_hash() const { return entry_hash_; }
+
+ // The key is not a constructor parameter to the SimpleEntryImpl, because
+ // during cache iteration, it's necessary to open entries by their hash
+ // alone. In that case, the SimpleSynchronousEntry will read the key from disk
+ // and it will be set.
void SetKey(const std::string& key);
// From Entry:
« no previous file with comments | « net/disk_cache/simple/simple_entry_format.h ('k') | net/disk_cache/simple/simple_entry_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698