62 if (
state.FlushThreshold > 0)
106 bool flag = reader.TrySkip();
113 reader.ReadWithVerify();
153 if (!
state.IsContinuation)
157 if (
state.SupportContinuation)
160 if (
state.Current.ReturnValue ==
null)
164 return (T)
state.Current.ReturnValue;
205 if (
ex5.Message.Contains(
" Path: "))
216 if (
base.IsValueType)
224 state.ReferenceResolver.PushReferenceForCycleDetection(
value);
249 if (
ex3.Message.Contains(
" Path: "))
320 if (
base.IsInternalConverter)
359 if (
base.IsInternalConverter)
395 if (
state.IsContinuation)
416 return value ==
null;
444 if (
base.CanBePolymorphic)
452 switch (
options.ReferenceHandlingStrategy)
461 state.ReferenceResolver.PushReferenceForCycleDetection(
value);
469 state.ReferenceResolver.PopReferenceForCycleDetection();
489 state.ReferenceResolver.PopReferenceForCycleDetection();
507 state.ReferenceResolver.PopReferenceForCycleDetection();
514 if (!
base.IsInternalConverter)
553 else if (depth != reader.CurrentDepth)
563 else if (depth != reader.CurrentDepth)
static string NodeJsonObjectCustomConverterNotAllowedOnExtensionProperty
static bool TryGetReferenceFromJsonElement(ref ReadStack state, JsonElement element, out object referenceValue)
static bool TryWriteReferenceForBoxedStruct(object currentValue, ref WriteStack state, Utf8JsonWriter writer)
virtual bool OnTryRead(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options, ref ReadStack state, out T value)
bool TryWriteDataExtensionProperty(Utf8JsonWriter writer, T value, JsonSerializerOptions options, ref WriteStack state)
virtual bool ConstructorIsParameterized
bool ShouldFlush(Utf8JsonWriter writer, ref WriteStack state)
void VerifyWrite(int originalDepth, Utf8JsonWriter writer)
virtual void CreateInstanceForReferenceResolver(ref Utf8JsonReader reader, ref ReadStack state, JsonSerializerOptions options)
static bool SingleValueReadWithReadAhead(ConverterStrategy converterStrategy, ref Utf8JsonReader reader, ref ReadStack state)
override bool TryWriteAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, ref WriteStack state)
virtual bool OnTryWrite(Utf8JsonWriter writer, T value, JsonSerializerOptions options, ref WriteStack state)
virtual T ReadAsPropertyName(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
bool TryWrite(Utf8JsonWriter writer, in T value, JsonSerializerOptions options, ref WriteStack state)
JsonPropertyInfo CreateJsonPropertyInfo()
override JsonPropertyInfo CreateJsonPropertyInfo()
virtual bool RequiresDynamicMemberAccessors
virtual T ReadAsPropertyNameCore(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
override object ReadCoreAsObject(ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state)
bool TryRead(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options, ref ReadStack state, out T value)
void VerifyRead(JsonTokenType tokenType, int depth, long bytesConsumed, bool isValueConverter, ref Utf8JsonReader reader)
override bool WriteCoreAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, ref WriteStack state)
void WriteAsPropertyNameCoreAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, bool isWritingExtensionDataProperty)
object ReadCoreAsObject(ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state)
static bool DoSingleValueReadWithReadAhead(ref Utf8JsonReader reader, ref ReadStack state)
bool WriteCoreAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, ref WriteStack state)
T ReadCore(ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state)
virtual void WriteAsPropertyNameCore(Utf8JsonWriter writer, T value, JsonSerializerOptions options, bool isWritingExtensionDataProperty)
bool IsInternalConverterForNumberType
static bool IsNull(T value)
bool TryWriteAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, ref WriteStack state)
bool TryReadAsObject(ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state, out object value)
virtual void WriteAsPropertyName(Utf8JsonWriter writer, T value, JsonSerializerOptions options)
virtual bool CanHaveIdMetadata
override void WriteAsPropertyNameCoreAsObject(Utf8JsonWriter writer, object value, JsonSerializerOptions options, bool isWritingExtensionDataProperty)
virtual object CreateObject(JsonSerializerOptions options)
virtual void Initialize(JsonSerializerOptions options, JsonTypeInfo jsonTypeInfo=null)
virtual void WriteNumberWithCustomHandling(Utf8JsonWriter writer, T value, JsonNumberHandling handling)
override bool CanConvert(Type typeToConvert)
virtual void ReadElementAndSetProperty(object obj, string propertyName, ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state)
override bool TryReadAsObject(ref Utf8JsonReader reader, JsonSerializerOptions options, ref ReadStack state, out object value)
override JsonParameterInfo CreateJsonParameterInfo()
JsonParameterInfo CreateJsonParameterInfo()
virtual T ReadNumberWithCustomHandling(ref Utf8JsonReader reader, JsonNumberHandling handling, JsonSerializerOptions options)
bool WriteCore(Utf8JsonWriter writer, in T value, JsonSerializerOptions options, ref WriteStack state)
bool CanConvert(Type typeToConvert)
bool CanUseDirectReadOrWrite
T? Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
void Write(Utf8JsonWriter writer, T value, JsonSerializerOptions options)
static readonly Type ObjectType
virtual void PushReferenceForCycleDetection(object value)
static void ThrowJsonException_SerializerCycleDetected(int maxDepth)
static void ThrowJsonException_SerializationConverterRead(JsonConverter converter)
static void ThrowNotSupportedException(ref ReadStack state, in Utf8JsonReader reader, NotSupportedException ex)
static void ThrowJsonException_DeserializeUnableToConvertValue(Type propertyType)
static void ThrowNotSupportedException_DictionaryKeyTypeNotSupported(Type keyType, JsonConverter converter)
static void AddJsonExceptionInformation(ref ReadStack state, in Utf8JsonReader reader, JsonException ex)
static void ReThrowWithPath(ref ReadStack state, JsonReaderException ex)
static void ThrowJsonException_SerializationConverterWrite(JsonConverter converter)
static ? Type GetType(string typeName, bool throwOnError, bool ignoreCase)
ReferenceHandlingStrategy
static ? Type GetUnderlyingType(Type nullableType)