Class ReadModelReactorMethods

Namespace
Cratis.Chronicle.ReadModels
Assembly
Cratis.Chronicle.dll

Discovers the convention-based handler methods on a IReadModelReactor.

public static class ReadModelReactorMethods
Inheritance
ReadModelReactorMethods
Inherited Members

Remarks

A handler method is a public instance method named Added, Modified or Removed. Its first parameter is the read model — a single instance or an IEnumerable<T> of instances.

Methods

GetFor(Type)

Get all discovered handler methods for a IReadModelReactor type.

public static IReadOnlyList<ReadModelReactorMethod> GetFor(Type reactorType)

Parameters

reactorType Type

The reactor Type to discover methods for.

Returns

IReadOnlyList<ReadModelReactorMethod>

The collection of ReadModelReactorMethod.

GetReadModelTypesFor(Type)

Get the distinct read model types a IReadModelReactor reacts to.

public static IEnumerable<Type> GetReadModelTypesFor(Type reactorType)

Parameters

reactorType Type

The reactor Type to get read model types for.

Returns

IEnumerable<Type>

The distinct read model Type instances.