-
Notifications
You must be signed in to change notification settings - Fork 0
/
intf.go
43 lines (33 loc) · 696 Bytes
/
intf.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package kapi
// Interceptor implement this to intercept controller method
type Interceptor interface {
Before(*Context)
After(*Context)
}
type HeaderAuth interface {
HeaderAuth(c *Context)
}
type BeforeBind interface {
BeforeBind(c *Context)
}
type AfterBind interface {
AfterBind(c *Context)
}
type BeforeCall interface {
BeforeCall(c *Context)
}
type AfterCall interface {
AfterCall(c *Context)
}
type OnPanic interface {
OnPanic(c *Context, err interface{})
}
type OnError interface {
OnError(c *Context, err error)
}
type OnValidationError interface {
OnValidationError(c *Context, err error)
}
type OnUnmarshalError interface {
OnUnmarshalError(c *Context, err error)
}