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

Unified Diff: content/browser/byte_stream.h

Issue 22908008: Limit the total memory usage for Stream instances (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | « no previous file | content/browser/byte_stream.cc » ('j') | content/browser/byte_stream.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/byte_stream.h
diff --git a/content/browser/byte_stream.h b/content/browser/byte_stream.h
index 0b5640d07112c8ce882dc5cac5c564bf9c6029e1..96829986a67ad0c60936f00c9b47bf2cc0cf1656 100644
--- a/content/browser/byte_stream.h
+++ b/content/browser/byte_stream.h
@@ -153,6 +153,10 @@ class CONTENT_EXPORT ByteStreamWriter {
// or after callbacks may be called).
// The callback will not be called after ByteStreamWriter destruction.
virtual void RegisterCallback(const base::Closure& source_callback) = 0;
+
+ // Returns the number of bytes sent to the reader but not yet reported by
+ // the reader as read.
+ virtual size_t TotalBufferedBytes() const = 0;
kinuko 2013/08/14 09:32:23 nit: GetTotalBufferedBytes() per naming convention
tyoshino (SeeGerritForStatus) 2013/08/15 04:15:33 Done.
};
class CONTENT_EXPORT ByteStreamReader {
« no previous file with comments | « no previous file | content/browser/byte_stream.cc » ('j') | content/browser/byte_stream.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698