| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_SPDY_FRAMER_H_ | 5 #ifndef NET_SPDY_SPDY_FRAMER_H_ |
| 6 #define NET_SPDY_SPDY_FRAMER_H_ | 6 #define NET_SPDY_SPDY_FRAMER_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 552 bool probable_http_response() const { return probable_http_response_; } | 552 bool probable_http_response() const { return probable_http_response_; } |
| 553 | 553 |
| 554 SpdyStreamId expect_continuation() const { return expect_continuation_; } | 554 SpdyStreamId expect_continuation() const { return expect_continuation_; } |
| 555 | 555 |
| 556 SpdyPriority GetLowestPriority() const { | 556 SpdyPriority GetLowestPriority() const { |
| 557 return spdy_version_ < SPDY3 ? 3 : 7; | 557 return spdy_version_ < SPDY3 ? 3 : 7; |
| 558 } | 558 } |
| 559 | 559 |
| 560 SpdyPriority GetHighestPriority() const { return 0; } | 560 SpdyPriority GetHighestPriority() const { return 0; } |
| 561 | 561 |
| 562 // Interpolates SpdyPriority values into SPDY4/HTTP2 priority weights, |
| 563 // and vice versa. |
| 564 uint8 MapPriorityToWeight(SpdyPriority priority); |
| 565 SpdyPriority MapWeightToPriority(uint8 weight); |
| 566 |
| 562 // Deliver the given control frame's compressed headers block to the visitor | 567 // Deliver the given control frame's compressed headers block to the visitor |
| 563 // in decompressed form, in chunks. Returns true if the visitor has | 568 // in decompressed form, in chunks. Returns true if the visitor has |
| 564 // accepted all of the chunks. | 569 // accepted all of the chunks. |
| 565 bool IncrementallyDecompressControlFrameHeaderData( | 570 bool IncrementallyDecompressControlFrameHeaderData( |
| 566 SpdyStreamId stream_id, | 571 SpdyStreamId stream_id, |
| 567 const char* data, | 572 const char* data, |
| 568 size_t len); | 573 size_t len); |
| 569 | 574 |
| 570 protected: | 575 protected: |
| 571 // TODO(jgraettinger): Switch to test peer pattern. | 576 // TODO(jgraettinger): Switch to test peer pattern. |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 792 // If a HEADERS frame is followed by a CONTINUATION frame, the FIN/END_STREAM | 797 // If a HEADERS frame is followed by a CONTINUATION frame, the FIN/END_STREAM |
| 793 // flag is still carried in the HEADERS frame. If it's set, flip this so that | 798 // flag is still carried in the HEADERS frame. If it's set, flip this so that |
| 794 // we know to terminate the stream when the entire header block has been | 799 // we know to terminate the stream when the entire header block has been |
| 795 // processed. | 800 // processed. |
| 796 bool end_stream_when_done_; | 801 bool end_stream_when_done_; |
| 797 }; | 802 }; |
| 798 | 803 |
| 799 } // namespace net | 804 } // namespace net |
| 800 | 805 |
| 801 #endif // NET_SPDY_SPDY_FRAMER_H_ | 806 #endif // NET_SPDY_SPDY_FRAMER_H_ |
| OLD | NEW |