System\Text\Json\Serialization\Metadata\JsonTypeInfo.cs (47)
75/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
106/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
136/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
166/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
202/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
288/// <paramref name="value" /> has been associated with a different <see cref="JsonTypeInfo"/> instance.
291/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
340/// A <see cref="JsonTypeInfo"/> instance can be locked either if
390private readonly JsonTypeInfo _parent;
392public JsonUnionCaseInfoList(JsonTypeInfo parent, IEnumerable<JsonUnionCaseInfo>? source = null) : base(source)
458/// <c>CaseValue</c> using the <see cref="JsonTypeInfo"/> registered for that case
628internal JsonTypeInfo? ElementTypeInfo
638JsonTypeInfo? elementTypeInfo = _elementTypeInfo;
654internal JsonTypeInfo? KeyTypeInfo
664JsonTypeInfo? keyTypeInfo = _keyTypeInfo;
676private JsonTypeInfo? _elementTypeInfo;
677private JsonTypeInfo? _keyTypeInfo;
680/// Gets the <see cref="JsonSerializerOptions"/> value associated with the current <see cref="JsonTypeInfo" /> instance.
695/// As such, the value of the converter cannot be changed once a <see cref="JsonTypeInfo"/> instance has been created.
715/// Dummy <see cref="JsonPropertyInfo"/> instance corresponding to the declaring type of this <see cref="JsonTypeInfo"/>.
733/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
765/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
805/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
843/// The <see cref="JsonTypeInfo"/> instance has been locked for further modification.
1039/// Validates that a union <see cref="JsonTypeInfo"/> has a well-formed shape after
1157/// This helper operates purely on already-resolved <see cref="JsonTypeInfo"/> /
1162private static void BuildUnionValueTypeMap(IList<JsonUnionCaseInfo> unionCases, JsonSerializerOptions options, JsonTypeInfo target)
1170JsonTypeInfo caseTypeInfo = options.GetTypeInfoInternal(caseType);
1226internal JsonTypeInfo? AncestorPolymorphicType
1243private JsonTypeInfo? _ancestorPolymorhicType;
1343/// which constrains the type of metadata that can be modified in the <see cref="JsonTypeInfo"/> instance.
1356/// Creates a blank <see cref="JsonTypeInfo"/> instance.
1360/// <returns>A blank <see cref="JsonTypeInfo"/> instance.</returns>
1364/// The returned <see cref="JsonTypeInfo"/> will be blank, with the exception of the
1371/// which constrains the type of metadata that can be modified in the <see cref="JsonTypeInfo"/> instance.
1375public static JsonTypeInfo CreateJsonTypeInfo(Type type, JsonSerializerOptions options)
1391internal static JsonTypeInfo CreateJsonTypeInfo(Type type, JsonConverter converter, JsonSerializerOptions options)
1393JsonTypeInfo jsonTypeInfo;
1404jsonTypeInfo = (JsonTypeInfo)jsonTypeInfoType.CreateInstanceNoWrapExceptions(
1414/// Creates a blank <see cref="JsonPropertyInfo"/> instance for the current <see cref="JsonTypeInfo"/>.
1421/// <exception cref="InvalidOperationException">The <see cref="JsonTypeInfo"/> instance has been locked for further modification.</exception>
1447if (Options.TryGetTypeInfoCached(propertyType, out JsonTypeInfo? jsonTypeInfo))
1460parameterTypes: [typeof(Type), typeof(JsonTypeInfo), typeof(JsonSerializerOptions)],
1471private protected abstract JsonPropertyInfo CreateJsonPropertyInfo(JsonTypeInfo declaringTypeInfo, Type? declaringType, JsonSerializerOptions options);
1753(propertyType.FullName == JsonObjectTypeName && ReferenceEquals(propertyType.Assembly, typeof(JsonTypeInfo).Assembly));
1787private readonly JsonTypeInfo _jsonTypeInfo;
1789public JsonPropertyInfoList(JsonTypeInfo jsonTypeInfo)
System\Text\Json\Serialization\Metadata\ReflectionEmitMemberAccessor.cs (7)
38JsonTypeInfo.ObjectType,
176public override JsonTypeInfo.ParameterizedConstructorDelegate<T, TArg0, TArg1, TArg2, TArg3>?
178CreateDelegate<JsonTypeInfo.ParameterizedConstructorDelegate<T, TArg0, TArg1, TArg2, TArg3>>(
201new[] { JsonTypeInfo.ObjectType },
347new[] { collectionType, JsonTypeInfo.ObjectType },
700new[] { JsonTypeInfo.ObjectType },
716new[] { JsonTypeInfo.ObjectType, memberType },