| 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 <string> | 10 #include <string> |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 383 SpdyRstStreamControlFrame* CreateRstStream(SpdyStreamId stream_id, | 383 SpdyRstStreamControlFrame* CreateRstStream(SpdyStreamId stream_id, |
| 384 SpdyRstStreamStatus status) const; | 384 SpdyRstStreamStatus status) const; |
| 385 SpdySerializedFrame* SerializeRstStream( | 385 SpdySerializedFrame* SerializeRstStream( |
| 386 const SpdyRstStreamIR& rst_stream) const; | 386 const SpdyRstStreamIR& rst_stream) const; |
| 387 | 387 |
| 388 // Creates an instance of SpdySettingsControlFrame. The SETTINGS frame is | 388 // Creates an instance of SpdySettingsControlFrame. The SETTINGS frame is |
| 389 // used to communicate name/value pairs relevant to the communication channel. | 389 // used to communicate name/value pairs relevant to the communication channel. |
| 390 SpdySettingsControlFrame* CreateSettings(const SettingsMap& values) const; | 390 SpdySettingsControlFrame* CreateSettings(const SettingsMap& values) const; |
| 391 SpdySerializedFrame* SerializeSettings(const SpdySettingsIR& settings) const; | 391 SpdySerializedFrame* SerializeSettings(const SpdySettingsIR& settings) const; |
| 392 | 392 |
| 393 // Creates an instance of SpdyPingControlFrame. The unique_id is used to | 393 // Creates and serializes a PING frame. The unique_id is used to |
| 394 // identify the ping request/response. | 394 // identify the ping request/response. |
| 395 SpdyPingControlFrame* CreatePingFrame(uint32 unique_id) const; | 395 SpdyFrame* CreatePingFrame(uint32 unique_id) const; |
| 396 SpdySerializedFrame* SerializePing(const SpdyPingIR& ping) const; | 396 SpdySerializedFrame* SerializePing(const SpdyPingIR& ping) const; |
| 397 | 397 |
| 398 // Creates and serializes a GOAWAY frame. The GOAWAY frame is used | 398 // Creates and serializes a GOAWAY frame. The GOAWAY frame is used |
| 399 // prior to the shutting down of the TCP connection, and includes the | 399 // prior to the shutting down of the TCP connection, and includes the |
| 400 // stream_id of the last stream the sender of the frame is willing to process | 400 // stream_id of the last stream the sender of the frame is willing to process |
| 401 // to completion. | 401 // to completion. |
| 402 SpdyFrame* CreateGoAway(SpdyStreamId last_accepted_stream_id, | 402 SpdyFrame* CreateGoAway(SpdyStreamId last_accepted_stream_id, |
| 403 SpdyGoAwayStatus status) const; | 403 SpdyGoAwayStatus status) const; |
| 404 SpdySerializedFrame* SerializeGoAway(const SpdyGoAwayIR& goaway) const; | 404 SpdySerializedFrame* SerializeGoAway(const SpdyGoAwayIR& goaway) const; |
| 405 | 405 |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 664 // starts with HTTP. If it does, we likely have an HTTP response. This | 664 // starts with HTTP. If it does, we likely have an HTTP response. This |
| 665 // isn't guaranteed though: we could have gotten a settings frame and then | 665 // isn't guaranteed though: we could have gotten a settings frame and then |
| 666 // corrupt data that just looks like HTTP, but deterministic checking requires | 666 // corrupt data that just looks like HTTP, but deterministic checking requires |
| 667 // a lot more state. | 667 // a lot more state. |
| 668 bool probable_http_response_; | 668 bool probable_http_response_; |
| 669 }; | 669 }; |
| 670 | 670 |
| 671 } // namespace net | 671 } // namespace net |
| 672 | 672 |
| 673 #endif // NET_SPDY_SPDY_FRAMER_H_ | 673 #endif // NET_SPDY_SPDY_FRAMER_H_ |
| OLD | NEW |