Package org.glassfish.jersey.client
Class HttpUrlConnectorProvider.DefaultConnectionFactory
java.lang.Object
org.glassfish.jersey.client.HttpUrlConnectorProvider.DefaultConnectionFactory
- All Implemented Interfaces:
HttpUrlConnectorProvider.ConnectionFactory
- Enclosing class:
HttpUrlConnectorProvider
private static class HttpUrlConnectorProvider.DefaultConnectionFactory
extends Object
implements HttpUrlConnectorProvider.ConnectionFactory
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetConnection
(URL url) Get aHttpURLConnection
for a given URL.
-
Constructor Details
-
DefaultConnectionFactory
private DefaultConnectionFactory()
-
-
Method Details
-
getConnection
Description copied from interface:HttpUrlConnectorProvider.ConnectionFactory
Get aHttpURLConnection
for a given URL.Implementation of the method MUST be thread-safe and MUST ensure that a dedicated
HttpURLConnection
instance is returned for concurrent requests.- Specified by:
getConnection
in interfaceHttpUrlConnectorProvider.ConnectionFactory
- Parameters:
url
- the endpoint URL.- Returns:
- the
HttpURLConnection
. - Throws:
IOException
- in case the connection cannot be provided.
-