@Internal public interface InternalStateFuture<T> extends StateFuture<T>
StateFuture
, add some method that will be used by framework.Modifier and Type | Method and Description |
---|---|
void |
complete(T result)
Complete this future.
|
void |
completeExceptionally(String message,
Throwable ex)
Fail this future and pass the given exception to the runtime.
|
void |
thenSyncAccept(ThrowingConsumer<? super T,? extends Exception> action)
Accept the action in the same thread with the one of complete (or current thread if it has
been completed).
|
thenAccept, thenApply, thenCombine, thenCompose
void complete(T result)
void completeExceptionally(String message, Throwable ex)
message
- the description of this exceptionex
- the exceptionvoid thenSyncAccept(ThrowingConsumer<? super T,? extends Exception> action)
action
- the action to perform.Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.