Class DiagnoseDocumentParams
- Namespace
- RDCore.SDK.Extensibility.Diagnostics
- Assembly
- RDCore.SDK.dll
Request for rdcore/diagnostics/document: the language server hands a diagnostics-provider
extension everything it needs to analyze one document and asks for the diagnostics it finds.
[Method("rdcore/diagnostics/document", Direction.ClientToServer)]
public record DiagnoseDocumentParams : IRequest, IRequest<Unit>, IRequest<DiagnoseDocumentResult>, IBaseRequest, IEquatable<DiagnoseDocumentParams>
- Inheritance
-
DiagnoseDocumentParams
- Implements
-
IRequestIRequest<Unit>IRequest<DiagnoseDocumentResult>IBaseRequest
- Inherited Members
Remarks
The language server is the orchestrator: it owns the workspace and the parser, so it pushes the parsed ModuleParseResult down rather than have each provider re-read and re-parse. The parse result's AST is polymorphic and the JSON-RPC transport's serializer cannot round-trip it (see PlatformJson), so the payload rides a System.Text.Json string in Json. The response is a plain DiagnoseDocumentResult: an LSP Diagnostic is the transport serializer's own model. Only extensions whose manifest advertises the DiagnoseDocument capability receive this request.
Properties
Json
The System.Text.Json representation of a DiagnoseDocumentPayload.
public string Json { get; init; }