|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface BaseResponsePromise<V>
Adds rich response-code callback registration to the base Promise interface.
| Method Summary | |
|---|---|
BaseResponsePromise<V> |
badRequest(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'bad request' (400) HTTP responses. |
BaseResponsePromise<V> |
clientError(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'client error' (4xx) HTTP responses. |
BaseResponsePromise<V> |
conflict(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'conflict' (409) HTTP responses. |
BaseResponsePromise<V> |
created(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'created' (201) HTTP responses. |
BaseResponsePromise<V> |
done(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to all completed (1xx, 2xx, 3xx, 4xx, and 5xx) HTTP responses. |
BaseResponsePromise<V> |
error(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to all error (4xx and 5xx) HTTP responses. |
BaseResponsePromise<V> |
fail(com.atlassian.util.concurrent.Effect<java.lang.Throwable> callback)
Register a callback to respond to exceptions thrown while executing the HTTP request. |
BaseResponsePromise<V> |
forbidden(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'forbidden' (403) HTTP responses. |
BaseResponsePromise<V> |
informational(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'informational' (1xx) HTTP responses. |
BaseResponsePromise<V> |
internalServerError(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'internal server error' (500) HTTP responses. |
BaseResponsePromise<V> |
noContent(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'no content' (204) HTTP responses. |
BaseResponsePromise<V> |
notFound(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'not found' (404) HTTP responses. |
BaseResponsePromise<V> |
notModified(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'not modified' (304) HTTP responses. |
BaseResponsePromise<V> |
notSuccessful(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to all non-'successful' (1xx, 3xx, 4xx, 5xx) HTTP responses. |
BaseResponsePromise<V> |
ok(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'ok' (200) HTTP responses. |
BaseResponsePromise<V> |
on(int statusCode,
com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to HTTP responses with a specific status code. |
BaseResponsePromise<V> |
others(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to all other HTTP responses (i.e. |
BaseResponsePromise<V> |
otherwise(com.atlassian.util.concurrent.Effect<java.lang.Throwable> callback)
Registers the specified callback as a handler for both of the following events: Any value passed to fail()
Any value passed to others(), converted into an exception
|
BaseResponsePromise<V> |
redirection(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'redirection' (3xx) HTTP responses. |
BaseResponsePromise<V> |
seeOther(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'see other' (303) HTTP responses. |
BaseResponsePromise<V> |
serverError(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'server error' (5xx) HTTP responses. |
BaseResponsePromise<V> |
serviceUnavailable(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'service unavailable' (503) HTTP responses. |
BaseResponsePromise<V> |
successful(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'successful' (2xx) HTTP responses. |
BaseResponsePromise<V> |
then(com.google.common.util.concurrent.FutureCallback<V> callback)
Register a future callback to respond to all completed HTTP responses and exceptions thrown while executing the HTTP request. |
BaseResponsePromise<V> |
unauthorized(com.atlassian.util.concurrent.Effect<V> callback)
Register a callback to respond to 'unauthorized' (401) HTTP responses. |
| Methods inherited from interface com.atlassian.util.concurrent.Promise |
|---|
claim, flatMap, map |
| Methods inherited from interface com.google.common.util.concurrent.ListenableFuture |
|---|
addListener |
| Methods inherited from interface java.util.concurrent.Future |
|---|
cancel, get, get, isCancelled, isDone |
| Method Detail |
|---|
BaseResponsePromise<V> on(int statusCode,
com.atlassian.util.concurrent.Effect<V> callback)
statusCode - The code to select oncallback - The callback
BaseResponsePromise<V> informational(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> successful(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> ok(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> created(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> noContent(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> redirection(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> seeOther(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> notModified(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> clientError(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> badRequest(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> unauthorized(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> forbidden(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> notFound(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> conflict(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> serverError(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> internalServerError(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> serviceUnavailable(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> error(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> notSuccessful(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> others(com.atlassian.util.concurrent.Effect<V> callback)
callback - The callback
BaseResponsePromise<V> otherwise(com.atlassian.util.concurrent.Effect<java.lang.Throwable> callback)
fail()
callback - The callback
BaseResponsePromise<V> done(com.atlassian.util.concurrent.Effect<V> callback)
done in interface com.atlassian.util.concurrent.Promise<V>callback - The callback
BaseResponsePromise<V> fail(com.atlassian.util.concurrent.Effect<java.lang.Throwable> callback)
fail in interface com.atlassian.util.concurrent.Promise<V>callback - The callback
BaseResponsePromise<V> then(com.google.common.util.concurrent.FutureCallback<V> callback)
then in interface com.atlassian.util.concurrent.Promise<V>callback - The callback
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||