server

package
v1.0.0-alpha Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const CacheDuration = time.Minute * 5

CacheDuration is the duration of the cache

Variables

This section is empty.

Functions

This section is empty.

Types

type NodeCache

type NodeCache struct {
	Expiration time.Time
	Nodes      []*models.Node
}

NodeCache is the cache of the nodes

type Server

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

Server is a language server

func New

func New(ir *language.Interpreter, root string, isDir bool, cache, colors bool) *Server

NewServer creates a new server

func (*Server) Serve

func (s *Server) Serve(addr string) error

Serve starts the server

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP serves the http request

Jump to

Keyboard shortcuts

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