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> |
11 | 11 |
12 #include "base/macros.h" | 12 #include "base/macros.h" |
13 #include "net/base/net_export.h" | 13 #include "net/base/net_export.h" |
14 #include "net/quic/core/quic_header_list.h" | 14 #include "net/quic/core/quic_header_list.h" |
15 #include "net/quic/core/quic_headers_stream.h" | 15 #include "net/quic/core/quic_headers_stream.h" |
16 #include "net/quic/core/quic_session.h" | 16 #include "net/quic/core/quic_session.h" |
17 #include "net/quic/core/quic_spdy_stream.h" | 17 #include "net/quic/core/quic_spdy_stream.h" |
18 | 18 |
19 namespace net { | 19 namespace net { |
20 | 20 |
21 namespace test { | 21 namespace test { |
22 class QuicSpdySessionPeer; | 22 class QuicSpdySessionPeer; |
23 } // namespace test | 23 } // namespace test |
24 | 24 |
25 // A QUIC session with a headers stream. | 25 // A QUIC session with a headers stream. |
26 class NET_EXPORT_PRIVATE QuicSpdySession : public QuicSession { | 26 class NET_EXPORT_PRIVATE QuicSpdySession : public QuicSession { |
27 public: | 27 public: |
28 // Does not take ownership of |connection|. | 28 // Does not take ownership of |connection| or |visitor|. |
29 QuicSpdySession(QuicConnection* connection, const QuicConfig& config); | 29 QuicSpdySession(QuicConnection* connection, |
| 30 QuicSession::Visitor* visitor, |
| 31 const QuicConfig& config); |
30 | 32 |
31 ~QuicSpdySession() override; | 33 ~QuicSpdySession() override; |
32 | 34 |
33 void Initialize() override; | 35 void Initialize() override; |
34 | 36 |
35 // Called by |headers_stream_| when headers with a priority have been | 37 // Called by |headers_stream_| when headers with a priority have been |
36 // received for this stream. This method will only be called for server | 38 // received for this stream. This method will only be called for server |
37 // streams. | 39 // streams. |
38 virtual void OnStreamHeadersPriority(QuicStreamId stream_id, | 40 virtual void OnStreamHeadersPriority(QuicStreamId stream_id, |
39 SpdyPriority priority); | 41 SpdyPriority priority); |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 // Set during handshake. If true, resources in x-associated-content and link | 130 // Set during handshake. If true, resources in x-associated-content and link |
129 // headers will be pushed. | 131 // headers will be pushed. |
130 bool server_push_enabled_; | 132 bool server_push_enabled_; |
131 | 133 |
132 DISALLOW_COPY_AND_ASSIGN(QuicSpdySession); | 134 DISALLOW_COPY_AND_ASSIGN(QuicSpdySession); |
133 }; | 135 }; |
134 | 136 |
135 } // namespace net | 137 } // namespace net |
136 | 138 |
137 #endif // NET_QUIC_QUIC_SPDY_SESSION_H_ | 139 #endif // NET_QUIC_QUIC_SPDY_SESSION_H_ |
OLD | NEW |