Class LspTypesMapper
Class To Map Types used In Parser To LSP-Types
public static class LspTypesMapper
- Inheritance
-
LspTypesMapper
- Inherited Members
Fields
SymbolKindMappings
Gets the mappings of symbol kinds to completion item kinds
public static readonly ReadOnlyDictionary<SymbolKind, CompletionItemKind> SymbolKindMappings
Field Value
- ReadOnlyDictionary<SymbolKind, CompletionItemKind>
Methods
MapToLspTextEdits(IEnumerable<TextEdit>)
Maps a collection of TextEdit objects to a collection of LspTypes.TextEdit objects.
public static IEnumerable<TextEdit> MapToLspTextEdits(IEnumerable<TextEdit> edits)
Parameters
editsIEnumerable<TextEdit>The collection of TextEdit objects to be mapped.
Returns
- IEnumerable<TextEdit>
An IEnumerable<T> representing the mapped LSP text edits.
MapWorkspaceEdit(WorkspaceEdit, string, bool)
Maps a WorkspaceEdit objects to a LspTypes.WorkspaceEdit.
public static WorkspaceEdit MapWorkspaceEdit(WorkspaceEdit workspaceEdit, string workspaceUri, bool useDocumentChanges = false)
Parameters
workspaceEditWorkspaceEditThe WorkspaceEdit object to be mapped.
workspaceUristringThe workspace Uri for the edit.
useDocumentChangesboolOption to use DocumentChange instead of TextEdit changes.
Returns
- WorkspaceEdit
A LspTypes.WorkspaceEdit representing the mapped LSP workspace edit.