Class RemoveConstraintAttribute

Namespace
Cratis.Chronicle.Events.Constraints
Assembly
Cratis.Chronicle.dll

Attribute to adorn event types to indicate that appending this event releases a named constraint.

[AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
public sealed class RemoveConstraintAttribute : Attribute
Inheritance
RemoveConstraintAttribute
Inherited Members
Extension Methods

Remarks

Place this attribute on the event type that signals removal of a domain object (e.g. a deletion event). The named constraint will stop blocking future appends once this event is observed. Multiple attributes may be applied to the same event type if it releases more than one constraint.

Constructors

RemoveConstraintAttribute(string)

Attribute to adorn event types to indicate that appending this event releases a named constraint.

public RemoveConstraintAttribute(string constraintName)

Parameters

constraintName string

Name of the constraint to release.

Remarks

Place this attribute on the event type that signals removal of a domain object (e.g. a deletion event). The named constraint will stop blocking future appends once this event is observed. Multiple attributes may be applied to the same event type if it releases more than one constraint.

Properties

ConstraintName

Gets the name of the constraint to release.

public string ConstraintName { get; }

Property Value

string

Properties

Gets or sets the properties carrying the value to release in per-value mode.

public string[] Properties { get; set; }

Property Value

string[]

Remarks

List composite properties in the same order as the constrained properties. Empty releases every value held by the event source in the constraint's scope. Per-event-source mode always releases its one claim.