Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Hook ¶
type Hook interface { // Register with url pattern // Support * wildcard, you can use it like this: // /api/v1/*, and the url like /api/v1/123 will be matched // // Now we support multi urls. Patterns() []string // Priority will set the priority of the hook Priority() int64 // Hooks // BeforeRun will be called before controller, you can do something here BeforeRun(c *gin.Context) // AfterRun will be called after controller, you can do something here AfterRun(c *gin.Context) }
Hook for interceptor.
type Trie ¶
type Trie struct {
// contains filtered or unexported fields
}
Trie is a tree for url.
func (*Trie) InsertBatch ¶
InsertBatch insert urls with hooks.
Click to show internal directories.
Click to hide internal directories.