OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_BASE_TEST_PROXY_DELEGATE_H_ | 5 #ifndef NET_BASE_TEST_PROXY_DELEGATE_H_ |
6 #define NET_BASE_TEST_PROXY_DELEGATE_H_ | 6 #define NET_BASE_TEST_PROXY_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "net/base/host_port_pair.h" | 10 #include "net/base/host_port_pair.h" |
11 #include "net/base/proxy_delegate.h" | 11 #include "net/base/proxy_delegate.h" |
12 #include "net/proxy/proxy_server.h" | 12 #include "net/proxy/proxy_server.h" |
13 | 13 |
14 class GURL; | 14 class GURL; |
15 | 15 |
16 namespace net { | 16 namespace net { |
17 | 17 |
18 class HttpRequestHeaders; | 18 class HttpRequestHeaders; |
19 class HttpResponseHeaders; | 19 class HttpResponseHeaders; |
20 class ProxyInfo; | 20 class ProxyInfo; |
21 class ProxyService; | 21 class ProxyService; |
22 class URLRequest; | |
23 | 22 |
24 class TestProxyDelegate : public ProxyDelegate { | 23 class TestProxyDelegate : public ProxyDelegate { |
25 public: | 24 public: |
26 TestProxyDelegate(); | 25 TestProxyDelegate(); |
27 ~TestProxyDelegate() override; | 26 ~TestProxyDelegate() override; |
28 | 27 |
29 bool on_before_tunnel_request_called() const { | 28 bool on_before_tunnel_request_called() const { |
30 return on_before_tunnel_request_called_; | 29 return on_before_tunnel_request_called_; |
31 } | 30 } |
32 | 31 |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 std::string on_tunnel_headers_received_status_line_; | 96 std::string on_tunnel_headers_received_status_line_; |
98 ProxyServer alternative_proxy_server_; | 97 ProxyServer alternative_proxy_server_; |
99 | 98 |
100 // Number of times GetAlternativeProxy() method has been called. | 99 // Number of times GetAlternativeProxy() method has been called. |
101 mutable int get_alternative_proxy_invocations_; | 100 mutable int get_alternative_proxy_invocations_; |
102 }; | 101 }; |
103 | 102 |
104 } // namespace net | 103 } // namespace net |
105 | 104 |
106 #endif // NET_BASE_TEST_PROXY_DELEGATE_H_ | 105 #endif // NET_BASE_TEST_PROXY_DELEGATE_H_ |
OLD | NEW |