Apache CXF API

org.apache.cxf.transport.http
Class HttpURLConnectionFactoryImpl

java.lang.Object
  extended by org.apache.cxf.transport.http.HttpURLConnectionFactoryImpl
All Implemented Interfaces:
HttpURLConnectionFactory

public class HttpURLConnectionFactoryImpl
extends Object
implements HttpURLConnectionFactory

This class is a URLConnectionFactory that creates URLConnections for the HTTP protocol.


Field Summary
static String HTTP_URL_PROTOCOL_ID
           
 
Constructor Summary
HttpURLConnectionFactoryImpl()
           
 
Method Summary
 HttpURLConnection createConnection(Proxy proxy, URL url)
          This call creates an URLConnection for an HTTP url.
 HttpURLConnectionInfo getConnectionInfo(HttpURLConnection connection)
          This operation returns the HttpURLConnectionInfo object that represents the HttpURLConnection.
 String getProtocol()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HTTP_URL_PROTOCOL_ID

public static final String HTTP_URL_PROTOCOL_ID
See Also:
Constant Field Values
Constructor Detail

HttpURLConnectionFactoryImpl

public HttpURLConnectionFactoryImpl()
Method Detail

createConnection

public HttpURLConnection createConnection(Proxy proxy,
                                          URL url)
                                   throws IOException
This call creates an URLConnection for an HTTP url.

Specified by:
createConnection in interface HttpURLConnectionFactory
Parameters:
proxy - The proxy. May be null if connection is not to be proxied.
url - The target URL
Returns:
An appropriate URLConnection
Throws:
IOException - if the url protocol is not "http".

getConnectionInfo

public HttpURLConnectionInfo getConnectionInfo(HttpURLConnection connection)
                                        throws IOException
This operation returns the HttpURLConnectionInfo object that represents the HttpURLConnection.

Specified by:
getConnectionInfo in interface HttpURLConnectionFactory
Returns:
The HttpURLConnection Info for the given connection.
Throws:
IOException

getProtocol

public String getProtocol()
Specified by:
getProtocol in interface HttpURLConnectionFactory
Returns:
the protocol that this connection supports (http or https)

Apache CXF API

Apache CXF