System\Text\Json\Serialization\Metadata\JsonTypeInfo.cs (19)
633ThrowHelper.ThrowInvalidOperationException_NoMetadataForTypeProperties(Options.TypeInfoResolver, Type);
771internal JsonNumberHandling EffectiveNumberHandling => _numberHandling ?? Options.NumberHandling;
962Options.MakeReadOnly();
967lock (Options.CacheContext)
998Debug.Assert(Monitor.IsEntered(Options.CacheContext), "Configure called directly, use EnsureConfigured which synchronizes access to this method");
999Debug.Assert(Options.IsReadOnly);
1008PolymorphicTypeResolver = new PolymorphicTypeResolver(Options, PolymorphismOptions, Type, Converter.CanHaveMetadata);
1024_elementTypeInfo ??= Options.GetTypeInfoInternal(ElementType);
1030_keyTypeInfo ??= Options.GetTypeInfoInternal(KeyType);
1053BuildUnionValueTypeMap(UnionCases, Options, this);
1145factory = Options.GetTypeClassifierFromList(ctx);
1150JsonTypeClassifier classifier = factory.CreateJsonClassifier(ctx, Options);
1346if (Options.CanUseFastPathSerializationLogic)
1352return OriginatingResolver.IsCompatibleWithOptions(Options);
1487if (Options.TryGetTypeInfoCached(propertyType, out JsonTypeInfo? jsonTypeInfo))
1492jsonPropertyInfo = jsonTypeInfo.CreateJsonPropertyInfo(declaringTypeInfo: this, declaringType, Options);
1501parameters: new object[] { declaringType ?? Type, this, Options })!;
1552StringComparer comparer = Options.PropertyNameCaseInsensitive ? StringComparer.OrdinalIgnoreCase : StringComparer.Ordinal;
1620? Options.UnmappedMemberHandling
System\Text\Json\Serialization\Metadata\JsonTypeInfoOfT.cs (1)
254Options)
System\Text\Json\Serialization\Metadata\JsonTypeInfoOfT.WriteHelpers.cs (12)
45Options.TryGetPolymorphicTypeInfoForRootType(rootValue, out JsonTypeInfo? derivedTypeInfo))
56bool success = EffectiveConverter.WriteCore(writer, rootValue, Options, ref state);
67PooledByteBufferWriter writer = new PooledByteBufferWriter(Options.DefaultBufferSize, utf8Json);
103Utf8JsonWriter writer = Utf8JsonWriterCache.RentWriter(Options, pipeWriter);
141Options.TryGetPolymorphicTypeInfoForRootType(rootValue, out JsonTypeInfo? derivedTypeInfo))
162var writer = new Utf8JsonWriter(pipeWriter, Options.GetWriterOptions());
172isFinalBlock = EffectiveConverter.WriteCore(writer, rootValue, Options, ref state);
269Utf8JsonWriter writer = Utf8JsonWriterCache.RentWriterAndBuffer(Options, out PooledByteBufferWriter bufferWriter);
291Options.TryGetPolymorphicTypeInfoForRootType(rootValue, out JsonTypeInfo? polymorphicTypeInfo))
305Utf8JsonWriter writer = Utf8JsonWriterCache.RentWriterAndBuffer(Options, out PooledByteBufferWriter bufferWriter);
315isFinalBlock = EffectiveConverter.WriteCore(writer, rootValue, Options, ref state);
375if ((ulong)serializationSize > (ulong)(Options.DefaultBufferSize / 2))