summaryrefslogtreecommitdiffstats
path: root/net/disk_cache/file.h
diff options
context:
space:
mode:
authorrvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-23 18:47:25 +0000
committerrvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-23 18:47:25 +0000
commite1fcf1482fd306b7e404ed037106801840deda76 (patch)
treed5d26cf73f30a254aecca16dfba4f6f5e9bdba4c /net/disk_cache/file.h
parent8e3e066579460f88a19e2e6e091c396f3bd851c3 (diff)
downloadchromium_src-e1fcf1482fd306b7e404ed037106801840deda76.zip
chromium_src-e1fcf1482fd306b7e404ed037106801840deda76.tar.gz
chromium_src-e1fcf1482fd306b7e404ed037106801840deda76.tar.bz2
Disk cache: Extend the internal buffering performed by each entry
to cover external files. We now keep a variable-size buffer and use it even after we know that the data is not going to be stored by a block-file. The backend keeps track of the total memory used by all entries and prevents that value from going over a max value that depends on the total memory available. This CL removes the tests that were checking the synchronous operation of sparse IO because that model is no longer supported by the public API, and this CL would add complexity to them (they fail due to thread safety concerns). BUG=6626 TEST=net_unittests Review URL: http://codereview.chromium.org/3167020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@57082 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/disk_cache/file.h')
-rw-r--r--net/disk_cache/file.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/net/disk_cache/file.h b/net/disk_cache/file.h
index 2535866..43ba5c1 100644
--- a/net/disk_cache/file.h
+++ b/net/disk_cache/file.h
@@ -59,10 +59,6 @@ class File : public base::RefCounted<File> {
bool Write(const void* buffer, size_t buffer_len, size_t offset,
FileIOCallback* callback, bool* completed);
- // Performs asynchronous writes, but doesn't notify when done. Automatically
- // deletes buffer when done.
- bool PostWrite(const void* buffer, size_t buffer_len, size_t offset);
-
// Sets the file's length. The file is truncated or extended with zeros to
// the new length.
bool SetLength(size_t length);
@@ -77,7 +73,7 @@ class File : public base::RefCounted<File> {
// Performs the actual asynchronous write. If notify is set and there is no
// callback, the call will be re-synchronized.
bool AsyncWrite(const void* buffer, size_t buffer_len, size_t offset,
- bool notify, FileIOCallback* callback, bool* completed);
+ FileIOCallback* callback, bool* completed);
private:
bool init_;