92 references to DocumentIds
AnalyzerRunner (3)
DiagnosticAnalyzerRunner.cs (2)
113foreach (var documentId in project.DocumentIds) 154Console.WriteLine($"{project.Name} ({project.DocumentIds.Count} documents): {averageEditsInProject:0.00} edits per second");
Program.cs (1)
179Console.WriteLine("Number of documents:\t\t" + projects.Sum(x => x.DocumentIds.Count));
IdeCoreBenchmarks (2)
ProjectOperationBenchmarks.cs (2)
84foreach (var _ in Project.DocumentIds) 108var documentId = Project.DocumentIds.FirstOrDefault();
Microsoft.Analyzers.Extra.Tests (1)
Resources\RoslynTestUtils.cs (1)
494foreach (var documentId in project.DocumentIds)
Microsoft.Analyzers.Local.Tests (1)
Resources\RoslynTestUtils.cs (1)
495foreach (var documentId in project.DocumentIds)
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (2)
DocumentTracking\FirstDocumentIsActiveAndVisibleDocumentTrackingService.cs (1)
26=> _workspace.CurrentSolution.Projects.First().DocumentIds.First();
NavigateTo\AbstractNavigateToTests.cs (1)
247=> ImmutableArray.Create(_workspace.CurrentSolution.Projects.First().DocumentIds.First());
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (3)
Preview\PreviewWorkspaceTests.cs (3)
77Assert.Equal(1, previewWorkspace.CurrentSolution.Projects.First().DocumentIds.Count); 86.RemoveDocument(previewWorkspace.CurrentSolution.Projects.First().DocumentIds[0]).Solution; 90Assert.Equal(0, previewWorkspace.CurrentSolution.Projects.First().DocumentIds.Count);
Microsoft.CodeAnalysis.Features (7)
DesignerAttribute\DesignerAttributeDiscoveryService.cs (1)
237foreach (var documentId in project.DocumentIds)
ExternalAccess\UnitTesting\SolutionCrawler\UnitTestingWorkCoordinator.cs (4)
373foreach (var documentId in project.DocumentIds) 624count += project.DocumentIds.Count; 650foreach (var documentId in project.DocumentIds) 668foreach (var documentId in project.DocumentIds)
ExternalAccess\UnitTesting\SolutionCrawler\UnitTestingWorkCoordinator.UnitTestingSemanticChangeProcessor.cs (1)
435foreach (var documentId in project.DocumentIds)
SemanticSearch\SemanticSearchUtilities.cs (1)
76=> GetQueryProject(solution).DocumentIds[0];
Microsoft.CodeAnalysis.Features.UnitTests (1)
EditAndContinue\EditAndContinueWorkspaceServiceTests.cs (1)
137: (from project in solution.Projects from documentId in project.DocumentIds select documentId).ToImmutableArray();
Microsoft.CodeAnalysis.LanguageServer.Protocol (3)
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.InProcOrRemoteHostAnalyzerRunner.cs (1)
175var count = documentAnalysisScope != null ? 1 : project.DocumentIds.Count + 1;
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer_GetDiagnostics.cs (1)
73=> ProduceProjectDiagnosticsAsync(solution.Projects, static project => project.DocumentIds, includeProjectNonLocalResult: true, cancellationToken);
Handler\Diagnostics\DiagnosticSources\AbstractWorkspaceDocumentDiagnosticSource.cs (1)
80static (project, _) => [.. project.DocumentIds.Concat(project.AdditionalDocumentIds)],
Microsoft.CodeAnalysis.Remote.ServiceHub (1)
Services\DiagnosticAnalyzer\DiagnosticComputer.cs (1)
397unitCount += _project.DocumentIds.Count;
Microsoft.CodeAnalysis.Workspaces (17)
CodeActions\CodeAction_Cleanup.cs (1)
67.Concat(solutionChanges.GetAddedProjects().SelectMany(p => p.DocumentIds))
CodeFixesAndRefactorings\FixAllLogger.cs (2)
83m[DocumentCount] = fixAllState.Project.DocumentIds.Count; 87m[DocumentCount] = fixAllState.Solution.Projects.Sum(p => p.DocumentIds.Count);
Editing\SymbolEditor.cs (1)
86foreach (var id in project.DocumentIds)
FindSymbols\FindLiterals\FindLiteralsSearchEngine.cs (1)
87var count = _solution.Projects.SelectMany(p => p.DocumentIds).Count();
Workspace\Solution\Project.cs (1)
196public IEnumerable<Document> Documents => DocumentIds.Select(GetDocument)!;
Workspace\Solution\ProjectChanges.cs (10)
97/// Get <see cref="DocumentId"/>s of added documents in the order they appear in <see cref="Project.DocumentIds"/> of the <see cref="NewProject"/>. 103/// Get <see cref="DocumentId"/>s of added dditional documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 109/// Get <see cref="DocumentId"/>s of added analyzer config documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 116/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 122/// Get changed documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 134/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 141/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="NewProject"/>. 147/// Get <see cref="DocumentId"/>s of removed documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="OldProject"/>. 153/// Get <see cref="DocumentId"/>s of removed additional documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="OldProject"/>. 159/// Get <see cref="DocumentId"/>s of removed analyzer config documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="OldProject"/>.
Workspace\Workspace.cs (1)
307addedDocumentIds.AddRange(addedProject.DocumentIds);
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (3)
VisualStudioMSBuildWorkspaceTests.cs (3)
3009Assert.Empty(proj.DocumentIds); 3026Assert.Equal(2, proj.DocumentIds.Count); 3044Assert.Equal(2, project.DocumentIds.Count);
Microsoft.CodeAnalysis.Workspaces.UnitTests (32)
SolutionTests\ProjectSemanticVersionTests.cs (1)
34await AssertSemanticVersionChangedAsync(project, project.RemoveDocument(project.DocumentIds.Single()));
SolutionTests\SolutionTests.cs (30)
175var documentId = solution.Projects.Single().DocumentIds.Single(); 195var documentId = solution.Projects.Single().DocumentIds.Single(); 226var documentId = solution.Projects.Single().DocumentIds.Single(); 253var documentId = solution.Projects.Single().DocumentIds.Single(); 272var documentId = solution.Projects.Single().DocumentIds.Single(); 291var documentId = solution.Projects.Single().DocumentIds.Single(); 302var documentId = solution.Projects.Single().DocumentIds.Single(); 348var documentId = solution.Projects.Single().DocumentIds.Single(); 373var documentId = solution.Projects.Single().DocumentIds.Single(); 397var documentId = solution.Projects.Single().DocumentIds.Single(); 431var documentId1 = solution.Projects.First().DocumentIds.Single(); 432var documentId2 = solution.Projects.Last().DocumentIds.Single(); 519var documentId1 = solution.Projects.First().DocumentIds.Single(); 520var documentId2 = solution.Projects.Last().DocumentIds.Single(); 598var documentId1 = solution.Projects.First().DocumentIds.Single(); 599var documentId2 = solution.Projects.Last().DocumentIds.Single(); 684var documentId1 = solution.Projects.First().DocumentIds.Single(); 685var documentId2 = solution.Projects.Last().DocumentIds.Single(); 761var documentId1 = solution.Projects.First().DocumentIds.Single(); 762var documentId2 = solution.Projects.Last().DocumentIds.Single(); 849var documentId1 = solution.Projects.First().DocumentIds.Single(); 850var documentId2 = solution.Projects.Last().DocumentIds.Single(); 1011var documentId = solution.Projects.Single().DocumentIds.Single(); 4288var forkedProject = originalProject.RemoveDocument(originalProject.DocumentIds.Single()) 4312var forkedProject = originalProject.RemoveDocument(originalProject.DocumentIds.Single()) 4567ImmutableArray<DocumentId> GetDocumentIds() => [.. solution.GetProject(pid).DocumentIds]; 5462var documentId = solution.Projects.Single().DocumentIds.Single(); 5551var regularDocumentId = solution.Projects.Single().DocumentIds.Single(); 5807var documentId1 = project1.DocumentIds.Single(); 5817var documentId2 = project2.DocumentIds.Single();
SolutionTests\SolutionWithSourceGeneratorTests.cs (1)
259var documentId = project.DocumentIds.Single();
Microsoft.Gen.ComplianceReports.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
536foreach (var documentId in project.DocumentIds)
Microsoft.Gen.ContextualOptions.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
536foreach (var documentId in project.DocumentIds)
Microsoft.Gen.Logging.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
536foreach (var documentId in project.DocumentIds)
Microsoft.Gen.Metrics.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
536foreach (var documentId in project.DocumentIds)
Microsoft.Gen.MetricsReports.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
536foreach (var documentId in project.DocumentIds)
Microsoft.VisualStudio.LanguageServices (4)
CodeCleanup\AbstractCodeCleanUpFixer.cs (1)
201progressTracker.AddItems(projects.Sum(static p => p.DocumentIds.Count));
Implementation\HierarchyItemToProjectIdMap.cs (1)
82if (!candidateProject.DocumentIds.Any(id => ContainedDocument.TryGetContainedDocument(id) != null))
Library\ObjectBrowser\Extensions.cs (1)
107foreach (var documentId in project.DocumentIds)
ProjectSystem\VisualStudioWorkspaceImpl.RemoveDocumentUndoUnit.cs (1)
22=> fromProject.DocumentIds;
Mvc.Api.Analyzers.Test (2)
AddResponseTypeAttributeCodeFixProviderIntegrationTest.cs (1)
65var controllerDocument = project.DocumentIds[0];
ApiActionsDoNotRequireExplicitModelValidationCheckCodeFixProviderTest.cs (1)
32var controllerDocument = project.DocumentIds[0];
Roslyn.VisualStudio.Next.UnitTests (5)
Services\ServiceHubServicesTests.cs (4)
1486var documentIds = project.DocumentIds; 1594SetEqual(solution1.GetProject(currentProjectId).DocumentIds, solution2.GetProject(currentProjectId).DocumentIds); 1596var documentIdsInProject = solution1.GetProject(currentProjectId).DocumentIds;
Services\SolutionServiceTests.cs (1)
313var existingDocumentId = project.DocumentIds.First();