Class ClientInvocation
java.lang.Object
org.jboss.resteasy.client.jaxrs.internal.ClientInvocation
- All Implemented Interfaces:
javax.ws.rs.client.Invocation
- Version:
- $Revision: 1 $
-
Nested Class Summary
Nested classes/interfaces inherited from interface javax.ws.rs.client.Invocation
javax.ws.rs.client.Invocation.Builder
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected boolean
protected ResteasyClient
protected ClientConfiguration
protected DelegatingOutputStream
protected Object
protected Annotation[]
protected Class
<?> protected Type
protected OutputStream
protected ClientRequestHeaders
protected String
protected URI
-
Constructor Summary
ConstructorsConstructorDescriptionClientInvocation
(ResteasyClient client, URI uri, ClientRequestHeaders headers, ClientConfiguration parent) -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> T
extractResult
(javax.ws.rs.core.GenericType<T> responseType, javax.ws.rs.core.Response response, Annotation[] annotations) Extracts result from response throwing an appropriate exception if not a successful response.javax.ws.rs.core.Configuration
Class
<?> javax.ws.rs.client.ClientRequestFilter[]
javax.ws.rs.client.ClientResponseFilter[]
getUri()
javax.ws.rs.ext.WriterInterceptor[]
static <T> T
handleErrorStatus
(javax.ws.rs.core.Response response) Throw an exception.javax.ws.rs.core.Response
invoke()
<T> T
<T> T
invoke
(javax.ws.rs.core.GenericType<T> responseType) boolean
javax.ws.rs.client.Invocation
void
setChunked
(boolean chunked) void
setDelegatingOutputStream
(DelegatingOutputStream delegatingOutputStream) void
setEntity
(javax.ws.rs.client.Entity<?> entity) void
setEntityAnnotations
(Annotation[] entityAnnotations) void
setEntityObject
(Object ent) void
setEntityStream
(OutputStream entityStream) void
setHeaders
(ClientRequestHeaders headers) void
void
Future
<javax.ws.rs.core.Response> submit()
<T> Future
<T> <T> Future
<T> submit
(javax.ws.rs.client.InvocationCallback<T> callback) <T> Future
<T> submit
(javax.ws.rs.core.GenericType<T> responseType) void
writeRequestBody
(OutputStream outputStream)
-
Field Details
-
client
-
headers
-
method
-
entity
-
entityGenericType
-
entityClass
-
entityAnnotations
-
configuration
-
uri
-
chunked
protected boolean chunked -
delegatingOutputStream
-
entityStream
-
-
Constructor Details
-
ClientInvocation
public ClientInvocation(ResteasyClient client, URI uri, ClientRequestHeaders headers, ClientConfiguration parent)
-
-
Method Details
-
extractResult
public static <T> T extractResult(javax.ws.rs.core.GenericType<T> responseType, javax.ws.rs.core.Response response, Annotation[] annotations) Extracts result from response throwing an appropriate exception if not a successful response.- Type Parameters:
T
-- Parameters:
responseType
-response
-annotations
-- Returns:
-
handleErrorStatus
public static <T> T handleErrorStatus(javax.ws.rs.core.Response response) Throw an exception. Expecting a status of 400 or greater.- Type Parameters:
T
-- Parameters:
response
-- Returns:
-
getClientConfiguration
-
getClient
-
getDelegatingOutputStream
-
setDelegatingOutputStream
-
getEntityStream
-
setEntityStream
-
getUri
-
setUri
-
getEntityAnnotations
-
setEntityAnnotations
-
getMethod
-
setMethod
-
setHeaders
-
getMutableProperties
-
getEntity
-
getEntityGenericType
-
getEntityClass
-
getHeaders
-
setEntity
public void setEntity(javax.ws.rs.client.Entity<?> entity) -
setEntityObject
-
writeRequestBody
- Throws:
IOException
-
getWriterInterceptors
public javax.ws.rs.ext.WriterInterceptor[] getWriterInterceptors() -
getRequestFilters
public javax.ws.rs.client.ClientRequestFilter[] getRequestFilters() -
getResponseFilters
public javax.ws.rs.client.ClientResponseFilter[] getResponseFilters() -
getConfiguration
public javax.ws.rs.core.Configuration getConfiguration() -
isChunked
public boolean isChunked() -
setChunked
public void setChunked(boolean chunked) -
invoke
public javax.ws.rs.core.Response invoke()- Specified by:
invoke
in interfacejavax.ws.rs.client.Invocation
-
invoke
- Specified by:
invoke
in interfacejavax.ws.rs.client.Invocation
-
invoke
public <T> T invoke(javax.ws.rs.core.GenericType<T> responseType) - Specified by:
invoke
in interfacejavax.ws.rs.client.Invocation
-
submit
- Specified by:
submit
in interfacejavax.ws.rs.client.Invocation
-
submit
- Specified by:
submit
in interfacejavax.ws.rs.client.Invocation
-
submit
- Specified by:
submit
in interfacejavax.ws.rs.client.Invocation
-
submit
- Specified by:
submit
in interfacejavax.ws.rs.client.Invocation
-
property
- Specified by:
property
in interfacejavax.ws.rs.client.Invocation
-