Skip to content

Class EventViewModelFactory ​

Namespace: Momentum.Extensions.EventMarkdownGenerator.Services
Assembly: Momentum.Extensions.EventMarkdownGenerator.dll

Factory for creating view models used in Liquid template rendering. Extracts complex object creation logic from FluidMarkdownGenerator.

csharp
public static class EventViewModelFactory

Inheritance ​

object ← EventViewModelFactory

Inherited Members ​

object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Methods ​

CreateEventModel(EventMetadata, EventDocumentation, GeneratorOptions?, IReadOnlySet<Type>?) ​

Creates an event view model for template rendering.

csharp
public static EventViewModel CreateEventModel(EventMetadata metadata, EventDocumentation documentation, GeneratorOptions? options = null, IReadOnlySet<Type>? schemaTypes = null)

Parameters ​

metadata EventMetadata

The event metadata to render.

documentation EventDocumentation

The event's XML documentation.

options GeneratorOptions?

Optional generator options for customization.

schemaTypes IReadOnlySet<Type>?

Types with generated schema documentation, used to link to its schema page when is among them.

Returns ​

EventViewModel

CreateSchemaModel(Type) ​

Creates a schema model for template rendering.

csharp
public static object CreateSchemaModel(Type schemaType)

Parameters ​

schemaType Type

Returns ​

object