言語

JsonPolymorphicAttribute クラス

定義

型に配置すると、型をポリモーフィックにシリアル化する必要があることを示します。

public ref class JsonPolymorphicAttribute sealed : System::Text::Json::Serialization::JsonAttribute
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Interface, AllowMultiple=false, Inherited=false)]
public sealed class JsonPolymorphicAttribute : System.Text.Json.Serialization.JsonAttribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Interface, AllowMultiple=false, Inherited=false)>]
type JsonPolymorphicAttribute = class
    inherit JsonAttribute
Public NotInheritable Class JsonPolymorphicAttribute
Inherits JsonAttribute
継承
JsonPolymorphicAttribute
属性

コンストラクター

名前 説明
JsonPolymorphicAttribute()

新しい JsonPolymorphicAttribute インスタンスを作成します。

プロパティ

名前 説明
IgnoreUnrecognizedTypeDiscriminators

デシリアライザーが認識できない型判別 ID を無視し、基本型のコントラクトに戻す必要があるかどうかを示す値を取得または設定します。

TypeClassifier

型に配置すると、型をポリモーフィックにシリアル化する必要があることを示します。

TypeDiscriminatorPropertyName

ポリモーフィック型のカスタム型識別子プロパティ名を取得または設定します。 設定を解除した場合は、既定の '$type' プロパティ名を使用します。

TypeId

派生クラスで実装されている場合は、この Attributeの一意の識別子を取得します。

(継承元 Attribute)
UnknownDerivedTypeHandling

宣言されていない派生ランタイム型をシリアル化するときの動作を取得または設定します。

メソッド

名前 説明
Equals(Object)

このインスタンスが指定したオブジェクトと等しいかどうかを示す値を返します。

(継承元 Attribute)
GetHashCode()

このインスタンスのハッシュ コードを返します。

(継承元 Attribute)
GetType()

現在のインスタンスの Type を取得します。

(継承元 Object)
IsDefaultAttribute()

派生クラスでオーバーライドされた場合、このインスタンスの値が派生クラスの既定値であるかどうかを示します。

(継承元 Attribute)
Match(Object)

派生クラスでオーバーライドされた場合、このインスタンスが指定したオブジェクトと等しいかどうかを示す値を返します。

(継承元 Attribute)
MemberwiseClone()

現在の Objectの簡易コピーを作成します。

(継承元 Object)
ToString()

現在のオブジェクトを表す文字列を返します。

(継承元 Object)

適用対象