Skip to main content
Table of Contents

Class MappingServiceCollectionExtensions

Namespace
Microsoft.Extensions.DependencyInjection
Assembly
Stratara.Shared.dll

Dependency-injection helpers that register Stratara's mapping primitives (event-stream entry to IEvent conversion) into an IServiceCollection.

public static class MappingServiceCollectionExtensions
Inheritance
MappingServiceCollectionExtensions
Inherited Members

Methods

AddMapping(IServiceCollection)

Registers the singleton IEventMapperFactory implementation used by the event-sourcing stack to materialize typed IEvent instances from persisted EventStreamEntry / EventMessage rows.

public static IServiceCollection AddMapping(this IServiceCollection services)

Parameters

services IServiceCollection

The DI container to extend.

Returns

IServiceCollection

The same services instance to allow fluent chaining.

Examples

services.AddMapping();