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_PROXY_PROXY_SERVICE_H_ | 5 #ifndef NET_PROXY_PROXY_SERVICE_H_ |
6 #define NET_PROXY_PROXY_SERVICE_H_ | 6 #define NET_PROXY_PROXY_SERVICE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 // Clears the list of bad proxy servers that has been cached. | 210 // Clears the list of bad proxy servers that has been cached. |
211 void ClearBadProxiesCache() { | 211 void ClearBadProxiesCache() { |
212 proxy_retry_info_.clear(); | 212 proxy_retry_info_.clear(); |
213 } | 213 } |
214 | 214 |
215 // Forces refetching the proxy configuration, and applying it. | 215 // Forces refetching the proxy configuration, and applying it. |
216 // This re-does everything from fetching the system configuration, | 216 // This re-does everything from fetching the system configuration, |
217 // to downloading and testing the PAC files. | 217 // to downloading and testing the PAC files. |
218 void ForceReloadProxyConfig(); | 218 void ForceReloadProxyConfig(); |
219 | 219 |
| 220 // Sets URLs for data reduction proxy. |
| 221 void SetDataReductionProxyOrigins( |
| 222 const std::string& data_reduction_default_origin, |
| 223 const std::string& data_reduction_default_fallback_origin); |
| 224 |
220 // Same as CreateProxyServiceUsingV8ProxyResolver, except it uses system | 225 // Same as CreateProxyServiceUsingV8ProxyResolver, except it uses system |
221 // libraries for evaluating the PAC script if available, otherwise skips | 226 // libraries for evaluating the PAC script if available, otherwise skips |
222 // proxy autoconfig. | 227 // proxy autoconfig. |
223 static ProxyService* CreateUsingSystemProxyResolver( | 228 static ProxyService* CreateUsingSystemProxyResolver( |
224 ProxyConfigService* proxy_config_service, | 229 ProxyConfigService* proxy_config_service, |
225 size_t num_pac_threads, | 230 size_t num_pac_threads, |
226 NetLog* net_log); | 231 NetLog* net_log); |
227 | 232 |
228 // Creates a ProxyService without support for proxy autoconfig. | 233 // Creates a ProxyService without support for proxy autoconfig. |
229 static ProxyService* CreateWithoutProxyResolver( | 234 static ProxyService* CreateWithoutProxyResolver( |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
477 // The earliest time at which we should run any proxy auto-config. (Used to | 482 // The earliest time at which we should run any proxy auto-config. (Used to |
478 // stall re-configuration following an IP address change). | 483 // stall re-configuration following an IP address change). |
479 base::TimeTicks stall_proxy_autoconfig_until_; | 484 base::TimeTicks stall_proxy_autoconfig_until_; |
480 | 485 |
481 // The amount of time to stall requests following IP address changes. | 486 // The amount of time to stall requests following IP address changes. |
482 base::TimeDelta stall_proxy_auto_config_delay_; | 487 base::TimeDelta stall_proxy_auto_config_delay_; |
483 | 488 |
484 // Whether child ProxyScriptDeciders should use QuickCheck | 489 // Whether child ProxyScriptDeciders should use QuickCheck |
485 bool quick_check_enabled_; | 490 bool quick_check_enabled_; |
486 | 491 |
| 492 // HostPortPair for data reduction proxy origin and fallback origin. |
| 493 net::HostPortPair data_reduction_default_origin_; |
| 494 net::HostPortPair data_reduction_default_fallback_origin_; |
| 495 |
487 DISALLOW_COPY_AND_ASSIGN(ProxyService); | 496 DISALLOW_COPY_AND_ASSIGN(ProxyService); |
488 }; | 497 }; |
489 | 498 |
490 } // namespace net | 499 } // namespace net |
491 | 500 |
492 #endif // NET_PROXY_PROXY_SERVICE_H_ | 501 #endif // NET_PROXY_PROXY_SERVICE_H_ |
OLD | NEW |