| 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 #ifndef NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ | 5 #ifndef NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ |
| 6 #define NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ | 6 #define NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 195 void set_allow_bidirectional_data(bool value) { | 195 void set_allow_bidirectional_data(bool value) { |
| 196 allow_bidirectional_data_ = value; | 196 allow_bidirectional_data_ = value; |
| 197 } | 197 } |
| 198 | 198 |
| 199 bool allow_bidirectional_data() const { return allow_bidirectional_data_; } | 199 bool allow_bidirectional_data() const { return allow_bidirectional_data_; } |
| 200 | 200 |
| 201 size_t num_requests() const { return num_requests_; } | 201 size_t num_requests() const { return num_requests_; } |
| 202 | 202 |
| 203 size_t num_responses() const { return num_responses_; } | 203 size_t num_responses() const { return num_responses_; } |
| 204 | 204 |
| 205 void set_server_address(const IPEndPoint& server_address) { |
| 206 client_->set_server_address(server_address); |
| 207 } |
| 208 |
| 205 // Explicitly set the SNI value for this client, overriding the default | 209 // Explicitly set the SNI value for this client, overriding the default |
| 206 // behavior which extracts the SNI value from the request URL. | 210 // behavior which extracts the SNI value from the request URL. |
| 207 void OverrideSni(const std::string& sni) { | 211 void OverrideSni(const std::string& sni) { |
| 208 override_sni_set_ = true; | 212 override_sni_set_ = true; |
| 209 override_sni_ = sni; | 213 override_sni_ = sni; |
| 210 } | 214 } |
| 211 | 215 |
| 212 protected: | 216 protected: |
| 213 QuicTestClient(); | 217 QuicTestClient(); |
| 214 | 218 |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 std::string override_sni_; | 291 std::string override_sni_; |
| 288 | 292 |
| 289 DISALLOW_COPY_AND_ASSIGN(QuicTestClient); | 293 DISALLOW_COPY_AND_ASSIGN(QuicTestClient); |
| 290 }; | 294 }; |
| 291 | 295 |
| 292 } // namespace test | 296 } // namespace test |
| 293 | 297 |
| 294 } // namespace net | 298 } // namespace net |
| 295 | 299 |
| 296 #endif // NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ | 300 #endif // NET_TOOLS_QUIC_TEST_TOOLS_QUIC_TEST_CLIENT_H_ |
| OLD | NEW |