transciever

package
v0.5.10 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WS = &WSHandler{}

WS to handle

Functions

func Echo

func Echo(conn *websocket.Conn) error

func ExplicitInit added in v0.2.8

func ExplicitInit()

ExplicitInit only run init() if we're configured for such

Types

type Client

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

Client is a middleman between the websocket connection and the hub.

type Hub

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

Hub hub maintains the set of active clients and broadcasts messages to the clients.

type HubHolder

type HubHolder struct {
	Hub *Hub
}

type WSHandler

type WSHandler struct{}

WSHandler implements the Handler Interface

func (WSHandler) ServeHTTP

func (WS WSHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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