Class FieldChangedEvent<TAggregate>
- Namespace
- Stratara.Shared.EventSourcing
- Assembly
- Stratara.Shared.dll
Generic field-level change event that records a single property mutation on
TAggregate. The generic type parameter acts as a type discriminator so
that the framework can route the event back to the correct aggregate handler.
[ExcludeFromCodeCoverage]
public sealed record FieldChangedEvent<TAggregate> : IEquatable<FieldChangedEvent<TAggregate>>
Type Parameters
TAggregateCLR type of the aggregate whose property changed.
- Inheritance
-
FieldChangedEvent<TAggregate>
- Implements
-
IEquatable<FieldChangedEvent<TAggregate>>
- Inherited Members
- Extension Methods
Constructors
FieldChangedEvent(string, object?)
Generic field-level change event that records a single property mutation on
TAggregate. The generic type parameter acts as a type discriminator so
that the framework can route the event back to the correct aggregate handler.
public FieldChangedEvent(string PropertyName, object? NewValue)
Parameters
PropertyNamestringName of the mutated property on the aggregate.
NewValueobjectThe new value to assign (may be null for reference / nullable value types).
Properties
NewValue
The new value to assign (may be null for reference / nullable value types).
public object? NewValue { get; init; }
Property Value
PropertyName
Name of the mutated property on the aggregate.
public string PropertyName { get; init; }