Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultDialer = websocket.DefaultDialer
Functions ¶
This section is empty.
Types ¶
type Connection ¶ added in v3.0.5
type Connection struct {
// contains filtered or unexported fields
}
func (*Connection) Close ¶ added in v3.0.5
func (c *Connection) Close()
func (*Connection) IsServer ¶ added in v3.0.5
func (c *Connection) IsServer() bool
IsServer returns true if the connection has server capabilities and not just a client. For now, we assume every connection with ping/pong handler is a server.
func (*Connection) Listen ¶ added in v3.0.5
func (c *Connection) Listen() chan struct{}
func (*Connection) SetMessageHandler ¶ added in v3.0.5
func (c *Connection) SetMessageHandler(fn MessageHandler)
func (*Connection) Write ¶ added in v3.0.5
func (c *Connection) Write(data []byte)
type MessageHandler ¶ added in v3.0.5
Click to show internal directories.
Click to hide internal directories.