Documentation
¶
Index ¶
- func Cors() gin.HandlerFunc
- func Engine() *gin.Engine
- func InitServer(port int)
- func RegisterPlugin(plugin gin.HandlerFunc)
- func RegisterRoute(path string, method HttpMethod, handler gin.HandlerFunc)
- func RegisterStatic(relativePath string, rootPath string)
- func RegisterStaticFile(relativePath string, filePath string)
- func StartServer()
- type HttpMethod
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitServer ¶
func InitServer(port int)
func RegisterPlugin ¶
func RegisterPlugin(plugin gin.HandlerFunc)
func RegisterRoute ¶
func RegisterRoute(path string, method HttpMethod, handler gin.HandlerFunc)
func RegisterStatic ¶
func RegisterStaticFile ¶
func StartServer ¶
func StartServer()
Types ¶
type HttpMethod ¶
type HttpMethod int
const ( HmAll HttpMethod = iota HmGet HmPost HmPut HmDelete HmOptions HmHead HmGetPost )
Click to show internal directories.
Click to hide internal directories.