ws

package
v0.20.0-dev-dccb254863... Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2018 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Socket

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

func (*Socket) Close

func (s *Socket) Close(args ...goja.Value)

func (*Socket) On

func (s *Socket) On(event string, handler goja.Value)

func (*Socket) Ping

func (s *Socket) Ping()

func (*Socket) Send

func (s *Socket) Send(message string)

func (*Socket) SetInterval

func (s *Socket) SetInterval(fn goja.Callable, intervalMs int)

func (*Socket) SetTimeout

func (s *Socket) SetTimeout(fn goja.Callable, timeoutMs int)

type WS

type WS struct{}

func New added in v0.18.0

func New() *WS

func (*WS) Connect

func (*WS) Connect(ctx context.Context, url string, args ...goja.Value) (*WSHTTPResponse, error)

type WSHTTPResponse

type WSHTTPResponse struct {
	URL     string
	Status  int
	Headers map[string]string
	Body    string
	Error   string
}

Jump to

Keyboard shortcuts

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