feather

package module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 23, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Context

type Context struct {
	// contains filtered or unexported fields
}

func (*Context) GetHeader

func (c *Context) GetHeader(key string) string

func (*Context) Param

func (c *Context) Param(key string) string

func (*Context) ParseForm

func (c *Context) ParseForm() (url.Values, map[string][]*multipart.FileHeader, error)

func (*Context) ParseJSON

func (c *Context) ParseJSON(v any) error

func (*Context) ParseXML

func (c *Context) ParseXML(v any) error

func (*Context) Query

func (c *Context) Query(key string) string

func (*Context) Redirect

func (c *Context) Redirect(code int, url string) error

func (*Context) Request

func (c *Context) Request() *http.Request

func (*Context) Response

func (c *Context) Response() http.ResponseWriter

func (*Context) SendHTML

func (c *Context) SendHTML(code int, html string) error

func (*Context) SendJSON

func (c *Context) SendJSON(code int, v any) error

func (*Context) SendStatus

func (c *Context) SendStatus(code int) error

func (*Context) SendString

func (c *Context) SendString(code int, s string) error

func (*Context) SendXML

func (c *Context) SendXML(code int, v any) error

func (*Context) SetHeader

func (c *Context) SetHeader(key, value string)

func (*Context) Status

func (c *Context) Status() int

func (*Context) Value

func (c *Context) Value(key any) any

func (*Context) WithValue

func (c *Context) WithValue(key, value any)

type ErrorHandler

type ErrorHandler func(err error, c *Context) error

type Feather

type Feather struct {
	// contains filtered or unexported fields
}

func New

func New() *Feather

func (*Feather) Delete

func (f *Feather) Delete(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Get

func (f *Feather) Get(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Group

func (f *Feather) Group(pathPrefix string, groupMiddlewares ...Middleware) *Group

func (*Feather) Head

func (f *Feather) Head(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Listen

func (f *Feather) Listen(listenAddr string) error

func (*Feather) ListenTLS

func (f *Feather) ListenTLS(listenAddr, certFile, keyFile string) error

func (*Feather) Options

func (f *Feather) Options(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Patch

func (f *Feather) Patch(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Post

func (f *Feather) Post(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) Put

func (f *Feather) Put(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Feather) SetErrorHandler

func (f *Feather) SetErrorHandler(errorHandler ErrorHandler)

func (*Feather) Static

func (f *Feather) Static(pathPrefix, root string, routeMiddlewares ...Middleware)

func (*Feather) Use

func (f *Feather) Use(middlewares ...Middleware)

type Group

type Group struct {
	// contains filtered or unexported fields
}

func (*Group) Delete

func (g *Group) Delete(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Get

func (g *Group) Get(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Group

func (g *Group) Group(pathPrefix string, groupMiddlewares ...Middleware) *Group

func (*Group) Head

func (g *Group) Head(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Options

func (g *Group) Options(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Patch

func (g *Group) Patch(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Post

func (g *Group) Post(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Put

func (g *Group) Put(path string, handler Handler, routeMiddlewares ...Middleware)

func (*Group) Static

func (g *Group) Static(pathPrefix, root string, routeMiddlewares ...Middleware)

func (*Group) Use

func (g *Group) Use(middlewares ...Middleware)

type Handler

type Handler func(c *Context) error

type Json

type Json map[string]any

type Middleware

type Middleware func(next Handler) Handler

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL