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 #include "net/proxy/proxy_config.h" | 5 #include "net/proxy/proxy_config.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/string_tokenizer.h" | 8 #include "base/string_tokenizer.h" |
9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 if (scheme == "http") | 152 if (scheme == "http") |
153 return &proxy_for_http; | 153 return &proxy_for_http; |
154 if (scheme == "https") | 154 if (scheme == "https") |
155 return &proxy_for_https; | 155 return &proxy_for_https; |
156 if (scheme == "ftp") | 156 if (scheme == "ftp") |
157 return &proxy_for_ftp; | 157 return &proxy_for_ftp; |
158 return NULL; // No mapping for this scheme. | 158 return NULL; // No mapping for this scheme. |
159 } | 159 } |
160 | 160 |
161 ProxyConfig::ProxyConfig() | 161 ProxyConfig::ProxyConfig() |
162 : auto_detect_(false), pac_mandatory_(false), id_(INVALID_ID) { | 162 : auto_detect_(false), pac_mandatory_(false), id_(kInvalidConfigID) { |
163 } | 163 } |
164 | 164 |
165 ProxyConfig::ProxyConfig(const ProxyConfig& config) | 165 ProxyConfig::ProxyConfig(const ProxyConfig& config) |
166 : auto_detect_(config.auto_detect_), | 166 : auto_detect_(config.auto_detect_), |
167 pac_url_(config.pac_url_), | 167 pac_url_(config.pac_url_), |
168 pac_mandatory_(config.pac_mandatory_), | 168 pac_mandatory_(config.pac_mandatory_), |
169 proxy_rules_(config.proxy_rules_), | 169 proxy_rules_(config.proxy_rules_), |
170 id_(config.id_) { | 170 id_(config.id_) { |
171 } | 171 } |
172 | 172 |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 } | 246 } |
247 | 247 |
248 dict->Set("bypass_list", list); | 248 dict->Set("bypass_list", list); |
249 } | 249 } |
250 } | 250 } |
251 | 251 |
252 return dict; | 252 return dict; |
253 } | 253 } |
254 | 254 |
255 } // namespace net | 255 } // namespace net |
OLD | NEW |