handler

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2018 License: BSD-3-Clause Imports: 20 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package handler implements a VSCode-compatible language server for Serulian.

Index

Constants

View Source
const DiagnoseDelay = 500 * time.Millisecond

DiagnoseDelay is the delay waited before a document is re-parsed.

View Source
const MaximumBuildDuration = 5 * time.Second

MaximumBuildDuration is the maximum duration to build a handle before we timeout.

Variables

This section is empty.

Functions

func NewHandler

func NewHandler(entrypointSourceFile string, vcsDevelopmentDirectories []string) jsonrpc2.Handler

NewHandler creates a Serulian language server handler.

Types

type CancelationHandle added in v0.3.2

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

CancelationHandle is a handle for tracking the cancelation of a language server request.

func NewCancelationHandle added in v0.3.2

func NewCancelationHandle(id jsonrpc2.ID) *CancelationHandle

NewCancelationHandle returns a new cancelation handle.

func (*CancelationHandle) Cancel added in v0.3.2

func (ch *CancelationHandle) Cancel()

Cancel marks the operation as having been canceled.

func (*CancelationHandle) Error added in v0.3.2

func (ch *CancelationHandle) Error() error

func (*CancelationHandle) WasCanceled added in v0.3.2

func (ch *CancelationHandle) WasCanceled() bool

WasCanceled returns whether the operation was canceled.

type SerulianLangServerHandler

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

SerulianLangServerHandler defines a JSON-RPC handler that implements the Serulian language server.

func (*SerulianLangServerHandler) Handle

Handle implements the JSON-RPC handling method for all incoming requests and notifications.

Jump to

Keyboard shortcuts

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