| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 | 215 |
| 216 // Sends all the unstarted pending requests off to the resolver. | 216 // Sends all the unstarted pending requests off to the resolver. |
| 217 void ResumeAllPendingRequests(); | 217 void ResumeAllPendingRequests(); |
| 218 | 218 |
| 219 // Returns true if |pending_requests_| contains |req|. | 219 // Returns true if |pending_requests_| contains |req|. |
| 220 bool ContainsPendingRequest(PacRequest* req); | 220 bool ContainsPendingRequest(PacRequest* req); |
| 221 | 221 |
| 222 // Removes |req| from the list of pending requests. | 222 // Removes |req| from the list of pending requests. |
| 223 void RemovePendingRequest(PacRequest* req); | 223 void RemovePendingRequest(PacRequest* req); |
| 224 | 224 |
| 225 // Called when proxy resolution has completed (either synchronously or |
| 226 // asynchronously). Handles logging the result, and cleaning out |
| 227 // bad entries from the results list. |
| 228 int DidFinishResolvingProxy(ProxyInfo* result, |
| 229 int result_code, |
| 230 LoadLog* load_log); |
| 231 |
| 225 // Returns true if the URL passed in should not go through the proxy server. | 232 // Returns true if the URL passed in should not go through the proxy server. |
| 226 // 1. If the proxy settings say to bypass local names, and |IsLocalName(url)|. | 233 // 1. If the proxy settings say to bypass local names, and |IsLocalName(url)|. |
| 227 // 2. The URL matches one of the entities in the proxy bypass list. | 234 // 2. The URL matches one of the entities in the proxy bypass list. |
| 228 bool ShouldBypassProxyForURL(const GURL& url); | 235 bool ShouldBypassProxyForURL(const GURL& url); |
| 229 | 236 |
| 230 // Returns true if |url| is to an intranet site (using non-FQDN as the | 237 // Returns true if |url| is to an intranet site (using non-FQDN as the |
| 231 // heuristic). | 238 // heuristic). |
| 232 static bool IsLocalName(const GURL& url); | 239 static bool IsLocalName(const GURL& url); |
| 233 | 240 |
| 234 // Helper to download the PAC script (wpad + custom) and apply fallback rules. | 241 // Helper to download the PAC script (wpad + custom) and apply fallback rules. |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 295 | 302 |
| 296 base::WaitableEvent event_; | 303 base::WaitableEvent event_; |
| 297 CompletionCallbackImpl<SyncProxyServiceHelper> callback_; | 304 CompletionCallbackImpl<SyncProxyServiceHelper> callback_; |
| 298 ProxyInfo proxy_info_; | 305 ProxyInfo proxy_info_; |
| 299 int result_; | 306 int result_; |
| 300 }; | 307 }; |
| 301 | 308 |
| 302 } // namespace net | 309 } // namespace net |
| 303 | 310 |
| 304 #endif // NET_PROXY_PROXY_SERVICE_H_ | 311 #endif // NET_PROXY_PROXY_SERVICE_H_ |
| OLD | NEW |