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_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ | 5 #ifndef NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ |
6 #define NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ | 6 #define NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 11 matching lines...) Expand all Loading... |
22 } // namespace test | 22 } // namespace test |
23 | 23 |
24 // All this does right now is aggregate data, and on fin, send an HTTP | 24 // All this does right now is aggregate data, and on fin, send an HTTP |
25 // response. | 25 // response. |
26 class QuicSimpleServerStream : public QuicSpdyStream { | 26 class QuicSimpleServerStream : public QuicSpdyStream { |
27 public: | 27 public: |
28 QuicSimpleServerStream(QuicStreamId id, QuicSpdySession* session); | 28 QuicSimpleServerStream(QuicStreamId id, QuicSpdySession* session); |
29 ~QuicSimpleServerStream() override; | 29 ~QuicSimpleServerStream() override; |
30 | 30 |
31 // QuicSpdyStream | 31 // QuicSpdyStream |
32 void OnInitialHeadersComplete(bool fin, size_t frame_len) override; | |
33 void OnTrailingHeadersComplete(bool fin, size_t frame_len) override; | |
34 void OnInitialHeadersComplete(bool fin, | 32 void OnInitialHeadersComplete(bool fin, |
35 size_t frame_len, | 33 size_t frame_len, |
36 const QuicHeaderList& header_list) override; | 34 const QuicHeaderList& header_list) override; |
37 void OnTrailingHeadersComplete(bool fin, | 35 void OnTrailingHeadersComplete(bool fin, |
38 size_t frame_len, | 36 size_t frame_len, |
39 const QuicHeaderList& header_list) override; | 37 const QuicHeaderList& header_list) override; |
40 | 38 |
41 // ReliableQuicStream implementation called by the sequencer when there is | 39 // ReliableQuicStream implementation called by the sequencer when there is |
42 // data (or a FIN) to be read. | 40 // data (or a FIN) to be read. |
43 void OnDataAvailable() override; | 41 void OnDataAvailable() override; |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 SpdyHeaderBlock request_headers_; | 79 SpdyHeaderBlock request_headers_; |
82 int64_t content_length_; | 80 int64_t content_length_; |
83 std::string body_; | 81 std::string body_; |
84 | 82 |
85 DISALLOW_COPY_AND_ASSIGN(QuicSimpleServerStream); | 83 DISALLOW_COPY_AND_ASSIGN(QuicSimpleServerStream); |
86 }; | 84 }; |
87 | 85 |
88 } // namespace net | 86 } // namespace net |
89 | 87 |
90 #endif // NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ | 88 #endif // NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_STREAM_H_ |
OLD | NEW |