Documentation ¶
Index ¶
- type Engine
- type GinRouterAdapter
- func (gra *GinRouterAdapter) DELETE(relativePath string, handlers ...HandlerFunc)
- func (gra *GinRouterAdapter) GET(relativePath string, handlers ...HandlerFunc)
- func (gra *GinRouterAdapter) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup
- func (gra *GinRouterAdapter) POST(relativePath string, handlers ...HandlerFunc)
- func (gra *GinRouterAdapter) PUT(relativePath string, handlers ...HandlerFunc)
- func (gra *GinRouterAdapter) Static(relativePath, rootPath string)
- type GinRouterGroupAdapter
- func (grga *GinRouterGroupAdapter) DELETE(relativePath string, handlers ...HandlerFunc)
- func (grga *GinRouterGroupAdapter) GET(relativePath string, handlers ...HandlerFunc)
- func (grga *GinRouterGroupAdapter) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup
- func (grga *GinRouterGroupAdapter) POST(relativePath string, handlers ...HandlerFunc)
- func (grga *GinRouterGroupAdapter) PUT(relativePath string, handlers ...HandlerFunc)
- type HandlerFunc
- type IContext
- type IRouter
- type IRouterGroup
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Engine ¶
func NewGinEngine ¶
func NewGinEngine() Engine
type GinRouterAdapter ¶
func (*GinRouterAdapter) DELETE ¶
func (gra *GinRouterAdapter) DELETE(relativePath string, handlers ...HandlerFunc)
func (*GinRouterAdapter) GET ¶
func (gra *GinRouterAdapter) GET(relativePath string, handlers ...HandlerFunc)
func (*GinRouterAdapter) Group ¶
func (gra *GinRouterAdapter) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup
func (*GinRouterAdapter) POST ¶
func (gra *GinRouterAdapter) POST(relativePath string, handlers ...HandlerFunc)
func (*GinRouterAdapter) PUT ¶
func (gra *GinRouterAdapter) PUT(relativePath string, handlers ...HandlerFunc)
func (*GinRouterAdapter) Static ¶
func (gra *GinRouterAdapter) Static(relativePath, rootPath string)
type GinRouterGroupAdapter ¶
type GinRouterGroupAdapter struct {
*gin.RouterGroup
}
func (*GinRouterGroupAdapter) DELETE ¶
func (grga *GinRouterGroupAdapter) DELETE(relativePath string, handlers ...HandlerFunc)
func (*GinRouterGroupAdapter) GET ¶
func (grga *GinRouterGroupAdapter) GET(relativePath string, handlers ...HandlerFunc)
func (*GinRouterGroupAdapter) Group ¶
func (grga *GinRouterGroupAdapter) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup
func (*GinRouterGroupAdapter) POST ¶
func (grga *GinRouterGroupAdapter) POST(relativePath string, handlers ...HandlerFunc)
func (*GinRouterGroupAdapter) PUT ¶
func (grga *GinRouterGroupAdapter) PUT(relativePath string, handlers ...HandlerFunc)
type HandlerFunc ¶
type HandlerFunc func(c IContext)
type IContext ¶
type IContext interface { JSON(code int, obj any) Param(key string) string BindJSON(v interface{}) error ShouldBindJSON(v interface{}) error ShouldBindQuery(v interface{}) error Get(key string) (value interface{}, exists bool) Set(key string, value interface{}) Next() Request() *http.Request Writer() gin.ResponseWriter FullPath() string GetHeader(key string) string Query(key string) string Abort() Header(key, value string) Data(code int, contentType string, data []byte) String(code int, format string, values ...any) GetInt64(key string) int64 FormFile(formName string) (*multipart.FileHeader, error) SaveUploadedFile(file *multipart.FileHeader, dst string) error }
func NewGinContextAdapter ¶
type IRouter ¶
type IRouter interface { GET(relativePath string, handlers ...HandlerFunc) POST(relativePath string, handlers ...HandlerFunc) PUT(relativePath string, handlers ...HandlerFunc) DELETE(relativePath string, handlers ...HandlerFunc) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup Static(relativePath, rootPath string) }
func NewGinRouterAdapter ¶
type IRouterGroup ¶
type IRouterGroup interface { GET(relativePath string, handlers ...HandlerFunc) POST(relativePath string, handlers ...HandlerFunc) PUT(relativePath string, handlers ...HandlerFunc) DELETE(relativePath string, handlers ...HandlerFunc) Group(relativePath string, handlers ...HandlerFunc) IRouterGroup }
Click to show internal directories.
Click to hide internal directories.