in pkg/registry/wardle/fischer/etcd.go [29:50]
func NewREST(scheme *runtime.Scheme, optsGetter generic.RESTOptionsGetter) (*registry.REST, error) {
strategy := NewStrategy(scheme)
store := &genericregistry.Store{
NewFunc: func() runtime.Object { return &wardle.Fischer{} },
NewListFunc: func() runtime.Object { return &wardle.FischerList{} },
PredicateFunc: MatchFischer,
DefaultQualifiedResource: wardle.Resource("fischers"),
CreateStrategy: strategy,
UpdateStrategy: strategy,
DeleteStrategy: strategy,
// TODO: define table converter that exposes more than name/creation timestamp
TableConvertor: rest.NewDefaultTableConvertor(wardle.Resource("fischers")),
}
options := &generic.StoreOptions{RESTOptions: optsGetter, AttrFunc: GetAttrs}
if err := store.CompleteWithOptions(options); err != nil {
return nil, err
}
return ®istry.REST{store}, nil
}