Versions in this module Expand all Collapse all v2 v2.0.0 Jan 1, 2021 Changes in this version + const GzipHeaderValue + const HeaderAcceptEncoding + const HeaderCacheControl + const HeaderContentDisposition + const HeaderContentEncoding + const HeaderContentLength + const HeaderContentType + const HeaderETag + const HeaderIfModifiedSince + const HeaderLastModified + const HeaderVary + var ParseTime = func(text string) (t time.Time, err error) + func IsZeroTime(t time.Time) bool + type App struct + Handlers HandlerMap + Middlewares Handlers + Prefix string + Requests []Path + Routers RouterMap + func NewApp() *App + func (app *App) ANY(url string, handler ...Handler) *App + func (app *App) AppendReqAndResp(url, method string, handler []Handler) + func (app *App) DELETE(url string, handler ...Handler) *App + func (app *App) Find(url, method string) []Handler + func (app *App) GET(url string, handler ...Handler) *App + func (app *App) Group(prefix string, middleware ...Handler) *RouterGroup + func (app *App) HEAD(url string, handler ...Handler) *App + func (app *App) Name(name string) + func (app *App) OPTIONS(url string, handler ...Handler) *App + func (app *App) POST(url string, handler ...Handler) *App + func (app *App) PUT(url string, handler ...Handler) *App + type Context struct + Request *http.Request + Response *http.Response + UserValue map[string]interface{} + func NewContext(req *http.Request) *Context + func (ctx *Context) Abort() + func (ctx *Context) AddHeader(key, value string) + func (ctx *Context) BindJSON(data interface{}) error + func (ctx *Context) CheckIfModifiedSince(modtime time.Time) (bool, error) + func (ctx *Context) Cookie(name string) string + func (ctx *Context) Data(code int, contentType string, data []byte) + func (ctx *Context) DataWithHeaders(code int, header map[string]string, data []byte) + func (ctx *Context) FormValue(key string) string + func (ctx *Context) GetContentType() string + func (ctx *Context) HTML(code int, body string) + func (ctx *Context) HTMLByte(code int, body []byte) + func (ctx *Context) Headers(key string) string + func (ctx *Context) IsPjax() bool + func (ctx *Context) JSON(code int, Body map[string]interface{}) + func (ctx *Context) Lang() string + func (ctx *Context) LocalIP() string + func (ctx *Context) Method() string + func (ctx *Context) MustBindJSON(data interface{}) + func (ctx *Context) Next() + func (ctx *Context) Path() string + func (ctx *Context) PjaxUrl(url string) + func (ctx *Context) PostForm() url.Values + func (ctx *Context) Query(key string) string + func (ctx *Context) QueryAll(key string) []string + func (ctx *Context) QueryDefault(key, def string) string + func (ctx *Context) Redirect(path string) + func (ctx *Context) Referer() string + func (ctx *Context) RefererQuery(key string) string + func (ctx *Context) RefererURL() *url.URL + func (ctx *Context) ServeContent(content io.ReadSeeker, filename string, modtime time.Time, ...) error + func (ctx *Context) ServeFile(filename string, gzipCompression bool) error + func (ctx *Context) SetContentType(contentType string) + func (ctx *Context) SetCookie(cookie *http.Cookie) + func (ctx *Context) SetHandlers(handlers Handlers) *Context + func (ctx *Context) SetHeader(key, value string) + func (ctx *Context) SetLastModified(modtime time.Time) + func (ctx *Context) SetStatusCode(code int) + func (ctx *Context) SetUserValue(key string, value interface{}) + func (ctx *Context) User() interface{} + func (ctx *Context) WantHTML() bool + func (ctx *Context) WantJSON() bool + func (ctx *Context) Write(code int, header map[string]string, Body string) + func (ctx *Context) WriteNotModified() + func (ctx *Context) WriteString(body string) + type Handler func(ctx *Context) + type HandlerMap map[Path]Handlers + type Handlers []Handler + type Node struct + Handlers []Handler + Method string + Path string + Value map[string]interface{} + type NodeProcessor func(...Node) + type Path struct + Method string + URL string + type Router struct + Methods []string + Patten string + func (r Router) GetURL(value ...string) string + func (r Router) Method() string + type RouterGroup struct + Middlewares Handlers + Prefix string + func (g *RouterGroup) ANY(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) AppendReqAndResp(url, method string, handler []Handler) + func (g *RouterGroup) DELETE(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) GET(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) Group(prefix string, middleware ...Handler) *RouterGroup + func (g *RouterGroup) HEAD(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) Name(name string) + func (g *RouterGroup) OPTIONS(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) POST(url string, handler ...Handler) *RouterGroup + func (g *RouterGroup) PUT(url string, handler ...Handler) *RouterGroup + type RouterMap map[string]Router + func (r RouterMap) Get(name string) Router Other modules containing this package github.com/betterwithbenji/go-admin