lsp

package
v0.1.7 Latest Latest
Warning

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

Go to latest
Published: May 18, 2022 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Version string
	Lint    bool

	Conn jsonrpc2.Conn
}

type Formatter added in v0.1.3

type Formatter struct {
	Config *config.Config
	// contains filtered or unexported fields
}

Formatter is a struct that holds the state of the formatter. A new formatter should be initialized when using different config.

func New added in v0.1.3

func New(cfg *config.Config) (*Formatter, error)

New creates a new instance of Formatter.

type LSP

type LSP struct {
	// contains filtered or unexported fields
}

func NewLSPServer

func NewLSPServer(config Config) *LSP

func (*LSP) CloseFile

func (l *LSP) CloseFile(ctx context.Context, data protocol.DidCloseTextDocumentParams) error

func (*LSP) Format

func (l *LSP) Format(ctx context.Context, params protocol.DocumentFormattingParams, reply jsonrpc2.Replier)

func (*LSP) Goto added in v0.1.5

func (l *LSP) Goto(ctx context.Context, params protocol.DefinitionParams, reply jsonrpc2.Replier)

func (*LSP) Handle

func (l *LSP) Handle(ctx context.Context, reply jsonrpc2.Replier, r jsonrpc2.Request) error

func (*LSP) Load

func (l *LSP) Load(ctx context.Context) error

func (*LSP) OpenFile

func (l *LSP) OpenFile(ctx context.Context, data protocol.DidOpenTextDocumentParams) error

func (*LSP) UpdateFile

func (l *LSP) UpdateFile(ctx context.Context, data protocol.DidChangeTextDocumentParams) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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