Class ReactorContextExtensions

Namespace
Cratis.Chronicle.Reactors.SideEffects
Assembly
Cratis.Chronicle.dll

Extension methods for ReactorContext that read append-metadata from the Values populated by the registered IReactorContextValuesProvider instances.

public static class ReactorContextExtensions
Inheritance
ReactorContextExtensions
Inherited Members

Methods

GetEventSourceId(ReactorContext)

Gets the EventSourceId to use when appending side-effect events.

public static EventSourceId GetEventSourceId(this ReactorContext reactorContext)

Parameters

reactorContext ReactorContext

The reactor context.

Returns

EventSourceId

The resolved EventSourceId, or the EventSourceId of the triggering event when none was provided.

GetEventSourceType(ReactorContext)

Gets the EventSourceType to use when appending side-effect events.

public static EventSourceType? GetEventSourceType(this ReactorContext reactorContext)

Parameters

reactorContext ReactorContext

The reactor context.

Returns

EventSourceType

The EventSourceType, or null when none was provided.

GetEventStreamId(ReactorContext)

Gets the EventStreamId to use when appending side-effect events.

public static EventStreamId? GetEventStreamId(this ReactorContext reactorContext)

Parameters

reactorContext ReactorContext

The reactor context.

Returns

EventStreamId

The resolved EventStreamId, or null when none was provided.

GetEventStreamType(ReactorContext)

Gets the EventStreamType to use when appending side-effect events.

public static EventStreamType? GetEventStreamType(this ReactorContext reactorContext)

Parameters

reactorContext ReactorContext

The reactor context.

Returns

EventStreamType

The EventStreamType, or null when none was provided.

GetSubject(ReactorContext)

Gets the Subject to use when appending side-effect events.

public static Subject? GetSubject(this ReactorContext reactorContext)

Parameters

reactorContext ReactorContext

The reactor context.

Returns

Subject

The Subject, or null when none was provided.