| 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. | 5 // A client specific QuicSession subclass. |
| 6 | 6 |
| 7 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ | 7 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ |
| 8 #define NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ | 8 #define NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ |
| 9 | 9 |
| 10 #include <memory> |
| 10 #include <string> | 11 #include <string> |
| 11 | 12 |
| 12 #include "base/macros.h" | 13 #include "base/macros.h" |
| 13 #include "net/quic/quic_client_session_base.h" | 14 #include "net/quic/quic_client_session_base.h" |
| 14 #include "net/quic/quic_crypto_client_stream.h" | 15 #include "net/quic/quic_crypto_client_stream.h" |
| 15 #include "net/quic/quic_protocol.h" | 16 #include "net/quic/quic_protocol.h" |
| 16 #include "net/tools/quic/quic_spdy_client_stream.h" | 17 #include "net/tools/quic/quic_spdy_client_stream.h" |
| 17 | 18 |
| 18 namespace net { | 19 namespace net { |
| 19 | 20 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 // Unlike CreateOutgoingDynamicStream, which applies a bunch of sanity checks, | 75 // Unlike CreateOutgoingDynamicStream, which applies a bunch of sanity checks, |
| 75 // this simply returns a new QuicSpdyClientStream. This may be used by | 76 // this simply returns a new QuicSpdyClientStream. This may be used by |
| 76 // subclasses which want to use a subclass of QuicSpdyClientStream for streams | 77 // subclasses which want to use a subclass of QuicSpdyClientStream for streams |
| 77 // but wish to use the sanity checks in CreateOutgoingDynamicStream. | 78 // but wish to use the sanity checks in CreateOutgoingDynamicStream. |
| 78 virtual QuicSpdyClientStream* CreateClientStream(); | 79 virtual QuicSpdyClientStream* CreateClientStream(); |
| 79 | 80 |
| 80 const QuicServerId& server_id() { return server_id_; } | 81 const QuicServerId& server_id() { return server_id_; } |
| 81 QuicCryptoClientConfig* crypto_config() { return crypto_config_; } | 82 QuicCryptoClientConfig* crypto_config() { return crypto_config_; } |
| 82 | 83 |
| 83 private: | 84 private: |
| 84 scoped_ptr<QuicCryptoClientStreamBase> crypto_stream_; | 85 std::unique_ptr<QuicCryptoClientStreamBase> crypto_stream_; |
| 85 QuicServerId server_id_; | 86 QuicServerId server_id_; |
| 86 QuicCryptoClientConfig* crypto_config_; | 87 QuicCryptoClientConfig* crypto_config_; |
| 87 | 88 |
| 88 // If this is set to false, the client will ignore server GOAWAYs and allow | 89 // If this is set to false, the client will ignore server GOAWAYs and allow |
| 89 // the creation of streams regardless of the high chance they will fail. | 90 // the creation of streams regardless of the high chance they will fail. |
| 90 bool respect_goaway_; | 91 bool respect_goaway_; |
| 91 | 92 |
| 92 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); | 93 DISALLOW_COPY_AND_ASSIGN(QuicClientSession); |
| 93 }; | 94 }; |
| 94 | 95 |
| 95 } // namespace net | 96 } // namespace net |
| 96 | 97 |
| 97 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ | 98 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_SESSION_H_ |
| OLD | NEW |