| 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 client specific QuicSession subclass. This class owns the underlying | 5 // A client specific QuicSession subclass. This class owns the underlying |
| 6 // QuicConnection and QuicConnectionHelper objects. The connection stores | 6 // QuicConnection and QuicConnectionHelper objects. The connection stores |
| 7 // a non-owning pointer to the helper so this session needs to ensure that | 7 // a non-owning pointer to the helper so this session needs to ensure that |
| 8 // the helper outlives the connection. | 8 // the helper outlives the connection. |
| 9 | 9 |
| 10 #ifndef NET_QUIC_QUIC_CLIENT_SESSION_H_ | 10 #ifndef NET_QUIC_QUIC_CLIENT_SESSION_H_ |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "net/quic/quic_client_session_base.h" | 21 #include "net/quic/quic_client_session_base.h" |
| 22 #include "net/quic/quic_connection_logger.h" | 22 #include "net/quic/quic_connection_logger.h" |
| 23 #include "net/quic/quic_crypto_client_stream.h" | 23 #include "net/quic/quic_crypto_client_stream.h" |
| 24 #include "net/quic/quic_protocol.h" | 24 #include "net/quic/quic_protocol.h" |
| 25 #include "net/quic/quic_reliable_client_stream.h" | 25 #include "net/quic/quic_reliable_client_stream.h" |
| 26 | 26 |
| 27 namespace net { | 27 namespace net { |
| 28 | 28 |
| 29 class CertVerifyResult; | 29 class CertVerifyResult; |
| 30 class DatagramClientSocket; | 30 class DatagramClientSocket; |
| 31 class NetworkConnection; |
| 31 class QuicConnectionHelper; | 32 class QuicConnectionHelper; |
| 32 class QuicCryptoClientStreamFactory; | 33 class QuicCryptoClientStreamFactory; |
| 33 class QuicServerId; | 34 class QuicServerId; |
| 34 class QuicServerInfo; | 35 class QuicServerInfo; |
| 35 class QuicStreamFactory; | 36 class QuicStreamFactory; |
| 36 class SSLInfo; | 37 class SSLInfo; |
| 37 class TransportSecurityState; | 38 class TransportSecurityState; |
| 38 | 39 |
| 39 namespace test { | 40 namespace test { |
| 40 class QuicClientSessionPeer; | 41 class QuicClientSessionPeer; |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 89 | 90 |
| 90 // Constructs a new session which will own |connection|, but not | 91 // Constructs a new session which will own |connection|, but not |
| 91 // |stream_factory|, which must outlive this session. | 92 // |stream_factory|, which must outlive this session. |
| 92 // TODO(rch): decouple the factory from the session via a Delegate interface. | 93 // TODO(rch): decouple the factory from the session via a Delegate interface. |
| 93 QuicClientSession(QuicConnection* connection, | 94 QuicClientSession(QuicConnection* connection, |
| 94 scoped_ptr<DatagramClientSocket> socket, | 95 scoped_ptr<DatagramClientSocket> socket, |
| 95 QuicStreamFactory* stream_factory, | 96 QuicStreamFactory* stream_factory, |
| 96 TransportSecurityState* transport_security_state, | 97 TransportSecurityState* transport_security_state, |
| 97 scoped_ptr<QuicServerInfo> server_info, | 98 scoped_ptr<QuicServerInfo> server_info, |
| 98 const QuicConfig& config, | 99 const QuicConfig& config, |
| 100 NetworkConnection* network_connection, |
| 99 base::TaskRunner* task_runner, | 101 base::TaskRunner* task_runner, |
| 100 NetLog* net_log); | 102 NetLog* net_log); |
| 101 ~QuicClientSession() override; | 103 ~QuicClientSession() override; |
| 102 | 104 |
| 103 // Initialize session's connection to |server_id|. | 105 // Initialize session's connection to |server_id|. |
| 104 void InitializeSession( | 106 void InitializeSession( |
| 105 const QuicServerId& server_id, | 107 const QuicServerId& server_id, |
| 106 QuicCryptoClientConfig* config, | 108 QuicCryptoClientConfig* config, |
| 107 QuicCryptoClientStreamFactory* crypto_client_stream_factory); | 109 QuicCryptoClientStreamFactory* crypto_client_stream_factory); |
| 108 | 110 |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 246 // on this session. Existing stream will continue to be processed. | 248 // on this session. Existing stream will continue to be processed. |
| 247 bool going_away_; | 249 bool going_away_; |
| 248 base::WeakPtrFactory<QuicClientSession> weak_factory_; | 250 base::WeakPtrFactory<QuicClientSession> weak_factory_; |
| 249 | 251 |
| 250 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); | 252 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); |
| 251 }; | 253 }; |
| 252 | 254 |
| 253 } // namespace net | 255 } // namespace net |
| 254 | 256 |
| 255 #endif // NET_QUIC_QUIC_CLIENT_SESSION_H_ | 257 #endif // NET_QUIC_QUIC_CLIENT_SESSION_H_ |
| OLD | NEW |