Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

JsonTypeInfo.UnmappedMemberHandling Property

Definition

Namespace:
System.Text.Json.Serialization.Metadata
Assembly:
System.Text.Json.dll
Package:
System.Text.Json v11.0.0-preview.5.26302.115
Source:
JsonTypeInfo.cs
Source:
JsonTypeInfo.cs
Source:
JsonTypeInfo.cs
Source:
JsonTypeInfo.cs
Source:
JsonTypeInfo.cs
Source:
JsonTypeInfo.cs

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Gets or sets the type-level JsonUnmappedMemberHandling override.

public:
 property Nullable<System::Text::Json::Serialization::JsonUnmappedMemberHandling> UnmappedMemberHandling { Nullable<System::Text::Json::Serialization::JsonUnmappedMemberHandling> get(); void set(Nullable<System::Text::Json::Serialization::JsonUnmappedMemberHandling> value); };
public System.Text.Json.Serialization.JsonUnmappedMemberHandling? UnmappedMemberHandling { get; set; }
member this.UnmappedMemberHandling : Nullable<System.Text.Json.Serialization.JsonUnmappedMemberHandling> with get, set
Public Property UnmappedMemberHandling As Nullable(Of JsonUnmappedMemberHandling)

Property Value

Exceptions

The JsonTypeInfo instance has been locked for further modification.

-or-

Unmapped member handling is only supported for Object.

Remarks

For contracts originating from DefaultJsonTypeInfoResolver or JsonSerializerContext, the value of this callback will be mapped from any JsonUnmappedMemberHandlingAttribute annotations.

Applies to


Feedback

Was this page helpful?