websocket

package
v0.0.0-...-8e4544a Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrShutdown = errors.New("connection is shut down")
)

Functions

This section is empty.

Types

type Transport

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

func NewTransport

func NewTransport(url string) (*Transport, error)

func (*Transport) Call

func (caller *Transport) Call(method string, args []interface{}, reply interface{}) error

func (*Transport) Close

func (caller *Transport) Close() error

Close calls the underlying web socket Close method. If the connection is already shutting down, ErrShutdown is returned.

func (*Transport) SetCallback

func (caller *Transport) SetCallback(api string, method string, notice func(args json.RawMessage)) error

func (*Transport) WriteJSON

func (caller *Transport) WriteJSON(v interface{}) error

Jump to

Keyboard shortcuts

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