Documentation
¶
Index ¶
- type Reader
- type Server
- func (s *Server) InitComplete() <-chan struct{}
- func (s *Server) IsActive() bool
- func (s *Server) NpmInstall(cwd string, args []string) ([]byte, error)
- func (s *Server) ProgressFinish(message *diagnostics.Message, args ...any)
- func (s *Server) ProgressStart(message *diagnostics.Message, args ...any)
- func (s *Server) PublishDiagnostics(ctx context.Context, params *lsproto.PublishDiagnosticsParams) error
- func (s *Server) RefreshCodeLens(ctx context.Context) error
- func (s *Server) RefreshDiagnostics(ctx context.Context) error
- func (s *Server) RefreshInlayHints(ctx context.Context) error
- func (s *Server) RequestConfiguration(ctx context.Context) (lsutil.UserPreferences, error)
- func (s *Server) Run(ctx context.Context) error
- func (s *Server) SendTelemetry(ctx context.Context, telemetry lsproto.TelemetryEvent) error
- func (s *Server) Session() *project.Session
- func (s *Server) SetCompilerOptionsForInferredProjects(ctx context.Context, options *core.CompilerOptions)
- func (s *Server) UnwatchFiles(ctx context.Context, id project.WatcherID) error
- func (s *Server) WatchFiles(ctx context.Context, id project.WatcherID, ...) error
- type ServerOptions
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func NewServer ¶
func NewServer(opts *ServerOptions) *Server
func (*Server) InitComplete ¶
func (s *Server) InitComplete() <-chan struct{}
InitComplete returns a channel that is closed when the server has finished processing the initialized notification, including the initial configuration exchange with the client.
func (*Server) NpmInstall ¶
NpmInstall implements ata.NpmExecutor
func (*Server) ProgressFinish ¶
func (s *Server) ProgressFinish(message *diagnostics.Message, args ...any)
ProgressFinish implements project.Client.
func (*Server) ProgressStart ¶
func (s *Server) ProgressStart(message *diagnostics.Message, args ...any)
ProgressStart implements project.Client.
func (*Server) PublishDiagnostics ¶
func (s *Server) PublishDiagnostics(ctx context.Context, params *lsproto.PublishDiagnosticsParams) error
PublishDiagnostics implements project.Client.
func (*Server) RefreshDiagnostics ¶
RefreshDiagnostics implements project.Client.
func (*Server) RequestConfiguration ¶
func (*Server) SendTelemetry ¶
SendTelemetry implements project.Client.
func (*Server) SetCompilerOptionsForInferredProjects ¶
func (s *Server) SetCompilerOptionsForInferredProjects(ctx context.Context, options *core.CompilerOptions)
!!! temporary; remove when we have `handleDidChangeConfiguration`/implicit project config support
func (*Server) UnwatchFiles ¶
UnwatchFiles implements project.Client.
func (*Server) WatchFiles ¶
func (s *Server) WatchFiles(ctx context.Context, id project.WatcherID, watchers []*lsproto.FileSystemWatcher) error
WatchFiles implements project.Client.
type ServerOptions ¶
type ServerOptions struct {
In Reader
Out Writer
Err io.Writer
Cwd string
FS vfs.FS
DefaultLibraryPath string
TypingsLocation string
ParseCache *project.ParseCache
NpmInstall func(cwd string, args []string) ([]byte, error)
ProgressDelay time.Duration // delay before showing progress UI; 0 means no delay
}
Click to show internal directories.
Click to hide internal directories.