1 instantiation of ActiveFileState
Microsoft.CodeAnalysis.LanguageServer.Protocol (1)
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.StateSet.cs (1)
99=> _activeFileStates.GetOrAdd(documentId, id => new ActiveFileState(id));
11 references to ActiveFileState
Microsoft.CodeAnalysis.LanguageServer.Protocol (11)
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.IncrementalMemberEditAnalyzer.cs (1)
86var state = analyzerWithState.State;
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.ProjectState.cs (1)
250public async ValueTask MergeAsync(ActiveFileState state, TextDocument document, IGlobalOptionService globalOptions)
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.StateSet.cs (7)
28private readonly ConcurrentDictionary<DocumentId, ActiveFileState> _activeFileStates; 37_activeFileStates = new ConcurrentDictionary<DocumentId, ActiveFileState>(concurrencyLevel: 2, capacity: 10); 92public bool TryGetActiveFileState(DocumentId documentId, [NotNullWhen(true)] out ActiveFileState? state) 98public ActiveFileState GetOrCreateActiveFileState(DocumentId documentId) 118var activeFileState = GetOrCreateActiveFileState(document.Id); 130if (!_activeFileStates.TryRemove(document.Id, out var activeFileState)) 146if (TryGetActiveFileState(document.Id, out var activeFileState))
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer_GetDiagnosticsForSpan.cs (2)
226var state = stateSet.GetOrCreateActiveFileState(_document.Id); 540private sealed record class AnalyzerWithState(DiagnosticAnalyzer Analyzer, bool IsHostAnalyzer, ActiveFileState State, DocumentAnalysisData ExistingData);