1 instantiation of ContextGenerationSpec
System.Text.Json.SourceGeneration (1)
JsonSourceGenerator.Parser.cs (1)
173ContextGenerationSpec contextGenSpec = new()
24 references to ContextGenerationSpec
System.Text.Json.SourceGeneration (24)
JsonSourceGenerator.Emitter.cs (16)
92public void Emit(ContextGenerationSpec contextGenerationSpec) 129private static SourceWriter CreateSourceWriterWithContextHeader(ContextGenerationSpec contextSpec, bool isPrimaryContextSourceFile = false, string? interfaceImplementation = null) 187private SourceText? GenerateTypeInfo(ContextGenerationSpec contextSpec, TypeGenerationSpec typeGenerationSpec) 225private static SourceText GenerateForTypeWithBuiltInConverter(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 242private static SourceText GenerateForTypeWithCustomConverter(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 263private static SourceText GenerateForNullable(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 284private static SourceText GenerateForUnsupportedType(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 300private static SourceText GenerateForEnum(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 316private SourceText GenerateForCollection(ContextGenerationSpec contextSpec, TypeGenerationSpec typeGenerationSpec) 496private SourceText GenerateForObject(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 613private static SourceText GenerateForUnion(ContextGenerationSpec contextSpec, TypeGenerationSpec typeMetadata) 1426private void GenerateFastPathFuncForObject(SourceWriter writer, ContextGenerationSpec contextSpec, string serializeMethodName, TypeGenerationSpec typeGenSpec) 1770private static SerializedValueCheckType GetCheckType(ContextGenerationSpec contextSpec, PropertyGenerationSpec propertySpec) 1824private static SourceText GetRootJsonContextImplementation(ContextGenerationSpec contextSpec, bool emitGetConverterForNullablePropertyMethod, bool emitValueTypeSetterDelegate) 2113private static SourceText GetGetTypeInfoImplementation(ContextGenerationSpec contextSpec) 2155private SourceText GetPropertyNameInitialization(ContextGenerationSpec contextSpec)
JsonSourceGenerator.Parser.cs (2)
89public ContextGenerationSpec? ParseContextGenerationSpec(ClassDeclarationSyntax contextClassDeclaration, SemanticModel semanticModel, CancellationToken cancellationToken) 173ContextGenerationSpec contextGenSpec = new()
JsonSourceGenerator.Roslyn4.0.cs (5)
34IncrementalValuesProvider<(ContextGenerationSpec?, ImmutableArray<Diagnostic>)> contextGenerationSpecs = context.SyntaxProvider 55ContextGenerationSpec? contextGenerationSpec = parser.ParseContextGenerationSpec(tuple.Left.ContextClass, tuple.Left.SemanticModel, cancellationToken); 76IncrementalValuesProvider<ContextGenerationSpec?> sourceGenerationSpecs = 93private void EmitSource(SourceProductionContext sourceProductionContext, ContextGenerationSpec? contextGenerationSpec) 131public Action<ImmutableArray<ContextGenerationSpec>>? OnSourceEmitting { get; init; }
Model\PropertyGenerationSpec.cs (1)
192public bool ShouldIncludePropertyForFastPath(ContextGenerationSpec contextSpec)