Interface INotificationHandler<T1, T2>
- Namespace
- Arc4u.Dispatcher.Notification
- Assembly
- Arc4u.Dispatcher.dll
Implemented to react to a notification carrying 2 values. Register the implementations in the dependency injection container; they are resolved through INotificationHandlers<T1, T2>.
public interface INotificationHandler<T1, T2>
Type Parameters
T1The type of the notification value number 1.
T2The type of the notification value number 2.
Methods
HandleAsync(T1, T2, CancellationToken)
Handles the notification.
Task HandleAsync(T1 param1, T2 param2, CancellationToken cancellationToken)
Parameters
param1T1The notification value number 1.
param2T2The notification value number 2.
cancellationTokenCancellationTokenA token to cancel the operation.
Returns
- Task
A task that completes when the notification is handled.