OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // SdchFilter applies open_vcdiff content decoding to a datastream. | 5 // SdchFilter applies open_vcdiff content decoding to a datastream. |
6 // This decoding uses a pre-cached dictionary of text fragments to decode | 6 // This decoding uses a pre-cached dictionary of text fragments to decode |
7 // (expand) the stream back to its original contents. | 7 // (expand) the stream back to its original contents. |
8 // | 8 // |
9 // This SdchFilter internally uses open_vcdiff/vcdec library to do decoding. | 9 // This SdchFilter internally uses open_vcdiff/vcdec library to do decoding. |
10 // | 10 // |
11 // SdchFilter is also a subclass of Filter. See the latter's header file | 11 // SdchFilter is also a subclass of Filter. See the latter's header file |
12 // filter.h for sample usage. | 12 // filter.h for sample usage. |
13 | 13 |
14 #ifndef NET_BASE_SDCH_FILTER_H_ | 14 #ifndef NET_BASE_SDCH_FILTER_H_ |
15 #define NET_BASE_SDCH_FILTER_H_ | 15 #define NET_BASE_SDCH_FILTER_H_ |
16 #pragma once | 16 #pragma once |
17 | 17 |
18 #include <string> | 18 #include <string> |
19 | 19 |
20 #include "base/scoped_ptr.h" | 20 #include "base/scoped_ptr.h" |
21 #include "net/base/filter.h" | 21 #include "net/base/filter.h" |
22 #include "net/base/sdch_manager.h" | 22 #include "net/base/sdch_manager.h" |
23 | 23 |
24 class SafeOutputStringInterface; | |
25 | |
26 namespace open_vcdiff { | 24 namespace open_vcdiff { |
27 class VCDiffStreamingDecoder; | 25 class VCDiffStreamingDecoder; |
28 } | 26 } |
29 | 27 |
30 class SdchFilter : public Filter { | 28 class SdchFilter : public Filter { |
31 public: | 29 public: |
32 explicit SdchFilter(const FilterContext& filter_context); | 30 explicit SdchFilter(const FilterContext& filter_context); |
33 | 31 |
34 virtual ~SdchFilter(); | 32 virtual ~SdchFilter(); |
35 | 33 |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 GURL url_; | 109 GURL url_; |
112 | 110 |
113 // To facilitate error recovery, allow filter to know if content is text/html | 111 // To facilitate error recovery, allow filter to know if content is text/html |
114 // by checking within this mime type (we may do a meta-refresh via html). | 112 // by checking within this mime type (we may do a meta-refresh via html). |
115 std::string mime_type_; | 113 std::string mime_type_; |
116 | 114 |
117 DISALLOW_COPY_AND_ASSIGN(SdchFilter); | 115 DISALLOW_COPY_AND_ASSIGN(SdchFilter); |
118 }; | 116 }; |
119 | 117 |
120 #endif // NET_BASE_SDCH_FILTER_H_ | 118 #endif // NET_BASE_SDCH_FILTER_H_ |
OLD | NEW |