private class HttpReceiver.Decoder extends IteratingNestedCallback
IteratingCallback.ActionCallback.Completable, Callback.Completing, Callback.NestedInvocable.InvocationType| Modifier and Type | Field and Description |
|---|---|
private java.nio.ByteBuffer |
buffer |
private java.nio.ByteBuffer |
decoded |
private ContentDecoder |
decoder |
private ResponseNotifier |
notifier |
private HttpResponse |
response |
__nonBlocking| Constructor and Description |
|---|
Decoder(ResponseNotifier notifier,
HttpResponse response,
ContentDecoder decoder,
java.nio.ByteBuffer buffer,
Callback callback) |
| Modifier and Type | Method and Description |
|---|---|
protected IteratingCallback.Action |
process()
Method called by
IteratingCallback.iterate() to process the sub task. |
void |
succeeded()
Invoked when the sub task succeeds.
|
getInvocationType, onCompleteFailure, onCompleteSuccess, toStringclose, failed, isClosed, isFailed, isSucceeded, iterate, resetclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetInvocationType, invokeNonBlocking, isNonBlockingInvocationprivate final ResponseNotifier notifier
private final HttpResponse response
private final ContentDecoder decoder
private final java.nio.ByteBuffer buffer
private java.nio.ByteBuffer decoded
public Decoder(ResponseNotifier notifier, HttpResponse response, ContentDecoder decoder, java.nio.ByteBuffer buffer, Callback callback)
protected IteratingCallback.Action process() throws java.lang.Throwable
IteratingCallbackIteratingCallback.iterate() to process the sub task.
Implementations must start the asynchronous execution of the sub task (if any) and return an appropriate action:
IteratingCallback.Action.IDLE when no sub tasks are available for execution
but the overall job is not completed yetIteratingCallback.Action.SCHEDULED when the sub task asynchronous execution
has been startedIteratingCallback.Action.SUCCEEDED when the overall job is completedprocess in class IteratingCallbackjava.lang.Throwable - if the sub task processing throwspublic void succeeded()
IteratingCallbacksuper.succeeded().succeeded in interface Callbacksucceeded in class IteratingCallbackCallback.failed(Throwable)