Versions in this module Expand all Collapse all v0 v0.12.5 Mar 4, 2020 v0.12.4 Mar 3, 2020 v0.12.3 Feb 7, 2019 GO-2020-0033 GO-2020-0033: Path Traversal in aahframe.work v0.12.2 Dec 13, 2018 GO-2020-0033 GO-2020-0033: Path Traversal in aahframe.work v0.12.1 Dec 8, 2018 GO-2020-0033 GO-2020-0033: Path Traversal in aahframe.work v0.12.0 Dec 2, 2018 GO-2020-0033 GO-2020-0033: Path Traversal in aahframe.work Changes in this version + const EventOnError + const EventOnPostConnect + const EventOnPostDisconnect + const EventOnPreConnect + var ErrAbortRequest = errors.New("aahws: abort request") + var ErrConnectFailed = errors.New("aahws: connect failed") + var ErrConnectionClosed = errors.New("aahws: connection closed") + var ErrNotFound = errors.New("aahws: not found") + var ErrOriginMismatch = errors.New("aahws: origin mismatch") + var ErrParameterParseFailed = errors.New("aahws: parameter parse failed") + var ErrUseOfClosedConnection = errors.New("aahws: use of closed ws connection") + func IsDisconnected(err error) bool + type Context struct + Conn net.Conn + Header http.Header + Req *Request + func (ctx *Context) Abort(httpErroCode int) + func (ctx *Context) Disconnect() error + func (ctx *Context) ErrorReason() error + func (ctx *Context) Log() log.Loggerer + func (ctx *Context) ReadBinary() ([]byte, error) + func (ctx *Context) ReadJSON(t interface{}) error + func (ctx *Context) ReadText() (string, error) + func (ctx *Context) ReadXML(t interface{}) error + func (ctx *Context) ReplyBinary(v []byte) error + func (ctx *Context) ReplyJSON(v interface{}) error + func (ctx *Context) ReplyText(v string) error + func (ctx *Context) ReplyXML(v interface{}) error + type Engine struct + func New(app interface{}) (*Engine, error) + func (e *Engine) AddWebSocket(t interface{}, methods []*ainsp.Method) + func (e *Engine) Handle(w http.ResponseWriter, r *http.Request) + func (e *Engine) Log() log.Loggerer + func (e *Engine) OnError(ecf EventCallbackFunc) + func (e *Engine) OnPostConnect(ecf EventCallbackFunc) + func (e *Engine) OnPostDisconnect(ecf EventCallbackFunc) + func (e *Engine) OnPreConnect(ecf EventCallbackFunc) + func (e *Engine) SetIDGenerator(g IDGenerator) + type EventCallbackFunc func(eventName string, ctx *Context) + type IDGenerator func(ctx *Context) string + type Request struct + Header http.Header + Host string + ID string + Path string + func (r *Request) ClientIP() string + func (r *Request) PathValue(key string) string + func (r *Request) QueryArrayValue(key string) []string + func (r *Request) QueryValue(key string) string + func (r *Request) URL() *url.URL + func (r Request) String() string