Class DefaultCollectingAsyncFuture<V>

  • All Implemented Interfaces:
    AsyncFuture<java.util.List<V>>, AsyncPromise<java.util.List<V>>, Time.Awaitable, java.util.concurrent.CompletionStage<java.util.List<V>>, java.util.concurrent.Future<java.util.List<V>>

    public class DefaultCollectingAsyncFuture<V>
    extends DefaultAsyncFuture<java.util.List<V>>
    A specialised instance of @{link AsyncFuture} for collecting the results of one or more futures of lists into a single list.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.concurrent.CompletableFuture

        java.util.concurrent.CompletableFuture.AsynchronousCompletionTask
    • Constructor Summary

      Constructors 
      Constructor Description
      DefaultCollectingAsyncFuture​(java.util.List<AsyncFuture<java.util.List<V>>> futuresList, boolean cancellable)
      Creates a new instance.
      DefaultCollectingAsyncFuture​(java.util.List<AsyncFuture<java.util.List<V>>> futuresList, boolean cancellable, java.util.function.Function<java.util.List<V>,​java.util.List<V>> filter)
      Creates a new instance.
    • Method Summary

      • Methods inherited from class java.util.concurrent.CompletableFuture

        acceptEither, acceptEitherAsync, acceptEitherAsync, allOf, anyOf, applyToEither, applyToEitherAsync, applyToEitherAsync, completeAsync, completeAsync, completedFuture, completedStage, completeOnTimeout, copy, defaultExecutor, delayedExecutor, delayedExecutor, exceptionally, failedFuture, failedStage, get, getNow, getNumberOfDependents, handle, handleAsync, handleAsync, isCancelled, isCompletedExceptionally, isDone, join, minimalCompletionStage, newIncompleteFuture, obtrudeException, obtrudeValue, orTimeout, runAfterBoth, runAfterBothAsync, runAfterBothAsync, runAfterEither, runAfterEitherAsync, runAfterEitherAsync, runAsync, runAsync, supplyAsync, supplyAsync, thenAccept, thenAcceptAsync, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenAcceptBothAsync, thenApply, thenApplyAsync, thenApplyAsync, thenCombine, thenCombineAsync, thenCombineAsync, thenCompose, thenComposeAsync, thenComposeAsync, thenRun, thenRunAsync, thenRunAsync, toCompletableFuture, toString, whenComplete, whenCompleteAsync, whenCompleteAsync
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.concurrent.CompletionStage

        acceptEither, acceptEitherAsync, acceptEitherAsync, applyToEither, applyToEitherAsync, applyToEitherAsync, exceptionally, handle, handleAsync, handleAsync, runAfterBoth, runAfterBothAsync, runAfterBothAsync, runAfterEither, runAfterEitherAsync, runAfterEitherAsync, thenAccept, thenAcceptAsync, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenAcceptBothAsync, thenApply, thenApplyAsync, thenApplyAsync, thenCombine, thenCombineAsync, thenCombineAsync, thenCompose, thenComposeAsync, thenComposeAsync, thenRun, thenRunAsync, thenRunAsync, toCompletableFuture, whenComplete, whenCompleteAsync, whenCompleteAsync
      • Methods inherited from interface java.util.concurrent.Future

        get, isCancelled, isDone
    • Constructor Detail

      • DefaultCollectingAsyncFuture

        public DefaultCollectingAsyncFuture​(@Nonnull
                                            java.util.List<AsyncFuture<java.util.List<V>>> futuresList,
                                            boolean cancellable)
        Creates a new instance.
        Parameters:
        futuresList - List of @{AsyncFuture}s to be collated.
        cancellable - true if and only if this future can be canceled
      • DefaultCollectingAsyncFuture

        public DefaultCollectingAsyncFuture​(@Nonnull
                                            java.util.List<AsyncFuture<java.util.List<V>>> futuresList,
                                            boolean cancellable,
                                            @Nonnull
                                            java.util.function.Function<java.util.List<V>,​java.util.List<V>> filter)
        Creates a new instance.
        Parameters:
        futuresList - List of @{AsyncFuture}s to be collated.
        cancellable - true if and only if this future can be canceled
        filter - a Function to filter the completing futures.