com.sun.jersey.api.client
Interface AsyncUniformInterface

All Known Implementing Classes:
AsyncWebResource, AsyncWebResource.Builder

public interface AsyncUniformInterface

An asynchronous uniform interface for invoking HTTP requests.


Method Summary
 java.util.concurrent.Future<?> delete()
          Invoke the DELETE method with no request entity or response.
<T> java.util.concurrent.Future<T>
delete(java.lang.Class<T> c)
          Invoke the DELETE method with no request entity that returns a response.
<T> java.util.concurrent.Future<T>
delete(java.lang.Class<T> c, java.lang.Object requestEntity)
          Invoke the DELETE method with a request entity that returns a response.
 java.util.concurrent.Future<?> delete(java.lang.Object requestEntity)
          Invoke the DELETE method with a request entity but no response.
<T> java.util.concurrent.Future<T>
get(java.lang.Class<T> c)
          Invoke the GET method.
 java.util.concurrent.Future<ClientResponse> head()
          Invoke the HEAD method.
 java.util.concurrent.Future<?> method(java.lang.String method)
          Invoke a HTTP method with no request entity or response.
<T> java.util.concurrent.Future<T>
method(java.lang.String method, java.lang.Class<T> c)
          Invoke a HTTP method with no request entity that returns a response.
<T> java.util.concurrent.Future<T>
method(java.lang.String method, java.lang.Class<T> c, java.lang.Object requestEntity)
          Invoke a HTTP method with a request entity that returns a response.
 java.util.concurrent.Future<?> method(java.lang.String method, java.lang.Object requestEntity)
          Invoke a HTTP method with a request entity but no response.
<T> java.util.concurrent.Future<T>
options(java.lang.Class<T> c)
          Invoke the OPTIONS method.
 java.util.concurrent.Future<?> post()
          Invoke the POST method with no request entity or response.
<T> java.util.concurrent.Future<T>
post(java.lang.Class<T> c)
          Invoke the POST method with no request entity that returns a response.
<T> java.util.concurrent.Future<T>
post(java.lang.Class<T> c, java.lang.Object requestEntity)
          Invoke the POST method with a request entity that returns a response.
 java.util.concurrent.Future<?> post(java.lang.Object requestEntity)
          Invoke the POST method with a request entity but no response.
 java.util.concurrent.Future<?> put()
          Invoke the PUT method with no request entity or response.
<T> java.util.concurrent.Future<T>
put(java.lang.Class<T> c)
          Invoke the PUT method with no request entity that returns a response.
<T> java.util.concurrent.Future<T>
put(java.lang.Class<T> c, java.lang.Object requestEntity)
          Invoke the PUT method with a request entity that returns a response.
 java.util.concurrent.Future<?> put(java.lang.Object requestEntity)
          Invoke the PUT method with a request entity but no response.
 

Method Detail

head

java.util.concurrent.Future<ClientResponse> head()
Invoke the HEAD method.

Returns:
the HTTP response.

options

<T> java.util.concurrent.Future<T> options(java.lang.Class<T> c)
                                       throws UniformInterfaceException
Invoke the OPTIONS method.

Parameters:
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

get

<T> java.util.concurrent.Future<T> get(java.lang.Class<T> c)
                                   throws UniformInterfaceException
Invoke the GET method.

Parameters:
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

put

java.util.concurrent.Future<?> put()
                                   throws UniformInterfaceException
Invoke the PUT method with no request entity or response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

put

java.util.concurrent.Future<?> put(java.lang.Object requestEntity)
                                   throws UniformInterfaceException
Invoke the PUT method with a request entity but no response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Parameters:
requestEntity - the request entity.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

put

<T> java.util.concurrent.Future<T> put(java.lang.Class<T> c)
                                   throws UniformInterfaceException
Invoke the PUT method with no request entity that returns a response.

Parameters:
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

put

<T> java.util.concurrent.Future<T> put(java.lang.Class<T> c,
                                       java.lang.Object requestEntity)
                                   throws UniformInterfaceException
Invoke the PUT method with a request entity that returns a response.

Parameters:
c - the type of the returned response.
requestEntity - the request entity.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

post

java.util.concurrent.Future<?> post()
                                    throws UniformInterfaceException
Invoke the POST method with no request entity or response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

post

java.util.concurrent.Future<?> post(java.lang.Object requestEntity)
                                    throws UniformInterfaceException
Invoke the POST method with a request entity but no response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Parameters:
requestEntity - the request entity.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

post

<T> java.util.concurrent.Future<T> post(java.lang.Class<T> c)
                                    throws UniformInterfaceException
Invoke the POST method with no request entity that returns a response.

Parameters:
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

post

<T> java.util.concurrent.Future<T> post(java.lang.Class<T> c,
                                        java.lang.Object requestEntity)
                                    throws UniformInterfaceException
Invoke the POST method with a request entity that returns a response.

Parameters:
c - the type of the returned response.
requestEntity - the request entity.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

delete

java.util.concurrent.Future<?> delete()
                                      throws UniformInterfaceException
Invoke the DELETE method with no request entity or response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

delete

java.util.concurrent.Future<?> delete(java.lang.Object requestEntity)
                                      throws UniformInterfaceException
Invoke the DELETE method with a request entity but no response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Parameters:
requestEntity - the request entity.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

delete

<T> java.util.concurrent.Future<T> delete(java.lang.Class<T> c)
                                      throws UniformInterfaceException
Invoke the DELETE method with no request entity that returns a response.

Parameters:
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

delete

<T> java.util.concurrent.Future<T> delete(java.lang.Class<T> c,
                                          java.lang.Object requestEntity)
                                      throws UniformInterfaceException
Invoke the DELETE method with a request entity that returns a response.

Parameters:
c - the type of the returned response.
requestEntity - the request entity.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

method

java.util.concurrent.Future<?> method(java.lang.String method)
                                      throws UniformInterfaceException
Invoke a HTTP method with no request entity or response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Parameters:
method - the HTTP method.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

method

java.util.concurrent.Future<?> method(java.lang.String method,
                                      java.lang.Object requestEntity)
                                      throws UniformInterfaceException
Invoke a HTTP method with a request entity but no response.

If the status code is less than 300 and a representation is present then that representation is ignored.

Parameters:
method - the HTTP method.
requestEntity - the request entity.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300.

method

<T> java.util.concurrent.Future<T> method(java.lang.String method,
                                          java.lang.Class<T> c)
                                      throws UniformInterfaceException
Invoke a HTTP method with no request entity that returns a response.

Parameters:
method - the HTTP method.
c - the type of the returned response.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.

method

<T> java.util.concurrent.Future<T> method(java.lang.String method,
                                          java.lang.Class<T> c,
                                          java.lang.Object requestEntity)
                                      throws UniformInterfaceException
Invoke a HTTP method with a request entity that returns a response.

Parameters:
method - the HTTP method.
c - the type of the returned response.
requestEntity - the request entity.
Returns:
an instance of type c.
Throws:
UniformInterfaceException - if the status of the HTTP response is greater than or equal to 300 and c is not the type ClientResponse.