Class EventStoreAttribute
Attribute to adorn event types or an assembly to indicate that event types originate from a specific event store.
[AttributeUsage(AttributeTargets.Assembly|AttributeTargets.Class, AllowMultiple = false)]
public sealed class EventStoreAttribute : Attribute
- Inheritance
-
EventStoreAttribute
- Inherited Members
Remarks
When applied to an event type class, it identifies the event store the event originates from. When applied at the assembly level, all event types in that assembly are considered to originate from the specified event store. A type-level attribute takes precedence over an assembly-level attribute. When an observer (Reactor, Reducer, or Projection) handles event types annotated with this attribute, it will automatically subscribe to the inbox event sequence for the specified event store. All event types handled by an observer must originate from the same event store.
Constructors
EventStoreAttribute(string)
Attribute to adorn event types or an assembly to indicate that event types originate from a specific event store.
public EventStoreAttribute(string eventStore)
Parameters
eventStorestringThe name of the event store this event type originates from.
Remarks
When applied to an event type class, it identifies the event store the event originates from. When applied at the assembly level, all event types in that assembly are considered to originate from the specified event store. A type-level attribute takes precedence over an assembly-level attribute. When an observer (Reactor, Reducer, or Projection) handles event types annotated with this attribute, it will automatically subscribe to the inbox event sequence for the specified event store. All event types handled by an observer must originate from the same event store.
Properties
EventStore
Gets the name of the event store this event type originates from.
public string EventStore { get; }