Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

class System.​Text.​Json.​Serialization.​JsonConverterFactory

Assembly: System.Text.Json

Inheritance: object → JsonConverter → JsonConverterFactory

Supports converting several types by using a factory pattern.

Properties

public Type
Type
Gets the type being converted by the current converter instance.

Methods

public JsonConverter
CreateConverter​(Type typeToConvert, JsonSerializerOptions options)
Creates a converter for a specified type.
Returns A converter for which <typeparamref name="T" /> is compatible with <paramref name="typeToConvert" /> .
typeToConvert The type handled by the converter.
options The serialization options to use.
public bool
CanConvert​(Type typeToConvert)
Inherited from JsonConverter
When overridden in a derived class, determines whether the converter instance can convert the specified object type.
Returns <see langword="true" /> if the instance can convert the specified object type; otherwise, <see langword="false" /> .
typeToConvert The type of the object to check whether it can be converted by this converter instance.
public bool
Equals​(object obj)
Inherited from object
protected void
Finalize​()
Inherited from object
public int
GetHashCode​()
Inherited from object
public Type
GetType​()
Inherited from object
protected object
MemberwiseClone​()
Inherited from object
public string
ToString​()
Inherited from object