Top Description Fields Constructors Methods
org.apache.hc.client5.http.impl.routing

public Class SystemDefaultRoutePlanner

extends DefaultRoutePlanner
Class Inheritance
Annotations
@Contract
threading:STATELESS
Imports
java.net.InetSocketAddress, .Proxy, .ProxySelector, .URI, .URISyntaxException, java.util.List, org.apache.hc.client5.http.SchemePortResolver, org.apache.hc.core5.annotation.Contract, .ThreadingBehavior, org.apache.hc.core5.http.HttpException, .HttpHost, org.apache.hc.core5.http.protocol.HttpContext

org.apache.hc.client5.http.routing.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

Modifier and TypeField and Description
private final ProxySelector

Constructor Summary

AccessConstructor and Description
public
SystemDefaultRoutePlanner(final SchemePortResolver schemePortResolver, final ProxySelector
the proxy selector, or null for the system default
proxySelector
)

public
SystemDefaultRoutePlanner(final ProxySelector
the proxy selector, or null for the system default
proxySelector
)

Method Summary

Modifier and TypeMethod and Description
private Proxy
chooseProxy(final List<Proxy> proxies)

protected HttpHost
determineProxy(final HttpHost target, final HttpContext context)

Overrides org.apache.hc.client5.http.impl.routing.DefaultRoutePlanner.determineProxy.

This implementation returns null.
Inherited from org.apache.hc.client5.http.impl.routing.DefaultRoutePlanner:
determineLocalAddressdetermineRoute

Field Detail

proxySelectorback to summary
private final ProxySelector proxySelector

Constructor Detail

SystemDefaultRoutePlannerback to summary
public SystemDefaultRoutePlanner(final SchemePortResolver schemePortResolver, final ProxySelector proxySelector)
Parameters
proxySelector:ProxySelector

the proxy selector, or null for the system default

SystemDefaultRoutePlannerback to summary
public SystemDefaultRoutePlanner(final ProxySelector proxySelector)
Parameters
proxySelector:ProxySelector

the proxy selector, or null for the system default

Method Detail

chooseProxyback to summary
private Proxy chooseProxy(final List<Proxy> proxies)
determineProxyback to summary
protected HttpHost determineProxy(final HttpHost target, final HttpContext context) throws HttpException

Overrides org.apache.hc.client5.http.impl.routing.DefaultRoutePlanner.determineProxy.

Doc from org.apache.hc.client5.http.impl.routing.DefaultRoutePlanner.determineProxy.

This implementation returns null.

Annotations
@Override
Exceptions
HttpException:
may be thrown if overridden