Class EnumerableModelWithIdToConceptOrPrimitiveEnumerableConverter<T, TElement>

Namespace
Cratis.Json
Assembly
Cratis.Fundamentals.dll

Represents a JsonConverter<T> for enumerable of concepts or primitive types represented as models with _id field.

public class EnumerableModelWithIdToConceptOrPrimitiveEnumerableConverter<T, TElement> : JsonConverter<T> where T : IEnumerable

Type Parameters

T

Underlying type.

TElement

Element type.

Inheritance
EnumerableModelWithIdToConceptOrPrimitiveEnumerableConverter<T, TElement>
Inherited Members
Extension Methods

Constructors

EnumerableModelWithIdToConceptOrPrimitiveEnumerableConverter()

public EnumerableModelWithIdToConceptOrPrimitiveEnumerableConverter()

Methods

Read(ref Utf8JsonReader, Type, JsonSerializerOptions)

public override T? Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)

Parameters

reader Utf8JsonReader
typeToConvert Type
options JsonSerializerOptions

Returns

T

Write(Utf8JsonWriter, T, JsonSerializerOptions)

public override void Write(Utf8JsonWriter writer, T value, JsonSerializerOptions options)

Parameters

writer Utf8JsonWriter
value T
options JsonSerializerOptions