23 references to JsonIgnoreCondition
System.Text.Json.SourceGeneration (23)
JsonSourceGenerator.Emitter.cs (7)
619{ DefaultIgnoreCondition: JsonIgnoreCondition.Always } => "null", 628{ DefaultIgnoreCondition: JsonIgnoreCondition.Always } => "null", 1066JsonIgnoreCondition.WhenWriting => SerializedValueCheckType.Ignore, 1067JsonIgnoreCondition.WhenWritingNull => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.None, 1068JsonIgnoreCondition.WhenWritingDefault => propertySpec.PropertyType.CanBeNull ? SerializedValueCheckType.IgnoreWhenNull : SerializedValueCheckType.IgnoreWhenDefault, 1215if (optionsSpec.DefaultIgnoreCondition is JsonIgnoreCondition defaultIgnoreCondition) 1455private static string FormatIgnoreCondition(JsonIgnoreCondition ignoreCondition)
JsonSourceGenerator.Parser.cs (11)
269JsonIgnoreCondition? defaultIgnoreCondition = null; 328defaultIgnoreCondition = (JsonIgnoreCondition)namedArg.Value.Value!; 1060if (other.DefaultIgnoreCondition == JsonIgnoreCondition.Always) 1071propertySpec.DefaultIgnoreCondition == JsonIgnoreCondition.Always || 1088if (propertySpec.DefaultIgnoreCondition == JsonIgnoreCondition.Always) 1129out JsonIgnoreCondition? ignoreCondition, 1183if (ignoreCondition is not JsonIgnoreCondition.Always) 1195TypeRef propertyTypeRef = ignoreCondition != JsonIgnoreCondition.Always 1234out JsonIgnoreCondition? ignoreCondition, 1277ignoreCondition = JsonIgnoreCondition.Always; 1282ignoreCondition = (JsonIgnoreCondition)namedArgs[0].Value.Value!;
Model\PropertyGenerationSpec.cs (3)
111/// The <see cref="JsonIgnoreCondition"/> for the property. 113public required JsonIgnoreCondition? DefaultIgnoreCondition { get; init; } 161if (DefaultIgnoreCondition is JsonIgnoreCondition.Always)
Model\SourceGenerationOptionsSpec.cs (1)
27public required JsonIgnoreCondition? DefaultIgnoreCondition { get; init; }
src\libraries\System.Text.Json\Common\JsonSourceGenerationOptionsAttribute.cs (1)
66public JsonIgnoreCondition DefaultIgnoreCondition { get; set; }