gfiber

package
v0.6.16-2 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckHeaderParams added in v0.6.17

func CheckHeaderParams(name string, v *string, ctx *fiber.Ctx) bool

func CheckHeaderParamsWithErrorMsg added in v0.6.17

func CheckHeaderParamsWithErrorMsg(name string, v *string, errorMsg string, ctx *fiber.Ctx) bool

func CheckParamsWithErrorMsg added in v0.6.17

func CheckParamsWithErrorMsg(name string, str string, v *string, errorMsg string, ctx *fiber.Ctx) bool

func CheckPostFormParams added in v0.6.17

func CheckPostFormParams(name string, v *string, ctx *fiber.Ctx) bool

func CheckPostFormParamsWithErrorMsg added in v0.6.17

func CheckPostFormParamsWithErrorMsg(name string, v *string, errorMsg string, ctx *fiber.Ctx) bool

func CheckQueryParams added in v0.6.17

func CheckQueryParams(name string, v *string, ctx *fiber.Ctx) bool

func CheckQueryParamsWithErrorMsg added in v0.6.17

func CheckQueryParamsWithErrorMsg(name string, v *string, errorMsg string, ctx *fiber.Ctx) bool

func GetHeader added in v0.6.17

func GetHeader(ctx *fiber.Ctx, key string) string

func NewServer

func NewServer(options server.Options, routerProvider func(engine *fiber.App), middleware ...any) server.Server

func PostFormArray added in v0.6.17

func PostFormArray(ctx *fiber.Ctx, name string) []string

func QueryArray added in v0.6.17

func QueryArray(ctx *fiber.Ctx, name string) []string

func ShouldBindBody

func ShouldBindBody(ctx *fiber.Ctx, obj any) error

ShouldBindBody binds the request body to a struct. It supports decoding the following content types based on the Content-Type header: application/json, application/xml, application/x-www-form-urlencoded, multipart/form-data If none of the content types above are matched, it will return a ErrUnprocessableEntity error

func ShouldBindHeader

func ShouldBindHeader(ctx *fiber.Ctx, obj any) error

func ShouldBindParams

func ShouldBindParams(ctx *fiber.Ctx, obj any) error

func ShouldBindQuery

func ShouldBindQuery(ctx *fiber.Ctx, obj any) error

Types

type Server

type Server struct {
	Srv     *fiber.App
	Options server.Options
}

func (*Server) Run

func (server *Server) Run(graceful func())

func (*Server) Shutdown

func (server *Server) Shutdown()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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