| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef NET_SPDY_HPACK_DECODER_H_ | 5 #ifndef NET_SPDY_HPACK_DECODER_H_ |
| 6 #define NET_SPDY_HPACK_DECODER_H_ | 6 #define NET_SPDY_HPACK_DECODER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 | 96 |
| 97 // Huffman table to be applied to decoded Huffman literals, | 97 // Huffman table to be applied to decoded Huffman literals, |
| 98 // and scratch space for storing those decoded literals. | 98 // and scratch space for storing those decoded literals. |
| 99 const HpackHuffmanTable& huffman_table_; | 99 const HpackHuffmanTable& huffman_table_; |
| 100 std::string key_buffer_, value_buffer_; | 100 std::string key_buffer_, value_buffer_; |
| 101 | 101 |
| 102 // Handlers for decoding HPACK opcodes and header representations | 102 // Handlers for decoding HPACK opcodes and header representations |
| 103 // (or parts thereof). These methods return true on success and | 103 // (or parts thereof). These methods return true on success and |
| 104 // false on error. | 104 // false on error. |
| 105 bool DecodeNextOpcode(HpackInputStream* input_stream); | 105 bool DecodeNextOpcode(HpackInputStream* input_stream); |
| 106 bool DecodeNextContextUpdate(HpackInputStream* input_stream); | 106 bool DecodeNextHeaderTableSizeUpdate(HpackInputStream* input_stream); |
| 107 bool DecodeNextIndexedHeader(HpackInputStream* input_stream); | 107 bool DecodeNextIndexedHeader(HpackInputStream* input_stream); |
| 108 bool DecodeNextLiteralHeader(HpackInputStream* input_stream, | 108 bool DecodeNextLiteralHeader(HpackInputStream* input_stream, |
| 109 bool should_index); | 109 bool should_index); |
| 110 bool DecodeNextName(HpackInputStream* input_stream, | 110 bool DecodeNextName(HpackInputStream* input_stream, |
| 111 base::StringPiece* next_name); | 111 base::StringPiece* next_name); |
| 112 bool DecodeNextStringLiteral(HpackInputStream* input_stream, | 112 bool DecodeNextStringLiteral(HpackInputStream* input_stream, |
| 113 bool is_header_key, // As distinct from a value. | 113 bool is_header_key, // As distinct from a value. |
| 114 base::StringPiece* output); | 114 base::StringPiece* output); |
| 115 | 115 |
| 116 DISALLOW_COPY_AND_ASSIGN(HpackDecoder); | 116 DISALLOW_COPY_AND_ASSIGN(HpackDecoder); |
| 117 }; | 117 }; |
| 118 | 118 |
| 119 } // namespace net | 119 } // namespace net |
| 120 | 120 |
| 121 #endif // NET_SPDY_HPACK_DECODER_H_ | 121 #endif // NET_SPDY_HPACK_DECODER_H_ |
| OLD | NEW |