route

package
v3.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(eng *gin.Engine, cfg *app.Conf, middlewareGroup []MiddlewareGroup, routesGroup []RoutesGroup)

Register 注册路由

Types

type MiddlewareGroup added in v3.1.0

type MiddlewareGroup struct {
	GroupName  string
	Middleware func(ctx *gin.Context)
}

MiddlewareGroup 中间件分组

type Route

type Route struct {
	Path       string                 // 路由路径
	Controller controller.IController //控制器实例
}

Route 路由

type RoutesGroup

type RoutesGroup struct {
	GroupName string
	Get       []Route
	Post      []Route
}

RoutesGroup 路由分组

Jump to

Keyboard shortcuts

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