eu.emi.client.security
Class HttpHostFactory

java.lang.Object
  extended by eu.emi.client.security.HttpHostFactory

public class HttpHostFactory
extends Object

Code from Apache Commons HTTPClient "contrib"


Field Summary
protected  org.apache.commons.httpclient.protocol.Protocol httpProtocol
           
protected  org.apache.commons.httpclient.protocol.Protocol httpsProtocol
           
 
Constructor Summary
HttpHostFactory(org.apache.commons.httpclient.protocol.Protocol httpProtocol, org.apache.commons.httpclient.protocol.Protocol httpsProtocol)
           
 
Method Summary
 org.apache.commons.httpclient.HttpHost getHost(org.apache.commons.httpclient.HostConfiguration old, String scheme, String host, int port)
          Get a host for the given parameters.
protected  org.apache.commons.httpclient.protocol.Protocol getProtocol(org.apache.commons.httpclient.HostConfiguration old, String scheme, String host, int port)
          Get a Protocol for the given parameters.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

httpProtocol

protected final org.apache.commons.httpclient.protocol.Protocol httpProtocol

httpsProtocol

protected final org.apache.commons.httpclient.protocol.Protocol httpsProtocol
Constructor Detail

HttpHostFactory

public HttpHostFactory(org.apache.commons.httpclient.protocol.Protocol httpProtocol,
                       org.apache.commons.httpclient.protocol.Protocol httpsProtocol)
Method Detail

getHost

public org.apache.commons.httpclient.HttpHost getHost(org.apache.commons.httpclient.HostConfiguration old,
                                                      String scheme,
                                                      String host,
                                                      int port)
Get a host for the given parameters. This method need not be thread-safe.


getProtocol

protected org.apache.commons.httpclient.protocol.Protocol getProtocol(org.apache.commons.httpclient.HostConfiguration old,
                                                                      String scheme,
                                                                      String host,
                                                                      int port)
Get a Protocol for the given parameters. The default implementation selects a protocol based only on the scheme. Subclasses can do fancier things, such as select SSL parameters based on the host or port. This method must not return null.



Copyright © 2012 EMI. All Rights Reserved.