Note

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

Access to this page requires authorization. You can try .

JsonSerializerOptions.DictionaryKeyPolicy Property

Definition

Namespace:
System.Text.Json
Assembly:
System.Text.Json.dll
Package:
System.Text.Json v11.0.0-preview.5.26302.115
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.cs
Source:
JsonSerializerOptions.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 policy used to convert a IDictionary key's name to another format, such as camel-casing.

public:
 property System::Text::Json::JsonNamingPolicy ^ DictionaryKeyPolicy { System::Text::Json::JsonNamingPolicy ^ get(); void set(System::Text::Json::JsonNamingPolicy ^ value); };
public System.Text.Json.JsonNamingPolicy? DictionaryKeyPolicy { get; set; }
public System.Text.Json.JsonNamingPolicy DictionaryKeyPolicy { get; set; }
member this.DictionaryKeyPolicy : System.Text.Json.JsonNamingPolicy with get, set
Public Property DictionaryKeyPolicy As JsonNamingPolicy

Property Value

The policy used to convert a IDictionary key's name to another format.

Remarks

The naming policy is not used when deserializing.

For more information, see Use a naming policy for dictionary keys.

Applies to


Feedback

Was this page helpful?