Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a middleman between the websocket connection and the hub
func (*Client) ReadPump ¶
func (c *Client) ReadPump()
readPump pumps messages from the websocket connection to the hub.
The application runs readPump in a per-connection goroutine. The application ensures that there is at most one reader on a connection by executing all reads from this goroutine
func (*Client) WritePump ¶
func (c *Client) WritePump()
writePump pumps messages from the hub to the websocket connection.
A goroutine running writePump is started for each connection. The application ensures that there is at most one writer to a connection by executing all writes from this goroutine
Click to show internal directories.
Click to hide internal directories.