nixd
Loading...
Searching...
No Matches
lspserver::WorkspaceEdit Struct Reference

#include <Protocol.h>

Public Attributes

std::optional< std::map< std::string, std::vector< TextEdit > > > changes
 Holds changes to existing resources.
std::optional< std::vector< DocumentChange > > documentChanges
std::map< std::string, ChangeAnnotationchangeAnnotations

Detailed Description

The edit should either provide changes or documentChanges. If the client can handle versioned document edits and if documentChanges are present, the latter are preferred over changes.

Definition at line 1069 of file lspserver/include/lspserver/Protocol.h.

Member Data Documentation

◆ changeAnnotations

std::map<std::string, ChangeAnnotation> lspserver::WorkspaceEdit::changeAnnotations

A map of change annotations that can be referenced in AnnotatedTextEdit.

Definition at line 1081 of file lspserver/include/lspserver/Protocol.h.

Referenced by lspserver::fromJSON(), and lspserver::toJSON().

◆ changes

std::optional<std::map<std::string, std::vector<TextEdit> > > lspserver::WorkspaceEdit::changes

Holds changes to existing resources.

Definition at line 1071 of file lspserver/include/lspserver/Protocol.h.

Referenced by lspserver::fromJSON(), and lspserver::toJSON().

◆ documentChanges

std::optional<std::vector<DocumentChange> > lspserver::WorkspaceEdit::documentChanges

Document changes including text edits and resource operations.

If a client supports workspace.workspaceEdit.resourceOperations, this can contain TextDocumentEdit, CreateFile, RenameFile, and DeleteFile operations. Otherwise, only TextDocumentEdit is supported.

Definition at line 1077 of file lspserver/include/lspserver/Protocol.h.

Referenced by nixd::addExtractToFileAction(), lspserver::fromJSON(), and lspserver::toJSON().


The documentation for this struct was generated from the following file: