request

package
v0.9.2 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const CONTEXT_CLAIM_KEY = "TOTOVAL_CONTEXT_CLAIM"

Variables

This section is empty.

Functions

func ConvertHandlers

func ConvertHandlers(handlers []HandlerFunc) (ginHandlers []gin.HandlerFunc)

Types

type Context

type Context struct {
	*gin.Context
}

func (*Context) AuthClaimID

func (c *Context) AuthClaimID() (ID uint, exist bool)

func (*Context) SetAuthClaim

func (c *Context) SetAuthClaim(claims *jwt.UserClaims)

type Engine

type Engine struct {
	*gin.Engine
}

func New

func New() *Engine

func (*Engine) GinEngine

func (e *Engine) GinEngine() *gin.Engine

func (*Engine) Use

func (e *Engine) Use(handlers ...HandlerFunc)

func (*Engine) UseGin

func (e *Engine) UseGin(handlerFunc ...gin.HandlerFunc)

type HandlerFunc

type HandlerFunc func(*Context)

Jump to

Keyboard shortcuts

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