Documentation ¶
Index ¶
- Constants
- Variables
- func AddRouter(httpPath string, handlerBuilder func() IHandler)
- func AddRouterAtServer(server *web.HttpServer, httpPath string, handlerBuilder func() IHandler)
- type Handler
- func (this *Handler) Close()
- func (this *Handler) Handle()
- func (this *Handler) OnConnect()
- func (this *Handler) OnDisconnect(e error)
- func (this *Handler) OnMessage(msgType int, body []byte) error
- func (this *Handler) ResponseHeaders(headers map[string][]string)
- func (this *Handler) Send(msgType int, body []byte) error
- type IHandler
Constants ¶
View Source
const ( Text = 1 Binary = 2 Close = 8 Ping = 9 Pong = 10 String = 1 Bytes = 2 )
Variables ¶
View Source
var Err_CloseIntent = errors.New("Close by you")
Functions ¶
func AddRouterAtServer ¶
func AddRouterAtServer(server *web.HttpServer, httpPath string, handlerBuilder func() IHandler)
Types ¶
Click to show internal directories.
Click to hide internal directories.