Package org.apache.http.impl.conn
Class SystemDefaultRoutePlanner
java.lang.Object
org.apache.http.impl.conn.DefaultRoutePlanner
org.apache.http.impl.conn.SystemDefaultRoutePlanner
- All Implemented Interfaces:
HttpRoutePlanner
@Contract(threading=IMMUTABLE_CONDITIONAL)
public class SystemDefaultRoutePlanner
extends DefaultRoutePlanner
HttpRoutePlanner implementation
based on ProxySelector. By default, this class will pick up
the proxy settings of the JVM, either from system properties
or from the browser running the application.- Since:
- 4.3
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionSystemDefaultRoutePlanner(ProxySelector proxySelector) SystemDefaultRoutePlanner(SchemePortResolver schemePortResolver, ProxySelector proxySelector) -
Method Summary
Modifier and TypeMethodDescriptionprivate ProxychooseProxy(List<Proxy> proxies) protected org.apache.http.HttpHostdetermineProxy(org.apache.http.HttpHost target, org.apache.http.HttpRequest request, org.apache.http.protocol.HttpContext context) This implementation returns null.private StringgetHost(InetSocketAddress isa) Methods inherited from class org.apache.http.impl.conn.DefaultRoutePlanner
determineRoute
-
Field Details
-
proxySelector
-
-
Constructor Details
-
SystemDefaultRoutePlanner
public SystemDefaultRoutePlanner(SchemePortResolver schemePortResolver, ProxySelector proxySelector) - Parameters:
proxySelector- the proxy selector, ornullfor the system default
-
SystemDefaultRoutePlanner
- Parameters:
proxySelector- the proxy selector, ornullfor the system default
-
-
Method Details
-
determineProxy
protected org.apache.http.HttpHost determineProxy(org.apache.http.HttpHost target, org.apache.http.HttpRequest request, org.apache.http.protocol.HttpContext context) throws org.apache.http.HttpException Description copied from class:DefaultRoutePlannerThis implementation returns null.- Overrides:
determineProxyin classDefaultRoutePlanner- Throws:
org.apache.http.HttpException- may be thrown if overridden
-
getHost
-
chooseProxy
-