42 references to SolutionState
Microsoft.CodeAnalysis.Workspaces (42)
Workspace\Host\PersistentStorage\ProjectKey.cs (1)
35=> ToProjectKey(project.Solution.SolutionState, project.State);
Workspace\Host\PersistentStorage\SolutionKey.cs (1)
22=> ToSolutionKey(solution.SolutionState);
Workspace\ProjectSystem\ProjectSystemProject.cs (1)
322var projectState = solution.SolutionState.GetRequiredProjectState(projectId);
Workspace\Solution\Solution.cs (33)
74internal int WorkspaceVersion => this.SolutionState.WorkspaceVersion; 82public SolutionServices Services => this.SolutionState.Services; 84internal string? WorkspaceKind => this.SolutionState.WorkspaceKind; 86internal ProjectState? GetProjectState(ProjectId projectId) => this.SolutionState.GetProjectState(projectId); 97return this.SolutionState.Services.WorkspaceServices.Workspace; 105public SolutionId Id => this.SolutionState.Id; 110public string? FilePath => this.SolutionState.FilePath; 115public VersionStamp Version => this.SolutionState.Version; 121public IReadOnlyList<ProjectId> ProjectIds => this.SolutionState.ProjectIds; 127internal ImmutableArray<ProjectState> SortedProjectStates => this.SolutionState.SortedProjectStates; 138public VersionStamp GetLatestProjectVersion() => this.SolutionState.GetLatestProjectVersion(); 144=> this.SolutionState.ContainsProject(projectId); 167var state = solution.SolutionState.GetProjectState(projectId); 222public bool ContainsDocument([NotNullWhen(returnValue: true)] DocumentId? documentId) => this.SolutionState.ContainsDocument(documentId); 227public bool ContainsAdditionalDocument([NotNullWhen(returnValue: true)] DocumentId? documentId) => this.SolutionState.ContainsAdditionalDocument(documentId); 232public bool ContainsAnalyzerConfigDocument([NotNullWhen(returnValue: true)] DocumentId? documentId) => this.SolutionState.ContainsAnalyzerConfigDocument(documentId); 632if (this.SolutionState.ContainsProjectReference(projectId, projectReference)) 728if (this.SolutionState.ContainsMetadataReference(projectId, metadataReference)) 811if (this.SolutionState.ContainsAnalyzerReference(projectId, analyzerReference)) 895if (this.SolutionState.AnalyzerReferences.Contains(analyzerReference)) 915if (!this.SolutionState.AnalyzerReferences.Contains(analyzerReference)) 1129=> this.SolutionState.GetProjectState(projectId) ?? throw new InvalidOperationException(string.Format(WorkspacesResources._0_is_not_part_of_the_workspace, projectId)); 1579=> this.SolutionState.GetRelatedDocumentIds(documentId, includeDifferentLanguages); 1589=> this.SolutionState.GetFirstRelatedDocumentId(documentId, relatedProjectIdHint); 1696public ImmutableArray<DocumentId> GetDocumentIdsWithFilePath(string? filePath) => this.SolutionState.GetDocumentIdsWithFilePath(filePath); 1701public ProjectDependencyGraph GetProjectDependencyGraph() => this.SolutionState.GetProjectDependencyGraph(); 1707public OptionSet Options => this.SolutionState.Options; 1712public IReadOnlyList<AnalyzerReference> AnalyzerReferences => this.SolutionState.AnalyzerReferences; 1720internal ImmutableDictionary<string, StructuredAnalyzerConfigOptions> FallbackAnalyzerOptions => SolutionState.FallbackAnalyzerOptions; 1862if (this.SolutionState.ContainsTransitiveReference(projectReference.ProjectId, projectId)) 1880var projectState = this.SolutionState.GetRequiredProjectState(projectId); 1883var hasSubmissionReference = !ignoreExistingReferences && projectState.ProjectReferences.Any(p => this.SolutionState.GetRequiredProjectState(p.ProjectId).IsSubmission); 1888var referencedProjectState = this.SolutionState.GetProjectState(projectReference.ProjectId);
Workspace\Workspace.cs (6)
390changedDocumentState ??= solution.SolutionState.GetRequiredDocumentState(changedDocumentId); 426foreach (var (language, _) in oldSolution.SolutionState.ProjectCountByLanguage) 428if (!newSolution.SolutionState.ProjectCountByLanguage.ContainsKey(language)) 435foreach (var (language, _) in newSolution.SolutionState.ProjectCountByLanguage) 437if (oldSolution.SolutionState.ProjectCountByLanguage.ContainsKey(language)) 1623var changedOptions = newSolution.SolutionState.Options.GetChangedOptions();