P - polling typeR - result typepublic interface PollHandler<P,R>
FutureResult| Modifier and Type | Method and Description |
|---|---|
Class<P> |
getPollClass()
Get class of the polling object.
|
String |
getPollingUri()
Get URI used for polling.
|
R |
getResult()
Return result after polling.
|
Class<R> |
getResultClass()
Get class of result after polling.
|
void |
handlePollException(GoodDataRestException e)
Handle exception while polling.
|
void |
handlePollResult(P pollResult)
Handle result of single polling request.
|
boolean |
isDone()
Returns true when the polling is done, false otherwise.
|
boolean |
isFinished(org.springframework.http.client.ClientHttpResponse response)
Check single polling response if whole polling process should finish.
|
String getPollingUri()
boolean isDone()
R getResult()
boolean isFinished(org.springframework.http.client.ClientHttpResponse response)
throws IOException
response - client side HTTP responseIOException - when there's a problem extracting data from responsevoid handlePollResult(P pollResult)
pollResult - result of polling requestvoid handlePollException(GoodDataRestException e)
GoodDataException
(or ancestor) with the given argument as cause.e - the exceptionCopyright © 2017. All Rights Reserved.