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 // A toy server specific QuicSession subclass. | 5 // A toy server specific QuicSession subclass. |
6 | 6 |
7 #ifndef NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ | 7 #ifndef NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ |
8 #define NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ | 8 #define NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ |
9 | 9 |
10 #include <stdint.h> | 10 #include <stdint.h> |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 is_cancelled(false) {} | 54 is_cancelled(false) {} |
55 SpdyHeaderBlock request_headers; | 55 SpdyHeaderBlock request_headers; |
56 QuicStreamId stream_id; | 56 QuicStreamId stream_id; |
57 SpdyPriority priority; | 57 SpdyPriority priority; |
58 bool is_cancelled; | 58 bool is_cancelled; |
59 }; | 59 }; |
60 | 60 |
61 // Takes ownership of |connection|. | 61 // Takes ownership of |connection|. |
62 QuicSimpleServerSession(const QuicConfig& config, | 62 QuicSimpleServerSession(const QuicConfig& config, |
63 QuicConnection* connection, | 63 QuicConnection* connection, |
64 QuicServerSessionBase::Visitor* visitor, | 64 QuicSession::Visitor* visitor, |
65 QuicCryptoServerStream::Helper* helper, | 65 QuicCryptoServerStream::Helper* helper, |
66 const QuicCryptoServerConfig* crypto_config, | 66 const QuicCryptoServerConfig* crypto_config, |
67 QuicCompressedCertsCache* compressed_certs_cache); | 67 QuicCompressedCertsCache* compressed_certs_cache); |
68 | 68 |
69 ~QuicSimpleServerSession() override; | 69 ~QuicSimpleServerSession() override; |
70 | 70 |
71 // When a stream is marked draining, it will decrease the number of open | 71 // When a stream is marked draining, it will decrease the number of open |
72 // streams. If it is an outgoing stream, try to open a new stream to send | 72 // streams. If it is an outgoing stream, try to open a new stream to send |
73 // remaing push responses. | 73 // remaing push responses. |
74 void StreamDraining(QuicStreamId id) override; | 74 void StreamDraining(QuicStreamId id) override; |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 // stream_id is always next_outgoing_stream_id_, and the last one is always | 149 // stream_id is always next_outgoing_stream_id_, and the last one is always |
150 // highest_promised_stream_id_. | 150 // highest_promised_stream_id_. |
151 std::deque<PromisedStreamInfo> promised_streams_; | 151 std::deque<PromisedStreamInfo> promised_streams_; |
152 | 152 |
153 DISALLOW_COPY_AND_ASSIGN(QuicSimpleServerSession); | 153 DISALLOW_COPY_AND_ASSIGN(QuicSimpleServerSession); |
154 }; | 154 }; |
155 | 155 |
156 } // namespace net | 156 } // namespace net |
157 | 157 |
158 #endif // NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ | 158 #endif // NET_TOOLS_QUIC_QUIC_SIMPLE_SERVER_SESSION_H_ |
OLD | NEW |