Class DecrementAttribute<TEvent>
- Namespace
- Cratis.Chronicle.Projections.ModelBound
- Assembly
- Cratis.Chronicle.dll
Attribute used to indicate that a property value should be decremented when an event occurs.
[AttributeUsage(AttributeTargets.Property|AttributeTargets.Parameter, AllowMultiple = true)]
public sealed class DecrementAttribute<TEvent> : Attribute, IProjectionAnnotation, IDecrementAttribute, IEventBoundAttribute
Type Parameters
TEventThe type of event that triggers the decrement.
- Inheritance
-
DecrementAttribute<TEvent>
- Implements
- Inherited Members
Properties
ConstantKey
Gets a constant value to use as the key. All events of this type will update the same read model instance.
public string? ConstantKey { get; init; }
Property Value
EventType
Gets the type of event this attribute is bound to.
public Type EventType { get; }