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

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

Issue 14877019: Minor SimpleCacheBackend improvements. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 7 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
Index: net/disk_cache/simple/simple_index.h
diff --git a/net/disk_cache/simple/simple_index.h b/net/disk_cache/simple/simple_index.h
index e1d28197cbd69dcb22d52041c1e9e36fce34963f..a1bf7605b8e7f02150cee7abe2ff0525652d9cd3 100644
--- a/net/disk_cache/simple/simple_index.h
+++ b/net/disk_cache/simple/simple_index.h
@@ -138,6 +138,8 @@ class NET_EXPORT_PRIVATE SimpleIndex
void PostponeWritingToDisk();
+ void UpdateEntryIteratorSize(EntrySet::iterator* it, uint64 entry_size);
+
// Using the mtime of the file and its mtime, detects if the index file is
// stale.
static bool IsIndexFileStale(const base::FilePath& index_filename);
@@ -193,7 +195,9 @@ class NET_EXPORT_PRIVATE SimpleIndex
// PostponeWritingToDisk() may give up postponing and allow the write if it
// has been a while since last time we wrote.
base::TimeTicks last_write_to_disk_;
+
base::OneShotTimer<SimpleIndex> write_to_disk_timer_;
+ base::Closure write_to_disk_cb_;
typedef std::list<net::CompletionCallback> CallbackList;
CallbackList to_run_when_initialized_;

Powered by Google App Engine
This is Rietveld 408576698