server/pkg/loafer/web/annotation/request-mapping.go
2019-11-13 23:21:05 +09:00

24 lines
479 B
Go

package annotation
import (
"reflect"
"git.loafle.net/loafer/annotation-go"
)
var RequestMappingAnnotationType = reflect.TypeOf((*RequestMappingAnnotation)(nil))
func init() {
if err := annotation.Register(RequestMappingAnnotationType); nil != err {
panic(err)
}
}
type RequestMappingAnnotation struct {
annotation.TypeAnnotation `@annotation:"@web:RequestMapping"`
Method string `json:"method"`
Entry string `json:"entry"`
Params []string `json:"params"`
}