Class SingleOrManyDataConverterFactory
- Namespace
- JsonApiDotNetCore.Serialization.JsonConverters
- Assembly
- JsonApiDotNetCore.dll
Converts SingleOrManyData<T> to/from JSON.
[UsedImplicitly(ImplicitUseKindFlags.InstantiatedNoFixedConstructorSignature)]
public sealed class SingleOrManyDataConverterFactory : JsonConverterFactory
- Inheritance
-
SingleOrManyDataConverterFactory
- Inherited Members
Methods
CanConvert(Type)
When overridden in a derived class, determines whether the converter instance can convert the specified object type.
public override bool CanConvert(Type typeToConvert)
Parameters
typeToConvert
TypeThe type of the object to check whether it can be converted by this converter instance.
Returns
CreateConverter(Type, JsonSerializerOptions)
Creates a converter for a specified type.
public override JsonConverter CreateConverter(Type typeToConvert, JsonSerializerOptions options)
Parameters
typeToConvert
TypeThe type handled by the converter.
options
JsonSerializerOptionsThe serialization options to use.
Returns
- JsonConverter
A converter for which
T
is compatible withtypeToConvert
.