Package org.apache.flink.core.state
Interface InternalStateFuture<T>
-
- All Superinterfaces:
org.apache.flink.api.common.state.v2.StateFuture<T>
- All Known Implementing Classes:
CompletedStateFuture,StateFutureImpl
@Internal public interface InternalStateFuture<T> extends org.apache.flink.api.common.state.v2.StateFuture<T>The Internal definition ofStateFuture, add some method that will be used by framework.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcomplete(T result)Complete this future.voidcompleteExceptionally(String message, Throwable ex)Fail this future and pass the given exception to the runtime.Tget()Waits if necessary for the computation to complete, and then retrieves its result.booleanisDone()Returnstrueif completed in any fashion: normally, exceptionally, or via cancellation.voidthenSyncAccept(org.apache.flink.util.function.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).
-
-
-
Method Detail
-
isDone
boolean isDone()
Returnstrueif completed in any fashion: normally, exceptionally, or via cancellation.- Returns:
trueif completed
-
get
T get()
Waits if necessary for the computation to complete, and then retrieves its result.
-
complete
void complete(T result)
Complete this future.
-
completeExceptionally
void completeExceptionally(String message, Throwable ex)
Fail this future and pass the given exception to the runtime.- Parameters:
message- the description of this exceptionex- the exception
-
-