CQRS.NET
2.1
A lightweight enterprise framework to write CQRS, event-sourced and micro-service applications in hybrid multi-datacentre, on-premise and Azure environments.
|
TEvent Cqrs.Commands.ISendAndWaitCommandSender< TAuthenticationToken >.SendAndWait< TCommand, TEvent > | ( | TCommand | command, |
Func< IEnumerable< IEvent< TAuthenticationToken >>, TEvent > | condition, | ||
TimeSpan | timeout, | ||
IEventReceiver< TAuthenticationToken > | eventReceiver = null |
||
) |
Sends the provided command and waits for an event of TEvent or exits if the specified timeout is expired.
command | The TCommand to send. |
condition | A delegate to be executed over and over until it returns the TEvent that is desired, return null to keep trying. |
timeout | A T:System.TimeSpan that represents the number of milliseconds to wait, or a TimeSpan that represents -1 milliseconds to wait indefinitely. |
eventReceiver | If provided, is the IEventReceiver<TAuthenticationToken> that the event is expected to be returned on. |
Implemented in Cqrs.Bus.InProcessBus< TAuthenticationToken >, Cqrs.Azure.ServiceBus.AzureCommandBusPublisher< TAuthenticationToken >, Cqrs.Azure.ServiceBus.AzureCommandBusPublisher< TAuthenticationToken >, and Cqrs.Akka.Commands.AkkaCommandBus< TAuthenticationToken >.
TCommand | : | ICommand<TAuthenticationToken> |