Class FutureCommandResult
java.lang.Object
org.axonframework.messaging.commandhandling.gateway.FutureCommandResult
- All Implemented Interfaces:
CommandResult
A
CommandResult that wraps a completable future providing the Message that represents the result.- Since:
- 0.6
- Author:
- Allard Buijze
-
Constructor Summary
ConstructorsConstructorDescriptionFutureCommandResult(CompletableFuture<? extends Message> result) Initializes the CommandResult based on the givenresultthe completes when the resultMessagebecomes available -
Method Summary
Modifier and TypeMethodDescriptionCompletableFuture<? extends Message> Returns the resultMessagewithin aCompletableFutureof command handling.
-
Constructor Details
-
FutureCommandResult
Initializes the CommandResult based on the givenresultthe completes when the resultMessagebecomes available- Parameters:
result- The completable future that provides the result message when available
-
-
Method Details
-
getResultMessage
Description copied from interface:CommandResultReturns the resultMessagewithin aCompletableFutureof command handling.- Specified by:
getResultMessagein interfaceCommandResult- Returns:
- The result
Messagewithin aCompletableFutureof command handling.
-