public class ExecutorBoundPromise<T> extends AbstractPromiseDecorator<T,Promise<T>>
delegate| Constructor and Description |
|---|
ExecutorBoundPromise(Promise<T> delegate,
Executor defaultExecutor) |
| Modifier and Type | Method and Description |
|---|---|
Promise<Void> |
acceptEitherAsync(CompletionStage<? extends T> other,
Consumer<? super T> action) |
<U> Promise<U> |
applyToEitherAsync(CompletionStage<? extends T> other,
Function<? super T,U> fn) |
Promise<T> |
defaultAsyncOn(Executor executor) |
DependentPromise<T> |
dependent()
Converts this
Promise to a DependentPromise
The returned DependentPromise does not implicitly enlist any CompletionStage
for cancellation (neither self, nor passed as arguments to combining methods);
only enlisting via explicit parameter is supported |
DependentPromise<T> |
dependent(Set<PromiseOrigin> defaultEnlistOptions)
Converts this
Promise to a DependentPromise
The returned DependentPromise does implicitly enlist CompletionStage
for cancellation (either self, and/or passed as arguments to combining methods)
according to defaultEnlistOptions parameter |
Promise<T> |
exceptionallyAsync(Function<Throwable,? extends T> fn) |
Promise<T> |
exceptionallyComposeAsync(Function<Throwable,? extends CompletionStage<T>> fn) |
<U> Promise<U> |
handleAsync(BiFunction<? super T,Throwable,? extends U> fn) |
Promise<Void> |
runAfterBothAsync(CompletionStage<?> other,
Runnable action) |
Promise<Void> |
runAfterEitherAsync(CompletionStage<?> other,
Runnable action) |
Promise<Void> |
thenAcceptAsync(Consumer<? super T> action) |
<U> Promise<Void> |
thenAcceptBothAsync(CompletionStage<? extends U> other,
BiConsumer<? super T,? super U> action) |
<U> Promise<U> |
thenApplyAsync(Function<? super T,? extends U> fn) |
<U,V> Promise<V> |
thenCombineAsync(CompletionStage<? extends U> other,
BiFunction<? super T,? super U,? extends V> fn) |
<U> Promise<U> |
thenComposeAsync(Function<? super T,? extends CompletionStage<U>> fn) |
Promise<T> |
thenFilterAsync(Predicate<? super T> predicate) |
Promise<T> |
thenFilterAsync(Predicate<? super T> predicate,
Function<? super T,Throwable> errorSupplier) |
Promise<Void> |
thenRunAsync(Runnable action) |
Promise<T> |
whenCompleteAsync(BiConsumer<? super T,? super Throwable> action) |
protected <U> Promise<U> |
wrapNew(CompletionStage<U> original) |
delay, delay, delay, delay, exceptionallyAsync, exceptionallyCompose, exceptionallyComposeAsync, getNow, getNow, isCompletedExceptionally, join, onCancel, onTimeout, onTimeout, onTimeout, onTimeout, onTimeout, onTimeout, onTimeout, onTimeout, orTimeout, orTimeout, orTimeout, orTimeout, raw, thenFilter, thenFilter, thenFilterAsync, thenFilterAsync, unwrapcancel, get, get, isCancelled, isDoneacceptEither, acceptEitherAsync, applyToEither, applyToEitherAsync, exceptionally, handle, handleAsync, runAfterBoth, runAfterBothAsync, runAfterEither, runAfterEitherAsync, thenAccept, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenApply, thenApplyAsync, thenCombine, thenCombineAsync, thenCompose, thenComposeAsync, thenRun, thenRunAsync, whenComplete, whenCompleteAsync, wrap, αtoCompletableFuture, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitacceptEither, acceptEitherAsync, applyToEither, applyToEitherAsync, as, exceptionally, handle, handleAsync, runAfterBoth, runAfterBothAsync, runAfterEither, runAfterEitherAsync, thenAccept, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenApply, thenApplyAsync, thenCombine, thenCombineAsync, thenCompose, thenComposeAsync, thenRun, thenRunAsync, whenComplete, whenCompleteAsynctoCompletableFutureprotected <U> Promise<U> wrapNew(CompletionStage<U> original)
wrapNew in class AbstractPromiseLikeDecorator<T,Promise<T>>public DependentPromise<T> dependent()
PromisePromise to a DependentPromise
The returned DependentPromise does not implicitly enlist any CompletionStage
for cancellation (neither self, nor passed as arguments to combining methods);
only enlisting via explicit parameter is supportedpublic DependentPromise<T> dependent(Set<PromiseOrigin> defaultEnlistOptions)
PromisePromise to a DependentPromise
The returned DependentPromise does implicitly enlist CompletionStage
for cancellation (either self, and/or passed as arguments to combining methods)
according to defaultEnlistOptions parameterdependent in interface Promise<T>dependent in class AbstractPromiseDecorator<T,Promise<T>>defaultEnlistOptions - defines what CompletionStage should be enlisted implicitly for cancellationpublic Promise<T> defaultAsyncOn(Executor executor)
defaultAsyncOn in interface Promise<T>defaultAsyncOn in class AbstractPromiseDecorator<T,Promise<T>>public <U> Promise<U> thenApplyAsync(Function<? super T,? extends U> fn)
thenApplyAsync in interface CompletionStage<T>thenApplyAsync in interface Promise<T>thenApplyAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<Void> thenAcceptAsync(Consumer<? super T> action)
thenAcceptAsync in interface CompletionStage<T>thenAcceptAsync in interface Promise<T>thenAcceptAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<Void> thenRunAsync(Runnable action)
thenRunAsync in interface CompletionStage<T>thenRunAsync in interface Promise<T>thenRunAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public <U,V> Promise<V> thenCombineAsync(CompletionStage<? extends U> other, BiFunction<? super T,? super U,? extends V> fn)
thenCombineAsync in interface CompletionStage<T>thenCombineAsync in interface Promise<T>thenCombineAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public <U> Promise<Void> thenAcceptBothAsync(CompletionStage<? extends U> other, BiConsumer<? super T,? super U> action)
thenAcceptBothAsync in interface CompletionStage<T>thenAcceptBothAsync in interface Promise<T>thenAcceptBothAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<Void> runAfterBothAsync(CompletionStage<?> other, Runnable action)
runAfterBothAsync in interface CompletionStage<T>runAfterBothAsync in interface Promise<T>runAfterBothAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public <U> Promise<U> applyToEitherAsync(CompletionStage<? extends T> other, Function<? super T,U> fn)
applyToEitherAsync in interface CompletionStage<T>applyToEitherAsync in interface Promise<T>applyToEitherAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<Void> acceptEitherAsync(CompletionStage<? extends T> other, Consumer<? super T> action)
acceptEitherAsync in interface CompletionStage<T>acceptEitherAsync in interface Promise<T>acceptEitherAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<Void> runAfterEitherAsync(CompletionStage<?> other, Runnable action)
runAfterEitherAsync in interface CompletionStage<T>runAfterEitherAsync in interface Promise<T>runAfterEitherAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public <U> Promise<U> thenComposeAsync(Function<? super T,? extends CompletionStage<U>> fn)
thenComposeAsync in interface CompletionStage<T>thenComposeAsync in interface Promise<T>thenComposeAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public Promise<T> exceptionallyAsync(Function<Throwable,? extends T> fn)
exceptionallyAsync in interface Promise<T>exceptionallyAsync in class AbstractPromiseDecorator<T,Promise<T>>public Promise<T> exceptionallyComposeAsync(Function<Throwable,? extends CompletionStage<T>> fn)
exceptionallyComposeAsync in interface Promise<T>exceptionallyComposeAsync in class AbstractPromiseDecorator<T,Promise<T>>public Promise<T> thenFilterAsync(Predicate<? super T> predicate)
thenFilterAsync in interface Promise<T>thenFilterAsync in class AbstractPromiseDecorator<T,Promise<T>>public Promise<T> thenFilterAsync(Predicate<? super T> predicate, Function<? super T,Throwable> errorSupplier)
thenFilterAsync in interface Promise<T>thenFilterAsync in class AbstractPromiseDecorator<T,Promise<T>>public Promise<T> whenCompleteAsync(BiConsumer<? super T,? super Throwable> action)
whenCompleteAsync in interface CompletionStage<T>whenCompleteAsync in interface Promise<T>whenCompleteAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>public <U> Promise<U> handleAsync(BiFunction<? super T,Throwable,? extends U> fn)
handleAsync in interface CompletionStage<T>handleAsync in interface Promise<T>handleAsync in class AbstractPromiseLikeDecorator<T,Promise<T>>Copyright © 2021. All rights reserved.