Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1792)

Side by Side Diff: net/proxy/proxy_resolver_js_bindings.h

Issue 2822043: Add the capability to run multiple proxy PAC scripts in parallel.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Re-upload after revert Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/proxy/proxy_resolver.h ('k') | net/proxy/proxy_resolver_js_bindings.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_RESOLVER_JS_BINDINGS_H_ 5 #ifndef NET_PROXY_PROXY_RESOLVER_JS_BINDINGS_H_
6 #define NET_PROXY_PROXY_RESOLVER_JS_BINDINGS_H_ 6 #define NET_PROXY_PROXY_RESOLVER_JS_BINDINGS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/string16.h" 10 #include "base/string16.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 // 47 //
48 // This is a Microsoft extension to PAC for IPv6, see: 48 // This is a Microsoft extension to PAC for IPv6, see:
49 // http://blogs.msdn.com/wndp/articles/IPV6_PAC_Extensions_v0_9.aspx 49 // http://blogs.msdn.com/wndp/articles/IPV6_PAC_Extensions_v0_9.aspx
50 virtual bool DnsResolveEx(const std::string& host, 50 virtual bool DnsResolveEx(const std::string& host,
51 std::string* ip_address_list) = 0; 51 std::string* ip_address_list) = 0;
52 52
53 // Handler for when an error is encountered. |line_number| may be -1 53 // Handler for when an error is encountered. |line_number| may be -1
54 // if a line number is not applicable to this error. 54 // if a line number is not applicable to this error.
55 virtual void OnError(int line_number, const string16& error) = 0; 55 virtual void OnError(int line_number, const string16& error) = 0;
56 56
57 // Called before the thread running the proxy resolver is stopped.
58 virtual void Shutdown() = 0;
59
57 // Creates a default javascript bindings implementation that will: 60 // Creates a default javascript bindings implementation that will:
58 // - Send script error messages to LOG(INFO) 61 // - Send script error messages to LOG(INFO)
59 // - Send script alert()s to LOG(INFO) 62 // - Send script alert()s to LOG(INFO)
60 // - Use the provided host resolver to service dnsResolve(). 63 // - Use the provided host resolver to service dnsResolve().
61 // 64 //
62 // Note that |host_resolver| will be used in sync mode mode. 65 // Note that |host_resolver| will be used in sync mode mode.
63 static ProxyResolverJSBindings* CreateDefault(HostResolver* host_resolver); 66 static ProxyResolverJSBindings* CreateDefault(HostResolver* host_resolver);
64 67
65 // Sets details about the currently executing FindProxyForURL() request. 68 // Sets details about the currently executing FindProxyForURL() request.
66 void set_current_request_context( 69 void set_current_request_context(
67 ProxyResolverRequestContext* current_request_context) { 70 ProxyResolverRequestContext* current_request_context) {
68 current_request_context_ = current_request_context; 71 current_request_context_ = current_request_context;
69 } 72 }
70 73
71 // Retrieves details about the currently executing FindProxyForURL() request. 74 // Retrieves details about the currently executing FindProxyForURL() request.
72 ProxyResolverRequestContext* current_request_context() { 75 ProxyResolverRequestContext* current_request_context() {
73 return current_request_context_; 76 return current_request_context_;
74 } 77 }
75 78
76 private: 79 private:
77 ProxyResolverRequestContext* current_request_context_; 80 ProxyResolverRequestContext* current_request_context_;
78 }; 81 };
79 82
80 } // namespace net 83 } // namespace net
81 84
82 #endif // NET_PROXY_PROXY_RESOLVER_JS_BINDINGS_H_ 85 #endif // NET_PROXY_PROXY_RESOLVER_JS_BINDINGS_H_
OLDNEW
« no previous file with comments | « net/proxy/proxy_resolver.h ('k') | net/proxy/proxy_resolver_js_bindings.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698