14 references to SerializedValueCheckType
System.Text.Json.SourceGeneration (14)
JsonSourceGenerator.Emitter.cs (14)
1559SerializedValueCheckType defaultCheckType = GetCheckType(contextSpec, propertyGenSpec); 1571if (defaultCheckType != SerializedValueCheckType.None) 1585case SerializedValueCheckType.Ignore: 1588case SerializedValueCheckType.IgnoreWhenNull: 1599case SerializedValueCheckType.IgnoreWhenDefault: 1610case SerializedValueCheckType.DisallowNull: 1861private static SerializedValueCheckType GetCheckType(ContextGenerationSpec contextSpec, PropertyGenerationSpec propertySpec) 1865JsonIgnoreCondition.WhenWriting => SerializedValueCheckType.Ignore, 1866JsonIgnoreCondition.WhenWritingNull => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.None, 1867JsonIgnoreCondition.WhenWritingDefault => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.IgnoreWhenDefault, 1868_ when propertySpec.IsGetterNonNullableAnnotation && contextSpec.GeneratedOptionsSpec?.RespectNullableAnnotations is true => SerializedValueCheckType.DisallowNull, 1869_ => SerializedValueCheckType.None,