| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_CONFIG_H_ | 5 #ifndef NET_PROXY_PROXY_CONFIG_H_ |
| 6 #define NET_PROXY_PROXY_CONFIG_H_ | 6 #define NET_PROXY_PROXY_CONFIG_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "googleurl/src/gurl.h" | 11 #include "googleurl/src/gurl.h" |
| 12 #include "net/base/net_api.h" | 12 #include "net/base/net_export.h" |
| 13 #include "net/proxy/proxy_bypass_rules.h" | 13 #include "net/proxy/proxy_bypass_rules.h" |
| 14 #include "net/proxy/proxy_server.h" | 14 #include "net/proxy/proxy_server.h" |
| 15 | 15 |
| 16 namespace base { | 16 namespace base { |
| 17 class Value; | 17 class Value; |
| 18 } | 18 } |
| 19 | 19 |
| 20 namespace net { | 20 namespace net { |
| 21 | 21 |
| 22 class ProxyInfo; | 22 class ProxyInfo; |
| 23 | 23 |
| 24 // ProxyConfig describes a user's proxy settings. | 24 // ProxyConfig describes a user's proxy settings. |
| 25 // | 25 // |
| 26 // There are two categories of proxy settings: | 26 // There are two categories of proxy settings: |
| 27 // (1) Automatic (indicates the methods to obtain a PAC script) | 27 // (1) Automatic (indicates the methods to obtain a PAC script) |
| 28 // (2) Manual (simple set of proxy servers per scheme, and bypass patterns) | 28 // (2) Manual (simple set of proxy servers per scheme, and bypass patterns) |
| 29 // | 29 // |
| 30 // When both automatic and manual settings are specified, the Automatic ones | 30 // When both automatic and manual settings are specified, the Automatic ones |
| 31 // take precedence over the manual ones. | 31 // take precedence over the manual ones. |
| 32 // | 32 // |
| 33 // For more details see: | 33 // For more details see: |
| 34 // http://www.chromium.org/developers/design-documents/proxy-settings-fallback | 34 // http://www.chromium.org/developers/design-documents/proxy-settings-fallback |
| 35 class NET_API ProxyConfig { | 35 class NET_EXPORT ProxyConfig { |
| 36 public: | 36 public: |
| 37 // ProxyRules describes the "manual" proxy settings. | 37 // ProxyRules describes the "manual" proxy settings. |
| 38 // TODO(eroman): Turn this into a class. | 38 // TODO(eroman): Turn this into a class. |
| 39 struct NET_API ProxyRules { | 39 struct NET_EXPORT ProxyRules { |
| 40 enum Type { | 40 enum Type { |
| 41 TYPE_NO_RULES, | 41 TYPE_NO_RULES, |
| 42 TYPE_SINGLE_PROXY, | 42 TYPE_SINGLE_PROXY, |
| 43 TYPE_PROXY_PER_SCHEME, | 43 TYPE_PROXY_PER_SCHEME, |
| 44 }; | 44 }; |
| 45 | 45 |
| 46 // Note that the default of TYPE_NO_RULES results in direct connections | 46 // Note that the default of TYPE_NO_RULES results in direct connections |
| 47 // being made when using this ProxyConfig. | 47 // being made when using this ProxyConfig. |
| 48 ProxyRules(); | 48 ProxyRules(); |
| 49 ~ProxyRules(); | 49 ~ProxyRules(); |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 206 ProxyRules proxy_rules_; | 206 ProxyRules proxy_rules_; |
| 207 | 207 |
| 208 int id_; | 208 int id_; |
| 209 }; | 209 }; |
| 210 | 210 |
| 211 } // namespace net | 211 } // namespace net |
| 212 | 212 |
| 213 | 213 |
| 214 | 214 |
| 215 #endif // NET_PROXY_PROXY_CONFIG_H_ | 215 #endif // NET_PROXY_PROXY_CONFIG_H_ |
| OLD | NEW |