Versions in this module Expand all Collapse all v1 v1.0.1 Jan 30, 2020 v1.0.0 Jan 30, 2020 Changes in this version + const CONNECT + const DELETE + const GET + const HEAD + const HeaderAcceptEncoding + const HeaderAccessControlAllowCredentials + const HeaderAccessControlAllowHeaders + const HeaderAccessControlAllowMethods + const HeaderAccessControlAllowOrigin + const HeaderAccessControlExposeHeaders + const HeaderAccessControlMaxAge + const HeaderAccessControlRequestHeaders + const HeaderAccessControlRequestMethod + const HeaderAllow + const HeaderAuthorization + const HeaderContentDisposition + const HeaderContentEncoding + const HeaderContentLength + const HeaderContentSecurityPolicy + const HeaderContentType + const HeaderCookie + const HeaderIfModifiedSince + const HeaderLastModified + const HeaderLocation + const HeaderOrigin + const HeaderServer + const HeaderSetCookie + const HeaderStrictTransportSecurity + const HeaderUpgrade + const HeaderVary + const HeaderWWWAuthenticate + const HeaderXCSRFToken + const HeaderXContentTypeOptions + const HeaderXForwardedFor + const HeaderXForwardedProto + const HeaderXFrameOptions + const HeaderXHTTPMethodOverride + const HeaderXRealIP + const HeaderXXSSProtection + const MIMEApplicationForm + const MIMEApplicationJSON + const MIMEApplicationJSONCharsetUTF8 + const MIMEApplicationJavaScript + const MIMEApplicationJavaScriptCharsetUTF8 + const MIMEApplicationMsgpack + const MIMEApplicationProtobuf + const MIMEApplicationXML + const MIMEApplicationXMLCharsetUTF8 + const MIMEMultipartForm + const MIMEOctetStream + const MIMETextHTML + const MIMETextHTMLCharsetUTF8 + const MIMETextPlain + const MIMETextPlainCharsetUTF8 + const OPTIONS + const PATCH + const POST + const PUT + const TRACE + var ErrCookieNotFound = errors.New("cookie not found") + var ErrInvalidRedirectCode = errors.New("invalid redirect status code") + var ErrMethodNotAllowed = NewHTTPError(http.StatusMethodNotAllowed) + var ErrNotFound = NewHTTPError(http.StatusNotFound) + var ErrRendererNotRegistered = errors.New("renderer not registered") + var ErrStatusRequestEntityTooLarge = NewHTTPError(http.StatusRequestEntityTooLarge) + var ErrUnauthorized = NewHTTPError(http.StatusUnauthorized) + var ErrUnsupportedMediaType = NewHTTPError(http.StatusUnsupportedMediaType) + var MethodNotAllowedHandler = func(c Context) error + var NotFoundHandler = func(c Context) error + func ContentTypeByExtension(name string) (t string) + type Binder interface + Bind func(interface{}, Context) error + type Context interface + Attachment func(io.ReadSeeker, string) error + Bind func(interface{}) error + Blob func(int, string, []byte) error + Cookie func(string) (engine.Cookie, error) + Cookies func() []engine.Cookie + Echo func() *Echo + Error func(err error) + File func(string) error + FormFile func(string) (*multipart.FileHeader, error) + FormParams func() map[string][]string + FormValue func(string) string + Get func(string) interface{} + HTML func(int, string) error + Handler func() HandlerFunc + Inline func(io.ReadSeeker, string) error + JSON func(int, interface{}) error + JSONBlob func(int, []byte) error + JSONP func(int, string, interface{}) error + JSONPBlob func(int, string, []byte) error + Logger func() log.Logger + MultipartForm func() (*multipart.Form, error) + NoContent func(int) error + P func(int) string + Param func(string) string + ParamNames func() []string + ParamValues func() []string + Path func() string + QueryParam func(string) string + QueryParams func() map[string][]string + Redirect func(int, string) error + Render func(int, string, interface{}) error + Request func() engine.Request + Reset func(engine.Request, engine.Response) + Response func() engine.Response + ServeContent func(io.ReadSeeker, string, time.Time) error + Set func(string, interface{}) + SetCookie func(engine.Cookie) + SetHandler func(HandlerFunc) + SetParamNames func(...string) + SetParamValues func(...string) + SetPath func(string) + SetStdContext func(context.Context) + StdContext func() context.Context + Stream func(int, string, io.Reader) error + String func(int, string) error + XML func(int, interface{}) error + XMLBlob func(int, []byte) error + type Cookie struct + func (c *Cookie) Domain() string + func (c *Cookie) Expires() time.Time + func (c *Cookie) HTTPOnly() bool + func (c *Cookie) Name() string + func (c *Cookie) Path() string + func (c *Cookie) SameSite() http.SameSite + func (c *Cookie) Secure() bool + func (c *Cookie) SetDomain(domain string) + func (c *Cookie) SetExpires(expires time.Time) + func (c *Cookie) SetHTTPOnly(httpOnly bool) + func (c *Cookie) SetName(name string) + func (c *Cookie) SetPath(path string) + func (c *Cookie) SetSameSite(sameSite http.SameSite) + func (c *Cookie) SetSecure(secure bool) + func (c *Cookie) SetValue(value string) + func (c *Cookie) Value() string + type Echo struct + func New() (e *Echo) + func (e *Echo) AcquireContext() Context + func (e *Echo) Any(path string, handler HandlerFunc, middleware ...MiddlewareFunc) + func (e *Echo) Binder() Binder + func (e *Echo) CONNECT(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Connect(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) DELETE(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Debug() bool + func (e *Echo) DefaultHTTPErrorHandler(err error, c Context) + func (e *Echo) Delete(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) File(path, file string) + func (e *Echo) GET(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Get(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Group(prefix string, m ...MiddlewareFunc) (g *Group) + func (e *Echo) HEAD(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Head(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Logger() log.Logger + func (e *Echo) Match(methods []string, path string, handler HandlerFunc, ...) + func (e *Echo) NewContext(req engine.Request, res engine.Response) Context + func (e *Echo) OPTIONS(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Options(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) PATCH(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) POST(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) PUT(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Patch(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Post(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Pre(middleware ...MiddlewareFunc) + func (e *Echo) Put(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) ReleaseContext(c Context) + func (e *Echo) Router() *Router + func (e *Echo) Routes() []Route + func (e *Echo) Run(s engine.Server) error + func (e *Echo) ServeHTTP(req engine.Request, res engine.Response) + func (e *Echo) SetBinder(b Binder) + func (e *Echo) SetDebug(on bool) + func (e *Echo) SetHTTPErrorHandler(h HTTPErrorHandler) + func (e *Echo) SetLogLevel(l glog.Lvl) + func (e *Echo) SetLogOutput(w io.Writer) + func (e *Echo) SetLogger(l log.Logger) + func (e *Echo) SetRenderer(r Renderer) + func (e *Echo) Static(prefix, root string) + func (e *Echo) Stop() error + func (e *Echo) TRACE(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) Trace(path string, h HandlerFunc, m ...MiddlewareFunc) + func (e *Echo) URI(handler HandlerFunc, params ...interface{}) string + func (e *Echo) URL(h HandlerFunc, params ...interface{}) string + func (e *Echo) Use(middleware ...MiddlewareFunc) + type Group struct + func (g *Group) Any(path string, handler HandlerFunc, middleware ...MiddlewareFunc) + func (g *Group) CONNECT(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Connect(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) DELETE(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Delete(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) File(path, file string) + func (g *Group) GET(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Get(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Group(prefix string, middleware ...MiddlewareFunc) *Group + func (g *Group) HEAD(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Head(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Match(methods []string, path string, handler HandlerFunc, ...) + func (g *Group) OPTIONS(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Options(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) PATCH(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) POST(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) PUT(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Patch(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Post(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Put(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Static(prefix, root string) + func (g *Group) TRACE(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Trace(path string, h HandlerFunc, m ...MiddlewareFunc) + func (g *Group) Use(m ...MiddlewareFunc) + type HTTPError struct + Code int + Message string + func NewHTTPError(code int, msg ...string) *HTTPError + func (e *HTTPError) Error() string + type HTTPErrorHandler func(error, Context) + type HandlerFunc func(Context) error + type MiddlewareFunc func(HandlerFunc) HandlerFunc + func WrapMiddleware(h HandlerFunc) MiddlewareFunc + type Renderer interface + Render func(io.Writer, string, interface{}, Context) error + type Route struct + Handler string + Method string + Path string + type Router struct + func NewRouter(e *Echo) *Router + func (r *Router) Add(method, path string, h HandlerFunc, e *Echo) + func (r *Router) Find(method, path string, context Context) + type Validator interface + Validate func() error