Class URLConnectionEngine
java.lang.Object
org.jboss.resteasy.client.jaxrs.engines.URLConnectionEngine
-
Field Summary
Modifier and TypeFieldDescriptionprotected Integer
protected boolean
protected HostnameVerifier
protected String
protected Integer
protected String
protected Integer
protected SSLContext
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
protected void
commitHeaders
(ClientInvocation request, HttpURLConnection connection) Add headers to HttpURLConnection from ClientInvocation.protected HttpURLConnection
createConnection
(ClientInvocation request) Create HttpUrlConnection from ClientInvorcation and set request method.protected void
executeRequest
(ClientInvocation request, HttpURLConnection connection) Execute request using HttpURLConnection with body from invocation if needed.getHeaders
(HttpURLConnection connection) Create map with response headers.{inheritDoc}{inheritDoc}jakarta.ws.rs.core.Response
invoke
(jakarta.ws.rs.client.Invocation inv) boolean
void
setConnectTimeout
(Integer connectTimeout) void
setFollowRedirects
(boolean followRedirects) void
setHostnameVerifier
(HostnameVerifier hostnameVerifier) void
setProxyHost
(String proxyHost) void
setProxyPort
(Integer proxyPort) void
setProxyScheme
(String proxyScheme) void
setReadTimeout
(Integer readTimeout) void
setSslContext
(SSLContext sslContext)
-
Field Details
-
sslContext
-
hostnameVerifier
-
readTimeout
-
connectTimeout
-
proxyHost
-
proxyPort
-
proxyScheme
-
followRedirects
protected boolean followRedirects
-
-
Constructor Details
-
URLConnectionEngine
public URLConnectionEngine()
-
-
Method Details
-
invoke
public jakarta.ws.rs.core.Response invoke(jakarta.ws.rs.client.Invocation inv) - Specified by:
invoke
in interfaceClientHttpEngine
-
getHeaders
Create map with response headers.- Parameters:
connection
- - HttpURLConnection- Returns:
- map key - list of values
-
close
public void close()- Specified by:
close
in interfaceClientHttpEngine
-
createConnection
Create HttpUrlConnection from ClientInvorcation and set request method.- Parameters:
request
- ClientInvocation- Returns:
- HttpURLConnection with method & url already set
- Throws:
IOException
- if url or io exceptions
-
executeRequest
Execute request using HttpURLConnection with body from invocation if needed.- Parameters:
request
- ClientInvocationconnection
- HttpURLConnection
-
commitHeaders
Add headers to HttpURLConnection from ClientInvocation. Should be executed before writing body.- Parameters:
request
- ClientInvocationconnection
- HttpURLConnection
-
getSslContext
{inheritDoc}- Specified by:
getSslContext
in interfaceClientHttpEngine
- Returns:
SSLContext
-
getHostnameVerifier
{inheritDoc}- Specified by:
getHostnameVerifier
in interfaceClientHttpEngine
- Returns:
HostnameVerifier
-
setSslContext
-
setHostnameVerifier
-
setConnectTimeout
-
setReadTimeout
-
setProxyHost
-
setProxyPort
-
setProxyScheme
-
setFollowRedirects
public void setFollowRedirects(boolean followRedirects) - Specified by:
setFollowRedirects
in interfaceClientHttpEngine
-
isFollowRedirects
public boolean isFollowRedirects()- Specified by:
isFollowRedirects
in interfaceClientHttpEngine
-