Class NotificationHandlerExecutor
- Namespace
- Caesar
- Assembly
- Caesar.Abstractions.dll
A resolved notification handler together with a callback that invokes it.
public sealed record NotificationHandlerExecutor : IEquatable<NotificationHandlerExecutor>
- Inheritance
-
NotificationHandlerExecutor
- Implements
- Inherited Members
Constructors
NotificationHandlerExecutor(object, Func<INotification, CancellationToken, Task>)
A resolved notification handler together with a callback that invokes it.
public NotificationHandlerExecutor(object HandlerInstance, Func<INotification, CancellationToken, Task> HandlerCallback)
Parameters
HandlerInstanceobjectThe handler instance (useful for logging or filtering).
HandlerCallbackFunc<INotification, CancellationToken, Task>Invokes the handler for a notification.
Properties
HandlerCallback
Invokes the handler for a notification.
public Func<INotification, CancellationToken, Task> HandlerCallback { get; init; }
Property Value
HandlerInstance
The handler instance (useful for logging or filtering).
public object HandlerInstance { get; init; }
Property Value
Methods
Deconstruct(out object, out Func<INotification, CancellationToken, Task>)
public void Deconstruct(out object HandlerInstance, out Func<INotification, CancellationToken, Task> HandlerCallback)
Parameters
HandlerInstanceobjectHandlerCallbackFunc<INotification, CancellationToken, Task>
Equals(NotificationHandlerExecutor?)
public bool Equals(NotificationHandlerExecutor? other)
Parameters
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(NotificationHandlerExecutor?, NotificationHandlerExecutor?)
public static bool operator ==(NotificationHandlerExecutor? left, NotificationHandlerExecutor? right)
Parameters
Returns
operator !=(NotificationHandlerExecutor?, NotificationHandlerExecutor?)
public static bool operator !=(NotificationHandlerExecutor? left, NotificationHandlerExecutor? right)