29 Type type = target.GetType();
72 Type <UnderlyingType>k__BackingField =
contractSafe.<UnderlyingType>k__BackingField;
73 if (
serializer.GetMatchingConverter(<UnderlyingType>k__BackingField) !=
null)
77 JsonConverter <InternalConverter>k__BackingField =
contractSafe.<InternalConverter>k__BackingField;
140 Type <UnderlyingType>k__BackingField =
contract.<UnderlyingType>k__BackingField;
176 return "Unexpected end when deserializing object.";
207 return "JSON object (e.g. {\"name\":\"value\"})";
219 JsonConverter <InternalConverter>k__BackingField;
224 Type <UnderlyingType>k__BackingField =
contract.<UnderlyingType>k__BackingField;
229 JsonConverter <InternalConverter>k__BackingField =
contract.<InternalConverter>k__BackingField;
261 bool <SupportMultipleContent>k__BackingField = reader.<SupportMultipleContent>k__BackingField;
262 jsonReader.<SupportMultipleContent>k__BackingField = <SupportMultipleContent>k__BackingField;
334 string text =
"Resolved object reference '{0}' to {1}.".FormatWith(
invariantCulture, reader, type);
337 string text2 =
"JSON reference {0} property must have a string or null value.".FormatWith(
invariantCulture2,
"$ref");
339 return "Additional content found in JSON reference object. A JSON reference object should only have a {0} property." !=
null;
360 if (<ItemTypeNameHandling>k__BackingField !=
null)
362 if (<ItemTypeNameHandling>k__BackingField ==
null)
391 string text =
"Type specified in JSON '{0}' was not resolved.".FormatWith(
invariantCulture, text2);
436 return "Cannot populate list type {0}.";
448 return "Cannot preserve reference to array or readonly list, or list created from a non-default constructor: {0}.";
465 Type <UnderlyingType>k__BackingField =
contract.<UnderlyingType>k__BackingField;
583 bool <Writable>k__BackingField =
property.<Writable>k__BackingField;
590 if (
contract.<CanDeserialize>k__BackingField)
592 if (
contract._overrideCreator !=
null)
594 if (
contract.<HasParameterizedCreator>k__BackingField)
597 return contract.CreateTemporaryCollection();
603 if (!
contract.IsReadOnlyOrFixedSize)
609 if (
contract.<ShouldCreateWrapper>k__BackingField)
615 bool <ShouldCreateWrapper>k__BackingField;
616 while (<ShouldCreateWrapper>k__BackingField)
619 while (<ShouldCreateWrapper>k__BackingField)
622 while (<ShouldCreateWrapper>k__BackingField)
625 if (!<ShouldCreateWrapper>k__BackingField)
631 return "Could not create an instance of type {0}. Type is an interface or abstract class and cannot be instantiated.";
637 if (
contract.<DefaultCreator>k__BackingField ==
null)
641 if (
contract.<DefaultCreatorNonPublic>k__BackingField)
645 <ShouldCreateWrapper>k__BackingField =
contract.<ShouldCreateWrapper>k__BackingField;
646 if (<ShouldCreateWrapper>k__BackingField)
665 return "Unable to find a constructor to use for type {0}.";
673 if (
contract._overrideCreator !=
null)
675 if (
contract.<HasParameterizedCreator>k__BackingField)
685 bool <ShouldCreateWrapper>k__BackingField;
686 if (
contract.<DefaultCreator>k__BackingField !=
null)
688 if (
contract.<DefaultCreatorNonPublic>k__BackingField)
692 <ShouldCreateWrapper>k__BackingField =
contract.<ShouldCreateWrapper>k__BackingField;
693 if (<ShouldCreateWrapper>k__BackingField)
706 while (<ShouldCreateWrapper>k__BackingField)
709 while (<ShouldCreateWrapper>k__BackingField)
712 while (<ShouldCreateWrapper>k__BackingField)
715 if (!<ShouldCreateWrapper>k__BackingField)
725 return contract.CreateTemporaryDictionary();
727 return "Could not create an instance of type {0}. Type is an interface or abstract class and cannot be instantiated.";
768 if (
contract.<KeyContract>k__BackingField ==
null)
770 Type <DictionaryKeyType>k__BackingField =
contract.<DictionaryKeyType>k__BackingField;
776 Type <DictionaryValueType>k__BackingField =
contract.<DictionaryValueType>k__BackingField;
780 if (
contract.<ItemConverter>k__BackingField ==
null)
784 if (
contract.<KeyContract>k__BackingField !=
null)
793 JsonContract <KeyContract>k__BackingField =
contract.<KeyContract>k__BackingField;
809 base.ClearErrorContext();
827 Type <CollectionItemType>k__BackingField =
contract.<CollectionItemType>k__BackingField;
1005 JsonPropertyCollection <Properties>k__BackingField;
1008 <Properties>k__BackingField =
contract.<Properties>k__BackingField;
1034 if (
jsonProperty.<PropertyContract>k__BackingField ==
null)
1040 JsonConverter <MemberConverter>k__BackingField =
jsonProperty.<MemberConverter>k__BackingField;
1042 JsonContract <PropertyContract>k__BackingField =
jsonProperty.<PropertyContract>k__BackingField;
1049 Type <UnderlyingType>k__BackingField =
contract.<UnderlyingType>k__BackingField;
1050 string text =
"Could not find member '{0}' on {1}".FormatWith(
invariantCulture, reader, <UnderlyingType>k__BackingField);
1061 if (<Properties>k__BackingField !=
null)
1099 bool flag = memberName ==
"$id";
1100 bool flag2 = memberName ==
"$ref";
1101 bool flag3 = memberName ==
"$type";
1102 bool flag4 = memberName ==
"$values";
1125 if (
contract.ExtensionDataIsJToken)
1154 Required? <ItemRequired>k__BackingField =
contract.<ItemRequired>k__BackingField;
1155 JsonPropertyCollection <Properties>k__BackingField =
contract.<Properties>k__BackingField;
1160 if (!
property.<Ignored>k__BackingField)
1162 if (
property.<PropertyContract>k__BackingField ==
null)
1164 Type propertyType =
property._propertyType;
1166 property.<PropertyContract>k__BackingField =
contractSafe;
1170 if (property.<Writable>k__BackingField)
1172 IValueProvider <ValueProvider>k__BackingField =
property.<ValueProvider>k__BackingField;
1176 JsonContract <PropertyContract>k__BackingField =
property.<PropertyContract>k__BackingField;
1195 base.ClearErrorContext();
1294 return p._propertyName;
1300 return p._propertyName;
class f__AnonymousType0<< Count > j__TPar
bool ReadAndMoveToContent()
DateTimeZoneHandling _dateTimeZoneHandling
FloatParseHandling _floatParseHandling
DateParseHandling _dateParseHandling
static JsonSerializationException Create(JsonReader reader, string message)
DefaultValueHandling _defaultValueHandling
NullValueHandling _nullValueHandling
IReferenceResolver GetReferenceResolver()
ConstructorHandling _constructorHandling
IContractResolver _contractResolver
MissingMemberHandling _missingMemberHandling
SerializationBinder _binder
TypeNameHandling _typeNameHandling
static JToken ReadFrom(JsonReader reader)
JsonReader CreateReader()
readonly ITraceWriter TraceWriter
readonly JsonSerializer Serializer
JsonSerializerInternalReader.? PropertyPresence Presence
JsonProperty ConstructorProperty
JsonSerializerProxy GetInternalSerializer()
bool ReadMetadataPropertiesToken(JTokenReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue, [Out] object newValue, [Out] string id)
object CreateISerializable(JsonReader reader, JsonISerializableContract contract, JsonProperty member, string id)
void ResolveTypeName(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, string qualifiedTypeName)
object ReadExtensionDataValue(JsonObjectContract contract, JsonProperty member, JsonReader reader)
object DeserializeConvertable(JsonConverter converter, JsonReader reader, Type objectType, object existingValue)
void SetExtensionData(JsonObjectContract contract, JsonProperty member, JsonReader reader, string memberName, object o)
object CreateISerializableItem(JToken token, Type type, JsonISerializableContract contract, JsonProperty member)
IDictionary CreateNewDictionary(JsonReader reader, JsonDictionaryContract contract, [Out] bool createdFromNonDefaultCreator)
object Deserialize(JsonReader reader, Type objectType, bool checkAdditionalContent)
object PopulateList(IList list, JsonReader reader, JsonArrayContract contract, JsonProperty containerProperty, string id)
object PopulateMultidimensionalArray(IList list, JsonReader reader, JsonArrayContract contract, JsonProperty containerProperty, string id)
bool SetPropertyValue(JsonProperty property, JsonConverter propertyConverter, JsonContainerContract containerContract, JsonProperty containerProperty, JsonReader reader, object target)
bool ReadForType(JsonReader reader, JsonContract contract, bool hasConverter)
bool ReadMetadataProperties(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue, [Out] object newValue, [Out] string id)
JsonConverter GetConverter(JsonContract contract, JsonConverter memberConverter, JsonContainerContract containerContract, JsonProperty containerProperty)
bool HasNoDefinedType(JsonContract contract)
bool CheckPropertyName(JsonReader reader, string memberName)
bool CalculatePropertyDetails(JsonProperty property, JsonConverter propertyConverter, JsonContainerContract containerContract, JsonProperty containerProperty, JsonReader reader, object target, [Out] bool useExistingValue, [Out] object currentValue, [Out] JsonContract propertyContract, [Out] bool gottenCurrentValue)
void ThrowUnexpectedEndException(JsonReader reader, JsonContract contract, object currentObject, string message)
object CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue)
object CreateValueInternal(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue)
object CreateList(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, object existingValue, string id)
JsonSerializerInternalReader(JsonSerializer serializer)
bool ShouldSetPropertyValue(JsonProperty property, object value)
bool HasFlag(DefaultValueHandling value, DefaultValueHandling flag)
void AddReference(JsonReader reader, string id, object value)
JToken CreateJToken(JsonReader reader, JsonContract contract)
bool ShouldDeserialize(JsonReader reader, JsonProperty property, object target)
object CreateNewObject(JsonReader reader, JsonObjectContract objectContract, JsonProperty containerMember, JsonProperty containerProperty, string id, [Out] bool createdFromNonDefaultCreator)
object PopulateDictionary(IDictionary dictionary, JsonReader reader, JsonDictionaryContract contract, JsonProperty containerProperty, string id)
object EnsureType(JsonReader reader, object value, CultureInfo culture, JsonContract contract, Type targetType)
string GetExpectedDescription(JsonContract contract)
List< JsonSerializerInternalReader.CreatorPropertyContext > ResolvePropertyAndCreatorValues(JsonObjectContract contract, JsonProperty containerProperty, JsonReader reader, Type objectType)
void Populate(JsonReader reader, object target)
void SetPropertyPresence(JsonReader reader, JsonProperty property, Dictionary< JsonProperty, JsonSerializerInternalReader.PropertyPresence > requiredProperties)
void OnDeserializing(JsonReader reader, JsonContract contract, object value)
static bool CoerceEmptyStringToNull(Type objectType, JsonContract contract, string s)
JsonArrayContract EnsureArrayContract(JsonReader reader, Type objectType, JsonContract contract)
void HandleError(JsonReader reader, bool readPastError, int initialDepth)
void OnDeserialized(JsonReader reader, JsonContract contract, object value)
object PopulateObject(object newObject, JsonReader reader, JsonObjectContract contract, JsonProperty member, string id)
JToken CreateJObject(JsonReader reader)
JsonContract GetContractSafe(Type type)
object CreateObjectUsingCreatorWithParameters(JsonReader reader, JsonObjectContract contract, JsonProperty containerProperty, ObjectConstructor< object > creator, string id)
void EndProcessProperty(object newObject, JsonReader reader, JsonObjectContract contract, int initialDepth, JsonProperty property, JsonSerializerInternalReader.PropertyPresence presence, bool setDefaultValue)
IList CreateNewList(JsonReader reader, JsonArrayContract contract, [Out] bool createdFromNonDefaultCreator)
static bool ValueEquals(object objA, object objB)
static Type GetObjectType(object v)
static void ArgumentNotNull(object value, string parameterName)
static object ToObject(Type enumType, object value)
static CultureInfo InvariantCulture
readonly StreamingContextStates m_state