Package io.hekate.network
Class NetworkFuture<T>
- java.lang.Object
-
- java.util.concurrent.CompletableFuture<NetworkEndpoint<T>>
-
- io.hekate.network.NetworkFuture<T>
-
- Type Parameters:
T
- Base type ofNetworkEndpoint
's messages.
- All Implemented Interfaces:
CompletionStage<NetworkEndpoint<T>>
,Future<NetworkEndpoint<T>>
public class NetworkFuture<T> extends CompletableFuture<NetworkEndpoint<T>>
Result of an asynchronous operation inNetworkEndpoint
.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class java.util.concurrent.CompletableFuture
CompletableFuture.AsynchronousCompletionTask
-
-
Constructor Summary
Constructors Constructor Description NetworkFuture()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> NetworkFuture<T>
completed(NetworkEndpoint<T> endpoint)
Returns completed future.-
Methods inherited from class java.util.concurrent.CompletableFuture
acceptEither, acceptEitherAsync, acceptEitherAsync, allOf, anyOf, applyToEither, applyToEitherAsync, applyToEitherAsync, cancel, complete, completeAsync, completeAsync, completedFuture, completedStage, completeExceptionally, completeOnTimeout, copy, defaultExecutor, delayedExecutor, delayedExecutor, exceptionally, failedFuture, failedStage, get, 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
-
-
-
-
Method Detail
-
completed
public static <T> NetworkFuture<T> completed(NetworkEndpoint<T> endpoint)
Returns completed future.- Type Parameters:
T
- Endpoint type.- Parameters:
endpoint
- Endpoint.- Returns:
- Completed future.
-
-