455 references to FixAllScope
BuildActionTelemetryTable (7)
src\Workspaces\Core\Portable\Shared\Extensions\TelemetryExtensions.cs (7)
41public static short GetScopeIdForTelemetry(this FixAllScope scope) 44FixAllScope.Document => 1, 45FixAllScope.Project => 2, 46FixAllScope.Solution => 3, 47FixAllScope.Custom => 4, 48FixAllScope.ContainingMember => 5, 49FixAllScope.ContainingType => 6,
GenerateDocumentationAndConfigFiles (32)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.Analyzers.Extra.Tests (1)
Resources\RoslynTestUtils.cs (1)
444scope: FixAllScope.Project,
Microsoft.Analyzers.Local.Tests (1)
Resources\RoslynTestUtils.cs (1)
445scope: FixAllScope.Project,
Microsoft.CodeAnalysis.Analyzers (42)
MetaAnalyzers\Fixers\AnalyzerReleaseTrackingFix.FixAllProvider.cs (5)
31case FixAllScope.Document: 38case FixAllScope.Project: 46case FixAllScope.Solution: 57case FixAllScope.Custom: 79public FixAllAdditionalDocumentChangeAction(FixAllScope fixAllScope, Solution solution, List<KeyValuePair<Project, ImmutableArray<Diagnostic>>> diagnosticsToFix, string? equivalenceKey)
MetaAnalyzers\Fixers\DefineDiagnosticDescriptorArgumentsCorrectlyFix.CustomFixAllProvider.cs (5)
44case FixAllScope.Document: 51case FixAllScope.Project: 59case FixAllScope.Solution: 70case FixAllScope.Custom: 86public FixAllAdditionalDocumentChangeAction(FixAllScope fixAllScope, Solution solution, List<KeyValuePair<Project, ImmutableArray<Diagnostic>>> diagnosticsToFix, string equivalenceKey)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.CodeAnalysis.BannedApiAnalyzers (32)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.CodeAnalysis.CodeStyle.Fixes (35)
src\Analyzers\Core\CodeFixes\MatchFolderAndNamespace\AbstractChangeNamespaceToMatchFolderCodeFixProvider.CustomFixAllProvider.cs (3)
32FixAllScope.Document when fixAllContext.Document is not null => await fixAllContext.GetDocumentDiagnosticsAsync(fixAllContext.Document).ConfigureAwait(false), 33FixAllScope.Project => await fixAllContext.GetAllDiagnosticsAsync(fixAllContext.Project).ConfigureAwait(false), 34FixAllScope.Solution => await GetSolutionDiagnosticsAsync(fixAllContext).ConfigureAwait(false),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (4)
Formatting\CodeCleanupTests.TestFixers.cs (4)
132public override IEnumerable<FixAllScope> GetSupportedFixAllScopes() 133=> [FixAllScope.Project, FixAllScope.Solution, FixAllScope.Custom];
Microsoft.CodeAnalysis.CSharp.Features (1)
ConvertToExtension\ConvertToExtensionFixAllProvider.cs (1)
20using FixAllScope = CodeAnalysis.CodeFixes.FixAllScope;
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (4)
AddFileBanner\AddFileBannerTests_FixAll.cs (4)
299[InlineData(FixAllScope.ContainingMember)] 300[InlineData(FixAllScope.ContainingType)] 301[InlineData(FixAllScope.Document)] 302public async Task FixAllScopes_NotApplicable(FixAllScope fixAllScope)
Microsoft.CodeAnalysis.ExternalAccess.OmniSharp (1)
CodeActions\OmniSharpCodeFixContextFactory.cs (1)
37FixAllScope scope,
Microsoft.CodeAnalysis.Features (20)
CodeFixes\CodeFixCollection.cs (2)
20ImmutableArray<FixAllScope> supportedScopes, 31public ImmutableArray<FixAllScope> SupportedScopes { get; } = supportedScopes.NullToEmpty();
CodeFixes\Service\CodeFixService.cs (3)
318if (collection.FixAllState is not null && collection.SupportedScopes.Contains(FixAllScope.Document)) 807var supportedScopes = ImmutableArray<FixAllScope>.Empty; 823FixAllScope.Document,
CodeFixes\Suppression\AbstractSuppressionCodeFixProvider.FixAllProvider.cs (6)
23public override IEnumerable<FixAllScope> GetSupportedFixAllScopes() 24=> [FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
CodeFixesAndRefactorings\AbstractFixAllCodeAction.cs (5)
58FixAllScope.Document => FeaturesResources.Document, 59FixAllScope.Project => FeaturesResources.Project, 60FixAllScope.Solution => FeaturesResources.Solution, 61FixAllScope.ContainingMember => FeaturesResources.Containing_Member, 62FixAllScope.ContainingType => FeaturesResources.Containing_Type,
src\Analyzers\Core\CodeFixes\MatchFolderAndNamespace\AbstractChangeNamespaceToMatchFolderCodeFixProvider.CustomFixAllProvider.cs (3)
32FixAllScope.Document when fixAllContext.Document is not null => await fixAllContext.GetDocumentDiagnosticsAsync(fixAllContext.Document).ConfigureAwait(false), 33FixAllScope.Project => await fixAllContext.GetAllDiagnosticsAsync(fixAllContext.Project).ConfigureAwait(false), 34FixAllScope.Solution => await GetSolutionDiagnosticsAsync(fixAllContext).ConfigureAwait(false),
SyncNamespaces\AbstractSyncNamespacesService.cs (1)
128FixAllScope.Solution,
Microsoft.CodeAnalysis.LanguageServer.Protocol (7)
Features\Suggestions\UnifiedSuggestedActionsSource.cs (7)
206ImmutableArray<FixAllScope> supportedScopes, 221foreach (var scope in supportedScopes) 223if (scope is FixAllScope.ContainingMember or FixAllScope.ContainingType) 577foreach (var scope in fixAllProviderInfo.SupportedScopes) 583if (scope is FixAllScope.ContainingMember or FixAllScope.ContainingType)
Microsoft.CodeAnalysis.PerformanceSensitiveAnalyzers (32)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.CodeAnalysis.PublicApiAnalyzers.CodeFixes (12)
AnnotatePublicApiFix.cs (4)
207case FixAllScope.Document: 216case FixAllScope.Project: 225case FixAllScope.Solution: 237case FixAllScope.Custom:
DeclarePublicApiFix.cs (4)
358case FixAllScope.Document: 367case FixAllScope.Project: 376case FixAllScope.Solution: 388case FixAllScope.Custom:
NullableEnablePublicApiFix.cs (4)
127case FixAllScope.Document: 128case FixAllScope.Project: 135case FixAllScope.Solution: 150case FixAllScope.Custom:
Microsoft.CodeAnalysis.Workspaces (141)
CodeActions\CodeAction.cs (2)
211internal Guid GetTelemetryId(FixAllScope? fixAllScope = null) 590/// This is used in <see cref="GetTelemetryId(FixAllScope?)"/> to determine the appropriate type
CodeFixes\FixAllOccurrences\BatchFixAllProvider.cs (10)
30public override IEnumerable<FixAllScope> GetSupportedFixAllScopes() 31=> [FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType]; 56Contract.ThrowIfFalse(fixAllContext.Scope is FixAllScope.Document or 57FixAllScope.Project or FixAllScope.ContainingMember or FixAllScope.ContainingType);
CodeFixes\FixAllOccurrences\DocumentBasedFixAllProvider.cs (3)
27public abstract class DocumentBasedFixAllProvider(ImmutableArray<FixAllScope> supportedFixAllScopes) : FixAllProvider 29private readonly ImmutableArray<FixAllScope> _supportedFixAllScopes = supportedFixAllScopes; 59public sealed override IEnumerable<FixAllScope> GetSupportedFixAllScopes()
CodeFixes\FixAllOccurrences\FixAllContext.cs (18)
47/// <see cref="FixAllScope"/> to fix all occurrences. 49public FixAllScope Scope => State.Scope; 83Optional<FixAllScope> scope, 93/// This overload cannot be used with <see cref="FixAllScope.ContainingMember"/> or 94/// <see cref="FixAllScope.ContainingType"/> value for the <paramref name="scope"/>. 102/// <param name="scope"><see cref="FixAllScope"/> to fix all occurrences.</param> 112FixAllScope scope, 122if (scope is FixAllScope.ContainingMember or FixAllScope.ContainingType) 132/// using <see cref="FixAllScope.ContainingMember"/> or <see cref="FixAllScope.ContainingType"/> 139/// <param name="scope"><see cref="FixAllScope"/> to fix all occurrences.</param> 150FixAllScope scope, 175/// <param name="scope"><see cref="FixAllScope"/> to fix all occurrences.</param> 185FixAllScope scope, 202if (scope is FixAllScope.ContainingMember or FixAllScope.ContainingType) 332Optional<FixAllScope> scope = default,
CodeFixes\FixAllOccurrences\FixAllContext.DiagnosticProvider.cs (2)
80case FixAllScope.Project: 84case FixAllScope.Solution:
CodeFixes\FixAllOccurrences\FixAllContext.SpanBasedDiagnosticProvider.cs (2)
21/// We need to compute diagnostics for a span when applying a fix all operation in <see cref="FixAllScope.ContainingMember"/> 22/// and <see cref="FixAllScope.ContainingType"/> scopes.
CodeFixes\FixAllOccurrences\FixAllProvider.cs (11)
21private protected static ImmutableArray<FixAllScope> DefaultSupportedFixAllScopes 22= [FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution]; 24public virtual IEnumerable<FixAllScope> GetSupportedFixAllScopes() 70/// Supported <see cref="FixAllScope"/>s for the fix all provider. 71/// Note that <see cref="FixAllScope.Custom"/> is not supported by the <see cref="DocumentBasedFixAllProvider"/> 76ImmutableArray<FixAllScope> supportedFixAllScopes) 83ImmutableArray<FixAllScope> supportedFixAllScopes, 92if (supportedFixAllScopes.Contains(FixAllScope.Custom)) 105ImmutableArray<FixAllScope> supportedFixAllScopes,
CodeFixes\FixAllOccurrences\FixAllState.cs (6)
32FixAllScope scope, 39Debug.Assert(diagnosticSpan.HasValue || scope is not FixAllScope.ContainingMember or FixAllScope.ContainingType); 48protected override FixAllState With(Document? document, Project project, FixAllScope scope, string? codeActionEquivalenceKey) 78FixAllScope.Custom, 99FixAllScope.Custom,
CodeFixes\FixAllOccurrences\WellKnownFixAllProviders.cs (5)
19/// <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/>, <see cref="FixAllScope.Solution"/> 20/// <see cref="FixAllScope.ContainingMember"/> and <see cref="FixAllScope.ContainingType"/>.
CodeFixesAndRefactorings\CommonFixAllState.cs (6)
24public FixAllScope Scope { get; } 32FixAllScope scope, 45protected abstract TFixAllState With(Document? document, Project project, FixAllScope scope, string? codeActionEquivalenceKey); 49Optional<FixAllScope> scope = default, 53var newScope = scope.HasValue ? scope.Value : Scope; 74Optional<FixAllScope> scope,
CodeFixesAndRefactorings\DefaultFixAllProviderHelpers.cs (6)
36FixAllScope.Document or FixAllScope.ContainingMember or FixAllScope.ContainingType 38FixAllScope.Project => await GetProjectFixesAsync(fixAllContext, fixAllContextsAsync).ConfigureAwait(false), 39FixAllScope.Solution => await GetSolutionFixesAsync(fixAllContext, fixAllContextsAsync).ConfigureAwait(false), 87sortedProjects.SelectAsArray(p => (TFixAllContext)fixAllContext.With((document: null, project: p), scope: FixAllScope.Project)));
CodeFixesAndRefactorings\DocumentBasedFixAllProviderHelpers.cs (4)
77fixAllContext.State.Scope is FixAllScope.Document or FixAllScope.Project or FixAllScope.ContainingMember or FixAllScope.ContainingType);
CodeFixesAndRefactorings\FixAllLogger.cs (2)
81case CodeFixes.FixAllScope.Project: 85case CodeFixes.FixAllScope.Solution:
CodeFixesAndRefactorings\FixAllProviderInfo.cs (5)
14/// Contains computed information for a given <see cref="FixAllProvider"/>, such as supported diagnostic Ids and supported <see cref="FixAllScope"/>. 19public readonly ImmutableArray<FixAllScope> SupportedScopes; 23ImmutableArray<FixAllScope> supportedScopes) 103ImmutableArray<FixAllScope> supportedScopes) : FixAllProviderInfo(fixAllProvider, supportedScopes) 112ImmutableArray<FixAllScope> supportedScopes)
CodeFixesAndRefactorings\IRefactorOrFixAllContext.cs (1)
25Optional<FixAllScope> scope = default,
CodeFixesAndRefactorings\IRefactorOrFixAllState.cs (2)
18FixAllScope Scope { get; } 31Optional<FixAllScope> scope = default,
CodeRefactorings\FixAllOccurences\RefactorAllContext.cs (1)
72Optional<FixAllScope> scope,
CodeRefactorings\FixAllOccurences\RefactorAllScope.cs (15)
61var fixAllFields = typeof(FixAllScope) 69public static FixAllScope ToFixAllScope(this RefactorAllScope scope) 72RefactorAllScope.Document => FixAllScope.Document, 73RefactorAllScope.Project => FixAllScope.Project, 74RefactorAllScope.Solution => FixAllScope.Solution, 75RefactorAllScope.Custom => FixAllScope.Custom, 76RefactorAllScope.ContainingMember => FixAllScope.ContainingMember, 77RefactorAllScope.ContainingType => FixAllScope.ContainingType, 81public static RefactorAllScope ToRefactorAllScope(this FixAllScope scope) 84FixAllScope.Document => RefactorAllScope.Document, 85FixAllScope.Project => RefactorAllScope.Project, 86FixAllScope.Solution => RefactorAllScope.Solution, 87FixAllScope.Custom => RefactorAllScope.Custom, 88FixAllScope.ContainingMember => RefactorAllScope.ContainingMember, 89FixAllScope.ContainingType => RefactorAllScope.ContainingType,
CodeRefactorings\FixAllOccurences\RefactorAllState.cs (1)
72protected override RefactorAllState With(Document? document, Project project, FixAllScope scope, string? codeActionEquivalenceKey)
Shared\Extensions\TelemetryExtensions.cs (7)
41public static short GetScopeIdForTelemetry(this FixAllScope scope) 44FixAllScope.Document => 1, 45FixAllScope.Project => 2, 46FixAllScope.Solution => 3, 47FixAllScope.Custom => 4, 48FixAllScope.ContainingMember => 5, 49FixAllScope.ContainingType => 6,
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Microsoft.Interop.ComInterfaceGenerator (8)
src\libraries\System.Runtime.InteropServices\gen\Common\FixAllContextExtensions.cs (8)
19case FixAllScope.Document: 21case FixAllScope.Project: 23case FixAllScope.Solution: 52case FixAllScope.ContainingMember: 53case FixAllScope.ContainingType: 54case FixAllScope.Document: 55case FixAllScope.Project: 57case FixAllScope.Solution:
Microsoft.Interop.LibraryImportGenerator (11)
Analyzers\CustomMarshallerAttributeFixer.cs (3)
91case FixAllScope.Document: 93case FixAllScope.Project: 95case FixAllScope.Solution:
src\libraries\System.Runtime.InteropServices\gen\Common\FixAllContextExtensions.cs (8)
19case FixAllScope.Document: 21case FixAllScope.Project: 23case FixAllScope.Solution: 52case FixAllScope.ContainingMember: 53case FixAllScope.ContainingType: 54case FixAllScope.Document: 55case FixAllScope.Project: 57case FixAllScope.Solution:
Roslyn.Diagnostics.Analyzers (32)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);
Text.Analyzers (32)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\FixAllContextHelper.cs (5)
36case FixAllScope.Document: 46case FixAllScope.ContainingMember or FixAllScope.ContainingType: 66case FixAllScope.Project: 70case FixAllScope.Solution:
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (6)
19private static readonly ImmutableArray<FixAllScope> s_defaultSupportedFixAllScopes = 20[FixAllScope.Document, FixAllScope.Project, FixAllScope.Solution, FixAllScope.ContainingMember, FixAllScope.ContainingType];
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (4)
24Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken) 26Contract.ThrowIfFalse(fixAllScope is FixAllScope.ContainingMember or FixAllScope.ContainingType); 28var fixAllInContainingMember = fixAllScope == FixAllScope.ContainingMember;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\FixAllHelper.cs (8)
5using FixAllScope = Microsoft.CodeAnalysis.CodeFixes.FixAllScope; 12FixAllScope fixAllScope, 19FixAllScope.Custom => string.Format(WorkspaceExtensionsResources.Fix_all_0, title), 20FixAllScope.Document => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerDocument.Name), 21FixAllScope.Project => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_1, title, triggerProject.Name), 22FixAllScope.Solution => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Solution, title), 23FixAllScope.ContainingMember => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_member, title), 24FixAllScope.ContainingType => string.Format(WorkspaceExtensionsResources.Fix_all_0_in_Containing_type, title),
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\IFixAllSpanMappingService.cs (9)
15/// Language service for mapping spans for specific <see cref="FixAllScope"/>s for fix all occurrences code fix. 16/// Every language that wants to support span based FixAll scopes, such as <see cref="FixAllScope.ContainingMember"/>, 17/// <see cref="FixAllScope.ContainingType"/>, should implement this language service. Non-span based FixAll scopes, 18/// such as <see cref="FixAllScope.Document"/>, <see cref="FixAllScope.Project"/> and <see cref="FixAllScope.Solution"/> 27/// Note that this API is only invoked for span based FixAll scopes, i.e. <see cref="FixAllScope.ContainingMember"/> 28/// and <see cref="FixAllScope.ContainingType"/>. 31Document document, TextSpan triggerSpan, FixAllScope fixAllScope, CancellationToken cancellationToken);