Index: net/filter/filter.h |
diff --git a/net/filter/filter.h b/net/filter/filter.h |
index 37f55e218b41e53cd57271eaedf9e729c13c0012..34c56ec4d7dd0d005934cc843b3ce39e2624c1f6 100644 |
--- a/net/filter/filter.h |
+++ b/net/filter/filter.h |
@@ -55,6 +55,7 @@ |
#include "base/memory/scoped_ptr.h" |
#include "base/time/time.h" |
#include "net/base/net_export.h" |
+#include "net/base/sdch_manager.h" |
class GURL; |
@@ -70,6 +71,14 @@ class IOBuffer; |
// is passed to the constructor of all those filters. To be clear, the context |
// does NOT reflect the position in a chain, or the fact that there are prior |
// or later filters in a chain. |
+// |
+// TODO(rdsmith): FilterContext is a grab-bag of methods which may or may |
+// not be relevant for any particular filter, and it's getting worse over |
+// time. In addition, it only supports two filters, sdch and gzip. |
Ryan Sleevi
2014/11/14 03:21:25
s/sdch/SDCH/
Randy Smith (Not in Mondays)
2014/11/17 17:04:22
Done.
|
+// It would make more sense to implement FilterContext as a |
+// base::SupportsUserData structure to which filter-specific information |
+// could be added by whatever the ultimate consumer of the filter chain is, |
+// and a particular filter (if included) could access that information. |
class NET_EXPORT_PRIVATE FilterContext { |
public: |
// Enum to control what histograms are emitted near end-of-life of this |
@@ -106,7 +115,7 @@ class NET_EXPORT_PRIVATE FilterContext { |
virtual bool IsDownload() const = 0; |
// Was this data flagged as a response to a request with an SDCH dictionary? |
- virtual bool SdchResponseExpected() const = 0; |
+ virtual SdchManager::DictionarySet* SdchDictionariesAdvertised() const = 0; |
// How many bytes were read from the net or cache so far (and potentially |
// pushed into a filter for processing)? |