OLD | NEW |
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2015 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_QUIC_QUIC_SPDY_SESSION_H_ | 5 #ifndef NET_QUIC_QUIC_SPDY_SESSION_H_ |
6 #define NET_QUIC_QUIC_SPDY_SESSION_H_ | 6 #define NET_QUIC_QUIC_SPDY_SESSION_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 0; | 110 0; |
111 | 111 |
112 QuicSpdyStream* GetSpdyDataStream(const QuicStreamId stream_id); | 112 QuicSpdyStream* GetSpdyDataStream(const QuicStreamId stream_id); |
113 | 113 |
114 // If an incoming stream can be created, return true. | 114 // If an incoming stream can be created, return true. |
115 virtual bool ShouldCreateIncomingDynamicStream(QuicStreamId id) = 0; | 115 virtual bool ShouldCreateIncomingDynamicStream(QuicStreamId id) = 0; |
116 | 116 |
117 // If an outgoing stream can be created, return true. | 117 // If an outgoing stream can be created, return true. |
118 virtual bool ShouldCreateOutgoingDynamicStream() = 0; | 118 virtual bool ShouldCreateOutgoingDynamicStream() = 0; |
119 | 119 |
| 120 void OnCryptoHandshakeEvent(CryptoHandshakeEvent event) override; |
| 121 |
120 private: | 122 private: |
121 friend class test::QuicSpdySessionPeer; | 123 friend class test::QuicSpdySessionPeer; |
122 | 124 |
123 std::unique_ptr<QuicHeadersStream> headers_stream_; | 125 std::unique_ptr<QuicHeadersStream> headers_stream_; |
124 | 126 |
125 // If set, redirect all data through the headers stream in order to | 127 // If set, redirect all data through the headers stream in order to |
126 // simulate forced HOL blocking between streams as happens in | 128 // simulate forced HOL blocking between streams as happens in |
127 // HTTP/2 over TCP. | 129 // HTTP/2 over TCP. |
128 bool force_hol_blocking_; | 130 bool force_hol_blocking_; |
129 | 131 |
130 // Set during handshake. If true, resources in x-associated-content and link | 132 // Set during handshake. If true, resources in x-associated-content and link |
131 // headers will be pushed. | 133 // headers will be pushed. |
132 bool server_push_enabled_; | 134 bool server_push_enabled_; |
133 | 135 |
134 DISALLOW_COPY_AND_ASSIGN(QuicSpdySession); | 136 DISALLOW_COPY_AND_ASSIGN(QuicSpdySession); |
135 }; | 137 }; |
136 | 138 |
137 } // namespace net | 139 } // namespace net |
138 | 140 |
139 #endif // NET_QUIC_QUIC_SPDY_SESSION_H_ | 141 #endif // NET_QUIC_QUIC_SPDY_SESSION_H_ |
OLD | NEW |