20 references to CodeGenerator
Microsoft.CodeAnalysis.CodeStyle.Fixes (20)
src\Analyzers\Core\CodeFixes\GenerateConstructor\AbstractGenerateConstructorService.State.cs (3)
114if (!CodeGenerator.CanAdd(_document.Project.Solution, TypeToGenerateIn, cancellationToken)) 457return await CodeGenerator.AddMemberDeclarationsAsync( 498return await CodeGenerator.AddMemberDeclarationsAsync(
src\Analyzers\Core\CodeFixes\GenerateDefaultConstructors\GenerateDefaultConstructorsCodeAction.cs (1)
40var result = await CodeGenerator.AddMemberDeclarationsAsync(
src\Analyzers\Core\CodeFixes\GenerateEnumMember\AbstractGenerateEnumMemberService.State.cs (1)
71return CodeGenerator.CanAdd(document.Project.Solution, TypeToGenerateIn, cancellationToken);
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\AbstractGenerateParameterizedMemberService.CodeAction.cs (2)
73var result = await CodeGenerator.AddPropertyDeclarationAsync( 89var result = await CodeGenerator.AddMethodDeclarationAsync(
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\AbstractGenerateParameterizedMemberService.State.cs (1)
72if (!CodeGenerator.CanAdd(document.Project.Solution, TypeToGenerateIn, cancellationToken))
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.CodeAction.cs (2)
87return await CodeGenerator.AddPropertyDeclarationAsync( 101return await CodeGenerator.AddFieldDeclarationAsync(
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.cs (1)
47var canGenerateMember = CodeGenerator.CanAdd(document.Project.Solution, state.TypeToGenerateIn, cancellationToken);
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
162return CanGenerateLocal() || CodeGenerator.CanAdd(_document.Project.Solution, TypeToGenerateIn, cancellationToken);
src\Analyzers\Core\CodeFixes\ImplementAbstractClass\ImplementAbstractClassData.cs (1)
60if (!CodeGenerator.CanAdd(document.Project.Solution, classType, cancellationToken))
src\Analyzers\Core\CodeFixes\ImplementInterface\AbstractImplementInterfaceService.State.cs (1)
55if (!CodeGenerator.CanAdd(document.Project.Solution, classOrStructType, cancellationToken))
src\Analyzers\Core\CodeFixes\ImplementInterface\ImplementInterfaceGenerator.cs (1)
94return await CodeGenerator.AddMemberDeclarationsAsync(
src\Analyzers\Core\CodeFixes\ImplementInterface\ImplementInterfaceGenerator_DisposePattern.cs (2)
68var firstGeneratedMember = rootWithCoreMembers.GetAnnotatedNodes(CodeGenerator.Annotation).First(); 99var lastGeneratedMember = root.GetAnnotatedNodes(CodeGenerator.Annotation)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\CodeGenerationContext.cs (1)
16/// General options for controlling the code produced by the <see cref="CodeGenerator"/> that apply to all documents.
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\CodeGenerationHelpers.cs (1)
44=> node.WithAdditionalAnnotations(Formatter.Annotation, CodeGenerator.Annotation);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\CodeGenerator.cs (1)
21public static readonly SyntaxAnnotation Annotation = new(nameof(CodeGenerator));