ing
This commit is contained in:
parent
9b562b23ea
commit
e9205cada3
10
registry.go
10
registry.go
|
@ -14,11 +14,6 @@ type Registry interface {
|
||||||
Get(f *reflect.StructField) (map[reflect.Type]Annotation, error)
|
Get(f *reflect.StructField) (map[reflect.Type]Annotation, error)
|
||||||
}
|
}
|
||||||
|
|
||||||
var SystemRegistry = &AnnotationRegistry{
|
|
||||||
parent: nil,
|
|
||||||
definitions: make(map[string]*Definition, 0),
|
|
||||||
}
|
|
||||||
|
|
||||||
func New(parent Registry) Registry {
|
func New(parent Registry) Registry {
|
||||||
r := &AnnotationRegistry{
|
r := &AnnotationRegistry{
|
||||||
parent: parent,
|
parent: parent,
|
||||||
|
@ -30,6 +25,11 @@ func New(parent Registry) Registry {
|
||||||
return r
|
return r
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var SystemRegistry = &AnnotationRegistry{
|
||||||
|
parent: nil,
|
||||||
|
definitions: make(map[string]*Definition, 0),
|
||||||
|
}
|
||||||
|
|
||||||
type AnnotationRegistry struct {
|
type AnnotationRegistry struct {
|
||||||
parent Registry
|
parent Registry
|
||||||
definitions map[string]*Definition
|
definitions map[string]*Definition
|
||||||
|
|
Loading…
Reference in New Issue
Block a user