14 references to SerializedValueCheckType
System.Text.Json.SourceGeneration (14)
JsonSourceGenerator.Emitter.cs (14)
1367SerializedValueCheckType defaultCheckType = GetCheckType(contextSpec, propertyGenSpec); 1379if (defaultCheckType != SerializedValueCheckType.None) 1393case SerializedValueCheckType.Ignore: 1396case SerializedValueCheckType.IgnoreWhenNull: 1407case SerializedValueCheckType.IgnoreWhenDefault: 1418case SerializedValueCheckType.DisallowNull: 1660private static SerializedValueCheckType GetCheckType(ContextGenerationSpec contextSpec, PropertyGenerationSpec propertySpec) 1664JsonIgnoreCondition.WhenWriting => SerializedValueCheckType.Ignore, 1665JsonIgnoreCondition.WhenWritingNull => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.None, 1666JsonIgnoreCondition.WhenWritingDefault => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.IgnoreWhenDefault, 1667_ when propertySpec.IsGetterNonNullableAnnotation && contextSpec.GeneratedOptionsSpec?.RespectNullableAnnotations is true => SerializedValueCheckType.DisallowNull, 1668_ => SerializedValueCheckType.None,