hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject Re: HTTP Client 4.0: proxy settings?
Date Thu, 19 Feb 2009 20:30:49 GMT
Florent Georges wrote:
> Oleg Kalnichevski wrote:
> 
>> If you want HttpClient to use proxy system properties, try out
>> the route planner implementation based on java.net.ProxySelector
> 
>> DefaultHttpClient httpclient = new DefaultHttpClient();
>> ProxySelectorRoutePlanner routePlanner = new
>> ProxySelectorRoutePlanner(
>>      httpclient.getConnectionManager().getSchemeRegistry(),
>>      ProxySelector.getDefault());
>> httpclient.setRoutePlanner(routePlanner);
> 
>   That works great.  Thanks to both of you!
> 
>   BTW, why such useful methods are not on the HttpClient interface, but rather on the
AbstractHttpClient class (not even in a second interface)?  Is there any rational for that
choice?
>

Mainly to make it simpler by hiding non-essential details, thus easier 
to implement and decorate.

Oleg

>   Thanks again, regards,
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org


Mime
View raw message