Share via


MobileServiceContractResolver.CreateProperty Method

Definition

Creates a Newtonsoft.Json.Serialization.JsonProperty for a given MemberInfo instance.

protected override Newtonsoft.Json.Serialization.JsonProperty CreateProperty (System.Reflection.MemberInfo member, Newtonsoft.Json.MemberSerialization memberSerialization);
override this.CreateProperty : System.Reflection.MemberInfo * Newtonsoft.Json.MemberSerialization -> Newtonsoft.Json.Serialization.JsonProperty
Protected Overrides Function CreateProperty (member As MemberInfo, memberSerialization As MemberSerialization) As JsonProperty

Parameters

member
MemberInfo

The MemberInfo for which to creat the Newtonsoft.Json.Serialization.JsonProperty.

memberSerialization
Newtonsoft.Json.MemberSerialization

Specifies the member serialization options for the member.

Returns

Newtonsoft.Json.Serialization.JsonProperty

A Newtonsoft.Json.Serialization.JsonProperty for a given MemberInfo instance.

Remarks

This method is overridden in order set specialized Newtonsoft.Json.Serialization.IValueProvider implementations for certain property types. The date types (DateTime, DateTimeOffset) require conversion to UTC dates on serialization and to local dates on deserialization. The numerical types (Int64, UInt64, Decimal) require checks to ensure that precision will not be lost on the server.

Applies to