Class AsyncScatterGather<TRequest, TResponse, TResult>.Builder
- Namespace
- PatternKit.Messaging.Routing
- Assembly
- PatternKit.Core.dll
Fluent builder for AsyncScatterGather<TRequest, TResponse, TResult>.
public sealed class AsyncScatterGather<TRequest, TResponse, TResult>.Builder
- Inheritance
-
AsyncScatterGather<TRequest, TResponse, TResult>.Builder
- Inherited Members
Methods
Build()
Builds an immutable async scatter-gather.
public AsyncScatterGather<TRequest, TResponse, TResult> Build()
Returns
- AsyncScatterGather<TRequest, TResponse, TResult>
CompleteWith(CompletionStrategy)
Sets the completion strategy (default: All).
public AsyncScatterGather<TRequest, TResponse, TResult>.Builder CompleteWith(CompletionStrategy strategy)
Parameters
strategyCompletionStrategy
Returns
- AsyncScatterGather<TRequest, TResponse, TResult>.Builder
Recipient(string, AsyncRecipientHandler)
Adds a named async recipient.
public AsyncScatterGather<TRequest, TResponse, TResult>.Builder Recipient(string name, AsyncScatterGather<TRequest, TResponse, TResult>.AsyncRecipientHandler handler)
Parameters
namestringhandlerAsyncScatterGather<TRequest, TResponse, TResult>.AsyncRecipientHandler
Returns
- AsyncScatterGather<TRequest, TResponse, TResult>.Builder
WithAggregator(ResponseAggregator)
Sets the aggregation delegate.
public AsyncScatterGather<TRequest, TResponse, TResult>.Builder WithAggregator(AsyncScatterGather<TRequest, TResponse, TResult>.ResponseAggregator aggregator)
Parameters
aggregatorAsyncScatterGather<TRequest, TResponse, TResult>.ResponseAggregator
Returns
- AsyncScatterGather<TRequest, TResponse, TResult>.Builder