Documentation ¶
Overview ¶
Package types contains the Language Server Protocol specification types. See https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/.
Index ¶
- type DefinitionParams
- type DidChangeTextDocumentParams
- type DidCloseTextDocumentParams
- type DidOpenTextDocumentParams
- type InitializeParams
- type InitializeResult
- type Location
- type Position
- type Range
- type ReferenceParams
- type RequestID
- type RequestMessage
- type ResponseMessage
- type ServerCapabilities
- type ServerInfo
- type TextDocumentContentChangeEvent
- type TextDocumentIdentifier
- type TextDocumentItem
- type TextDocumentPositionParams
- type TextDocumentSyncKind
- type TextDocumentSyncOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefinitionParams ¶
type DefinitionParams struct {
TextDocumentPositionParams
}
type DidChangeTextDocumentParams ¶
type DidChangeTextDocumentParams struct { TextDocument TextDocumentIdentifier `json:"textDocument"` ContentChanges []TextDocumentContentChangeEvent `json:"contentChanges"` }
type DidCloseTextDocumentParams ¶
type DidCloseTextDocumentParams struct {
TextDocument TextDocumentIdentifier `json:"textDocument"`
}
type DidOpenTextDocumentParams ¶
type DidOpenTextDocumentParams struct {
TextDocument TextDocumentItem `json:"textDocument"`
}
type InitializeParams ¶
type InitializeResult ¶
type InitializeResult struct { Capabilities ServerCapabilities `json:"capabilities"` ServerInfo ServerInfo `json:"serverInfo"` }
type Location ¶
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#location.
type Position ¶
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#position.
type Range ¶
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#range.
type ReferenceParams ¶
type ReferenceParams struct {
TextDocumentPositionParams
}
type RequestMessage ¶
type RequestMessage struct { JSONRPC string `json:"jsonrpc"` ID *RequestID `json:"id"` Method string `json:"method"` Params json.RawMessage `json:"params"` }
type ResponseMessage ¶
type ServerCapabilities ¶
type ServerCapabilities struct { TextDocumentSync TextDocumentSyncOptions `json:"textDocumentSync"` DefinitionProvider bool `json:"definitionProvider,omitempty"` ReferencesProvider bool `json:"referencesProvider,omitempty"` }
type ServerInfo ¶
type TextDocumentContentChangeEvent ¶
type TextDocumentIdentifier ¶
type TextDocumentIdentifier struct {
URI string `json:"uri"`
}
type TextDocumentItem ¶
type TextDocumentPositionParams ¶
type TextDocumentPositionParams struct { TextDocument TextDocumentIdentifier `json:"textDocument"` Position Position `json:"position"` }
type TextDocumentSyncKind ¶
type TextDocumentSyncKind int
const ( SyncNone TextDocumentSyncKind = 0 SyncFull TextDocumentSyncKind = 1 SyncIncremental TextDocumentSyncKind = 2 )
type TextDocumentSyncOptions ¶
type TextDocumentSyncOptions struct { OpenClose bool `json:"openClose,omitempty"` Change TextDocumentSyncKind `json:"change"` }
Click to show internal directories.
Click to hide internal directories.