langserver

package
v0.0.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 13, 2021 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DiagsFiles = make(map[string][]lsp.Diagnostic)
View Source
var ServiceMap jrpc2.Assigner
View Source
var StdioServer *jrpc2.Server

Functions

func CancelRequest

func CancelRequest(ctx context.Context, vs lsp.CancelParams) error

func Exit

func Exit(ctx context.Context, vs lsp.None) error

func InitializeServiceMap added in v0.0.12

func InitializeServiceMap()

func Initialized added in v0.0.12

func Initialized(ctx context.Context, vs InitializedParams) error

func RunStdioServer added in v0.0.12

func RunStdioServer(oldLogInstance *oldLog.Logger)

func RunTCPServer added in v0.0.12

func RunTCPServer(address string, port int, oldLogInstance *oldLog.Logger)

func Shutdown

func Shutdown(ctx context.Context, vs lsp.None) error

func TextDocumentComplete

func TextDocumentComplete(ctx context.Context, vs lsp.CompletionParams) (lsp.CompletionList, error)

func TextDocumentDidChange

func TextDocumentDidChange(ctx context.Context, vs lsp.DidChangeTextDocumentParams) error

func TextDocumentDidClose

func TextDocumentDidClose(ctx context.Context, vs lsp.DidCloseTextDocumentParams) error

func TextDocumentDidOpen

func TextDocumentDidOpen(ctx context.Context, vs lsp.DidOpenTextDocumentParams) error

func TextDocumentPublishDiagnostics

func TextDocumentPublishDiagnostics(ctx context.Context, vs lsp.PublishDiagnosticsParams) error

Types

type DocumentLink struct {
	Range lsp.Range `json:"range"`

	/**
	 * The uri this link points to. If missing a resolve request is sent later.
	 */
	Target string `json:"target"`

	Tooltip string `json:"tooltip"`
}
func TextDocumentDocumentLink(ctx context.Context, vs documentLinkParams) ([]DocumentLink, error)

type DocumentLinkOptions added in v0.0.12

type DocumentLinkOptions struct {
	ResolveProvider bool `json:"resolveProvider,omitempty"`
}

type ExtendedInitializeResult added in v0.0.12

type ExtendedInitializeResult struct {
	Capabilities ExtendedServerCapabilities `json:"capabilities"`
}

type ExtendedServerCapabilities added in v0.0.12

type ExtendedServerCapabilities struct {
	TextDocumentSync     *lsp.TextDocumentSyncOptionsOrKind `json:"textDocumentSync,omitempty"`
	CompletionProvider   *lsp.CompletionOptions             `json:"completionProvider,omitempty"`
	HoverProvider        bool                               `json:"hoverProvider,omitempty"`
	DocumentLinkProvider *DocumentLinkOptions               `json:"documentLinkProvider,omitempty"`
}

type InitializedParams added in v0.0.12

type InitializedParams struct{}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL