14 references to SerializedValueCheckType
System.Text.Json.SourceGeneration (14)
JsonSourceGenerator.Emitter.cs (14)
1661SerializedValueCheckType defaultCheckType = GetCheckType(contextSpec, propertyGenSpec); 1673if (defaultCheckType != SerializedValueCheckType.None) 1687case SerializedValueCheckType.Ignore: 1690case SerializedValueCheckType.IgnoreWhenNull: 1701case SerializedValueCheckType.IgnoreWhenDefault: 1712case SerializedValueCheckType.DisallowNull: 1963private static SerializedValueCheckType GetCheckType(ContextGenerationSpec contextSpec, PropertyGenerationSpec propertySpec) 1967JsonIgnoreCondition.WhenWriting => SerializedValueCheckType.Ignore, 1968JsonIgnoreCondition.WhenWritingNull => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.None, 1969JsonIgnoreCondition.WhenWritingDefault => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.IgnoreWhenDefault, 1970_ when propertySpec.IsGetterNonNullableAnnotation && contextSpec.GeneratedOptionsSpec?.RespectNullableAnnotations is true => SerializedValueCheckType.DisallowNull, 1971_ => SerializedValueCheckType.None,