DelayableCompletableFuture
abstract class DelayableCompletableFuture<T> : CompletableFuture<T> , DelayCompletionStage<T> (source)
继承 CompletableFuture 并实现 DelayCompletionStage, 提供 CompletableFuture 与 DelayCompletionStage 的能力.
Author
ForteScarlet
See also
Functions
Link copied to clipboard
abstract override fun acceptEither(other: CompletionStage<out T>, action: Consumer<in T>): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun acceptEitherAsync(other: CompletionStage<out T>, action: Consumer<in T>): DelayableCompletableFuture<Void?>
abstract override fun acceptEitherAsync(other: CompletionStage<out T>, action: Consumer<in T>, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun <U> applyToEither(other: CompletionStage<out T>, fn: Function<in T, U>): DelayableCompletableFuture<U>
Link copied to clipboard
abstract override fun <U> applyToEitherAsync(other: CompletionStage<out T>, fn: Function<in T, U>): DelayableCompletableFuture<U>
abstract override fun <U> applyToEitherAsync(other: CompletionStage<out T>, fn: Function<in T, U>, executor: Executor): DelayableCompletableFuture<U>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract override fun delay(duration: JavaDuration, runnable: Runnable): DelayableCompletableFuture<T>
当等待的计算结果(通过 get 可以得到的结果 )计算完成后, 延迟指定时间单位为 TimeUnit.MILLISECONDS 的时间周期 time,并执行 runnable 函数。
Link copied to clipboard
abstract override fun <V> delayAndCompute(duration: JavaDuration, function: Function<T, V>): DelayableCompletableFuture<V>
abstract override fun <V> delayAndCompute(time: Long, function: Function<T, V>): DelayableCompletableFuture<V>
abstract override fun <V> delayAndCompute(time: Long, timeUnit: TimeUnit, function: Function<T, V>): DelayableCompletableFuture<V>
当等待的计算结果(通过 get 可以得到的结果 )计算完成后, 延迟指定时间单位为 TimeUnit.MILLISECONDS 的时间周期 time,并执行 function 函数。
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract override fun <U> handle(fn: BiFunction<in T?, Throwable?, out U>): DelayableCompletableFuture<U>
Link copied to clipboard
abstract override fun <U> handleAsync(fn: BiFunction<in T?, Throwable?, out U>): DelayableCompletableFuture<U>
abstract override fun <U> handleAsync(fn: BiFunction<in T?, Throwable?, out U>, executor: Executor): DelayableCompletableFuture<U>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract override fun runAfterBoth(other: CompletionStage<*>, action: Runnable): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun runAfterBothAsync(other: CompletionStage<*>, action: Runnable): DelayableCompletableFuture<Void?>
abstract override fun runAfterBothAsync(other: CompletionStage<*>, action: Runnable, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun runAfterEither(other: CompletionStage<*>, action: Runnable): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun runAfterEitherAsync(other: CompletionStage<*>, action: Runnable): DelayableCompletableFuture<Void?>
abstract override fun runAfterEitherAsync(other: CompletionStage<*>, action: Runnable, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
Link copied to clipboard
abstract override fun thenAcceptAsync(action: Consumer<in T>, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun <U> thenAcceptBoth(other: CompletionStage<out U>, action: BiConsumer<in T, in U>): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun <U> thenAcceptBothAsync(other: CompletionStage<out U>, action: BiConsumer<in T, in U>): DelayableCompletableFuture<Void?>
abstract override fun <U> thenAcceptBothAsync(other: CompletionStage<out U>, action: BiConsumer<in T, in U>, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
abstract override fun <U> thenApplyAsync(fn: Function<in T, out U>, executor: Executor): DelayableCompletableFuture<U>
Link copied to clipboard
abstract override fun <U, V> thenCombine(other: CompletionStage<out U>, fn: BiFunction<in T, in U, out V>): DelayableCompletableFuture<V>
Link copied to clipboard
abstract override fun <U, V> thenCombineAsync(other: CompletionStage<out U>, fn: BiFunction<in T, in U, out V>): DelayableCompletableFuture<V>
abstract override fun <U, V> thenCombineAsync(other: CompletionStage<out U>, fn: BiFunction<in T, in U, out V>, executor: Executor): DelayableCompletableFuture<V>
Link copied to clipboard
abstract override fun <U> thenCompose(fn: Function<in T, out CompletionStage<U>>): DelayableCompletableFuture<U>
Link copied to clipboard
abstract override fun <U> thenComposeAsync(fn: Function<in T, out CompletionStage<U>>): DelayableCompletableFuture<U>
abstract override fun <U> thenComposeAsync(fn: Function<in T, out CompletionStage<U>>, executor: Executor): DelayableCompletableFuture<U>
Link copied to clipboard
Link copied to clipboard
abstract override fun thenRunAsync(action: Runnable, executor: Executor): DelayableCompletableFuture<Void?>
Link copied to clipboard
得到 CompletableFuture 对象。
Link copied to clipboard
abstract override fun whenComplete(action: BiConsumer<in T?, in Throwable?>): DelayableCompletableFuture<T>
Link copied to clipboard
abstract override fun whenCompleteAsync(action: BiConsumer<in T?, in Throwable?>): DelayableCompletableFuture<T>
abstract override fun whenCompleteAsync(action: BiConsumer<in T?, in Throwable?>, executor: Executor): DelayableCompletableFuture<T>