OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_CLIENT_SESSION_BASE_H_ | 5 #ifndef NET_QUIC_QUIC_CLIENT_SESSION_BASE_H_ |
6 #define NET_QUIC_QUIC_CLIENT_SESSION_BASE_H_ | 6 #define NET_QUIC_QUIC_CLIENT_SESSION_BASE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 | 28 |
29 // The maximum time a promises stream can be reserved without being | 29 // The maximum time a promises stream can be reserved without being |
30 // claimed by a client request. | 30 // claimed by a client request. |
31 const int64_t kPushPromiseTimeoutSecs = 60; | 31 const int64_t kPushPromiseTimeoutSecs = 60; |
32 | 32 |
33 // Base class for all client-specific QuicSession subclasses. | 33 // Base class for all client-specific QuicSession subclasses. |
34 class NET_EXPORT_PRIVATE QuicClientSessionBase | 34 class NET_EXPORT_PRIVATE QuicClientSessionBase |
35 : public QuicSpdySession, | 35 : public QuicSpdySession, |
36 public QuicCryptoClientStream::ProofHandler { | 36 public QuicCryptoClientStream::ProofHandler { |
37 public: | 37 public: |
38 // Caller retains ownership of |promised_by_url|. | 38 // Takes ownership of |connection|. Caller retains ownership of |
| 39 // |promised_by_url|. |
39 QuicClientSessionBase(QuicConnection* connection, | 40 QuicClientSessionBase(QuicConnection* connection, |
40 QuicClientPushPromiseIndex* push_promise_index, | 41 QuicClientPushPromiseIndex* push_promise_index, |
41 const QuicConfig& config); | 42 const QuicConfig& config); |
42 | 43 |
43 ~QuicClientSessionBase() override; | 44 ~QuicClientSessionBase() override; |
44 | 45 |
45 void OnConfigNegotiated() override; | 46 void OnConfigNegotiated() override; |
46 | 47 |
47 // Override base class to set FEC policy before any data is sent by client. | 48 // Override base class to set FEC policy before any data is sent by client. |
48 void OnCryptoHandshakeEvent(CryptoHandshakeEvent event) override; | 49 void OnCryptoHandshakeEvent(CryptoHandshakeEvent event) override; |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 QuicClientPushPromiseIndex* push_promise_index_; | 130 QuicClientPushPromiseIndex* push_promise_index_; |
130 QuicPromisedByIdMap promised_by_id_; | 131 QuicPromisedByIdMap promised_by_id_; |
131 QuicStreamId largest_promised_stream_id_; | 132 QuicStreamId largest_promised_stream_id_; |
132 | 133 |
133 DISALLOW_COPY_AND_ASSIGN(QuicClientSessionBase); | 134 DISALLOW_COPY_AND_ASSIGN(QuicClientSessionBase); |
134 }; | 135 }; |
135 | 136 |
136 } // namespace net | 137 } // namespace net |
137 | 138 |
138 #endif // NET_QUIC_QUIC_CLIENT_SESSION_BASE_H_ | 139 #endif // NET_QUIC_QUIC_CLIENT_SESSION_BASE_H_ |
OLD | NEW |