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

Unified Diff: runtime/bin/http.dart

Issue 11066041: Add support for HTTP proxy in the HTTP client (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed review comments from ajohnsen@ Created 8 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/bin/http_impl.dart » ('j') | runtime/bin/http_impl.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/http.dart
diff --git a/runtime/bin/http.dart b/runtime/bin/http.dart
index 0b9cd30028730ca93c578764076fe4ac3b8505d4..a3f4931c8dc36a568bc6b6d79fcbfa770e163ff4 100644
--- a/runtime/bin/http.dart
+++ b/runtime/bin/http.dart
@@ -709,6 +709,29 @@ abstract class HttpClient {
HttpClientConnection postUrl(Uri url);
/**
+ * Sets the function used to resolve the proxy server to be used for
+ * opening a HTTP connection to the specified [url]. If this
+ * function is not set, direct connections will always be used.
+ *
+ * The string returned by [f] must be in the format used by browser
+ * PAC (proxy auto-config) scripts. That is either
+ *
+ * "DIRECT"
+ *
+ * for using a direct connection or
+ *
+ * "PROXY host:port"
+ *
+ * for using the proxy server [:host:] on port [:port:].
+ *
+ * A configuration can contain several configuration elements
+ * separated by semicolons, e.g.
+ *
+ * "PROXY host:port; PROXY host2:port2; DIRECT"
+ */
+ set findProxy(String f(Uri url));
+
+ /**
* Shutdown the HTTP client releasing all resources.
*/
void shutdown();
« no previous file with comments | « no previous file | runtime/bin/http_impl.dart » ('j') | runtime/bin/http_impl.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698