server

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MessageType

type MessageType uint8
const (
	MessageTypeUnknown MessageType = iota
	MessageTypePing
	MessageTypePong
	MessageTypeSubscribe
	MessageTypeNotify
	MessageTypeMethod
	MessageTypeResult
	MessageTypeFailure
	MessageTypeError
)

func (MessageType) String

func (mt MessageType) String() string

type Server

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

func New

func New(ctx context.Context, staticFS fs.FS, logger *log.Logger, settingsProvider *settings.Provider) *Server

func (*Server) Start

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

func (*Server) TriggerEvent

func (s *Server) TriggerEvent(event string, args ...interface{}) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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