共用方式為


InterfaceConverter<T> Class

Definition

Handles resolving interfaces to the correct concrete class during serialization/deserialization.

public class InterfaceConverter<T> : Newtonsoft.Json.Converters.CustomCreationConverter<T> where T : new()
type InterfaceConverter<'T (requires 'T : (new : unit -> 'T))> = class
    inherit CustomCreationConverter<'T (requires 'T : (new : unit -> 'T))>
Public Class InterfaceConverter(Of T)
Inherits CustomCreationConverter(Of T)

Type Parameters

T

The concrete instance type.

Inheritance
Newtonsoft.Json.Converters.CustomCreationConverter<T>
InterfaceConverter<T>

Constructors

InterfaceConverter<T>()

Methods

Create(Type)

Create a new object of type T.

Applies to