annotation-go/annotation.go
2018-09-04 10:15:34 +09:00

21 lines
327 B
Go

package annotation
import (
"regexp"
)
const (
AnnotationTag = "annotation"
NameTag = "@name"
DefaultTag = "@default"
RequiredTag = "@required"
MethodAnnotationPrefix = "_"
)
var (
AnnotationRGX = regexp.MustCompile(`@((?s).*?)\(((?s).*?)\)`)
AnnotationBodyRGX = regexp.MustCompile(`'([^\\\\']|\\')*'`)
)