26 references to Document
Microsoft.CodeAnalysis.LanguageServer.Protocol (26)
Features\EditAndContinue\EditAndContinueDiagnosticSource_OpenDocument.cs (1)
26var designTimeDocument = Document;
Handler\Diagnostics\DiagnosticSources\AbstractDocumentDiagnosticSource.cs (9)
17public Solution Solution => this.Document.Project.Solution; 24public ProjectOrDocumentId GetId() => new(Document.Id); 25public Project GetProject() => Document.Project; 28=> !string.IsNullOrEmpty(Document.FilePath) 29? new VSTextDocumentIdentifier { ProjectContext = ProtocolConversions.ProjectToProjectContext(Document.Project), DocumentUri = Document.GetURI() } 32public string ToDisplayString() => $"{this.GetType().Name}: {Document.FilePath ?? Document.Name} in {Document.Project.Name}";
Handler\Diagnostics\DiagnosticSources\AbstractWorkspaceDocumentDiagnosticSource.cs (7)
45if (Document is SourceGeneratedDocument sourceGeneratedDocument) 57return projectDiagnostics.WhereAsArray(d => d.DocumentId == Document.Id); 63if (!s_projectToDiagnostics.TryGetValue(Document.Project, out var lazyDiagnostics)) 70return [.. result[Document.Id]]; 75Document.Project, 81Document.Project, documentId: null, diagnosticIds: null, shouldIncludeAnalyzer, 107return Task.FromResult(codeAnalysisService.GetLastComputedDocumentDiagnostics(Document.Id));
Handler\Diagnostics\DiagnosticSources\DocumentDiagnosticSource.cs (2)
32Document, range: null, diagnosticKind: this.DiagnosticKind, cancellationToken).ConfigureAwait(false); 40var copilotDiagnostics = await Document.GetCachedCopilotDiagnosticsAsync(span: null, cancellationToken).ConfigureAwait(false);
Handler\Diagnostics\DiagnosticSources\NonLocalDocumentDiagnosticSource.cs (2)
31Document.Project, Document.Id, diagnosticIds: null, _shouldIncludeAnalyzer,
Handler\Diagnostics\DiagnosticSources\TaskListDiagnosticSource.cs (5)
38var service = this.Document.GetLanguageService<ITaskListService>(); 45var items = await service.GetTaskListItemsAsync(this.Document, descriptors, cancellationToken).ConfigureAwait(false); 59projectId: this.Document.Project.Id, 60language: this.Document.Project.Language, 61location: new DiagnosticDataLocation(i.Span, this.Document.Id, mappedFileSpan: i.MappedSpan)));