1
0
mirror of https://github.com/rancher/types.git synced 2025-09-13 13:33:06 +00:00

Generated changes

This commit is contained in:
Craig Jellick
2017-12-18 14:45:43 -07:00
committed by Darren Shepherd
parent a13c7fffd9
commit 4268be633d
11 changed files with 894 additions and 0 deletions

View File

@@ -147,6 +147,22 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error {
in.(*GithubCredential).DeepCopyInto(out.(*GithubCredential))
return nil
}, InType: reflect.TypeOf(&GithubCredential{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*GlobalRole).DeepCopyInto(out.(*GlobalRole))
return nil
}, InType: reflect.TypeOf(&GlobalRole{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*GlobalRoleBinding).DeepCopyInto(out.(*GlobalRoleBinding))
return nil
}, InType: reflect.TypeOf(&GlobalRoleBinding{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*GlobalRoleBindingList).DeepCopyInto(out.(*GlobalRoleBindingList))
return nil
}, InType: reflect.TypeOf(&GlobalRoleBindingList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*GlobalRoleList).DeepCopyInto(out.(*GlobalRoleList))
return nil
}, InType: reflect.TypeOf(&GlobalRoleList{})},
conversion.GeneratedDeepCopyFunc{Fn: func(in interface{}, out interface{}, c *conversion.Cloner) error {
in.(*GoogleKubernetesEngineConfig).DeepCopyInto(out.(*GoogleKubernetesEngineConfig))
return nil
@@ -1232,6 +1248,136 @@ func (in *GithubCredential) DeepCopy() *GithubCredential {
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GlobalRole) DeepCopyInto(out *GlobalRole) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
if in.Rules != nil {
in, out := &in.Rules, &out.Rules
*out = make([]rbac_v1.PolicyRule, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalRole.
func (in *GlobalRole) DeepCopy() *GlobalRole {
if in == nil {
return nil
}
out := new(GlobalRole)
in.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (in *GlobalRole) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GlobalRoleBinding) DeepCopyInto(out *GlobalRoleBinding) {
*out = *in
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
out.Subject = in.Subject
return
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalRoleBinding.
func (in *GlobalRoleBinding) DeepCopy() *GlobalRoleBinding {
if in == nil {
return nil
}
out := new(GlobalRoleBinding)
in.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (in *GlobalRoleBinding) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GlobalRoleBindingList) DeepCopyInto(out *GlobalRoleBindingList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]GlobalRoleBinding, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalRoleBindingList.
func (in *GlobalRoleBindingList) DeepCopy() *GlobalRoleBindingList {
if in == nil {
return nil
}
out := new(GlobalRoleBindingList)
in.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (in *GlobalRoleBindingList) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GlobalRoleList) DeepCopyInto(out *GlobalRoleList) {
*out = *in
out.TypeMeta = in.TypeMeta
out.ListMeta = in.ListMeta
if in.Items != nil {
in, out := &in.Items, &out.Items
*out = make([]GlobalRole, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
return
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalRoleList.
func (in *GlobalRoleList) DeepCopy() *GlobalRoleList {
if in == nil {
return nil
}
out := new(GlobalRoleList)
in.DeepCopyInto(out)
return out
}
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (in *GlobalRoleList) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
} else {
return nil
}
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *GoogleKubernetesEngineConfig) DeepCopyInto(out *GoogleKubernetesEngineConfig) {
*out = *in

View File

@@ -0,0 +1,204 @@
package v3
import (
"context"
"github.com/rancher/norman/clientbase"
"github.com/rancher/norman/controller"
"k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/apimachinery/pkg/watch"
"k8s.io/client-go/tools/cache"
)
var (
GlobalRoleBindingGroupVersionKind = schema.GroupVersionKind{
Version: Version,
Group: GroupName,
Kind: "GlobalRoleBinding",
}
GlobalRoleBindingResource = metav1.APIResource{
Name: "globalrolebindings",
SingularName: "globalrolebinding",
Namespaced: false,
Kind: GlobalRoleBindingGroupVersionKind.Kind,
}
)
type GlobalRoleBindingList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []GlobalRoleBinding
}
type GlobalRoleBindingHandlerFunc func(key string, obj *GlobalRoleBinding) error
type GlobalRoleBindingLister interface {
List(namespace string, selector labels.Selector) (ret []*GlobalRoleBinding, err error)
Get(namespace, name string) (*GlobalRoleBinding, error)
}
type GlobalRoleBindingController interface {
Informer() cache.SharedIndexInformer
Lister() GlobalRoleBindingLister
AddHandler(handler GlobalRoleBindingHandlerFunc)
Enqueue(namespace, name string)
Sync(ctx context.Context) error
Start(ctx context.Context, threadiness int) error
}
type GlobalRoleBindingInterface interface {
ObjectClient() *clientbase.ObjectClient
Create(*GlobalRoleBinding) (*GlobalRoleBinding, error)
Get(name string, opts metav1.GetOptions) (*GlobalRoleBinding, error)
Update(*GlobalRoleBinding) (*GlobalRoleBinding, error)
Delete(name string, options *metav1.DeleteOptions) error
List(opts metav1.ListOptions) (*GlobalRoleBindingList, error)
Watch(opts metav1.ListOptions) (watch.Interface, error)
DeleteCollection(deleteOpts *metav1.DeleteOptions, listOpts metav1.ListOptions) error
Controller() GlobalRoleBindingController
AddSyncHandler(sync GlobalRoleBindingHandlerFunc)
AddLifecycle(name string, lifecycle GlobalRoleBindingLifecycle)
}
type globalRoleBindingLister struct {
controller *globalRoleBindingController
}
func (l *globalRoleBindingLister) List(namespace string, selector labels.Selector) (ret []*GlobalRoleBinding, err error) {
err = cache.ListAllByNamespace(l.controller.Informer().GetIndexer(), namespace, selector, func(obj interface{}) {
ret = append(ret, obj.(*GlobalRoleBinding))
})
return
}
func (l *globalRoleBindingLister) Get(namespace, name string) (*GlobalRoleBinding, error) {
var key string
if namespace != "" {
key = namespace + "/" + name
} else {
key = name
}
obj, exists, err := l.controller.Informer().GetIndexer().GetByKey(key)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(schema.GroupResource{
Group: GlobalRoleBindingGroupVersionKind.Group,
Resource: "globalRoleBinding",
}, name)
}
return obj.(*GlobalRoleBinding), nil
}
type globalRoleBindingController struct {
controller.GenericController
}
func (c *globalRoleBindingController) Lister() GlobalRoleBindingLister {
return &globalRoleBindingLister{
controller: c,
}
}
func (c *globalRoleBindingController) AddHandler(handler GlobalRoleBindingHandlerFunc) {
c.GenericController.AddHandler(func(key string) error {
obj, exists, err := c.Informer().GetStore().GetByKey(key)
if err != nil {
return err
}
if !exists {
return handler(key, nil)
}
return handler(key, obj.(*GlobalRoleBinding))
})
}
type globalRoleBindingFactory struct {
}
func (c globalRoleBindingFactory) Object() runtime.Object {
return &GlobalRoleBinding{}
}
func (c globalRoleBindingFactory) List() runtime.Object {
return &GlobalRoleBindingList{}
}
func (s *globalRoleBindingClient) Controller() GlobalRoleBindingController {
s.client.Lock()
defer s.client.Unlock()
c, ok := s.client.globalRoleBindingControllers[s.ns]
if ok {
return c
}
genericController := controller.NewGenericController(GlobalRoleBindingGroupVersionKind.Kind+"Controller",
s.objectClient)
c = &globalRoleBindingController{
GenericController: genericController,
}
s.client.globalRoleBindingControllers[s.ns] = c
s.client.starters = append(s.client.starters, c)
return c
}
type globalRoleBindingClient struct {
client *Client
ns string
objectClient *clientbase.ObjectClient
controller GlobalRoleBindingController
}
func (s *globalRoleBindingClient) ObjectClient() *clientbase.ObjectClient {
return s.objectClient
}
func (s *globalRoleBindingClient) Create(o *GlobalRoleBinding) (*GlobalRoleBinding, error) {
obj, err := s.objectClient.Create(o)
return obj.(*GlobalRoleBinding), err
}
func (s *globalRoleBindingClient) Get(name string, opts metav1.GetOptions) (*GlobalRoleBinding, error) {
obj, err := s.objectClient.Get(name, opts)
return obj.(*GlobalRoleBinding), err
}
func (s *globalRoleBindingClient) Update(o *GlobalRoleBinding) (*GlobalRoleBinding, error) {
obj, err := s.objectClient.Update(o.Name, o)
return obj.(*GlobalRoleBinding), err
}
func (s *globalRoleBindingClient) Delete(name string, options *metav1.DeleteOptions) error {
return s.objectClient.Delete(name, options)
}
func (s *globalRoleBindingClient) List(opts metav1.ListOptions) (*GlobalRoleBindingList, error) {
obj, err := s.objectClient.List(opts)
return obj.(*GlobalRoleBindingList), err
}
func (s *globalRoleBindingClient) Watch(opts metav1.ListOptions) (watch.Interface, error) {
return s.objectClient.Watch(opts)
}
func (s *globalRoleBindingClient) DeleteCollection(deleteOpts *metav1.DeleteOptions, listOpts metav1.ListOptions) error {
return s.objectClient.DeleteCollection(deleteOpts, listOpts)
}
func (s *globalRoleBindingClient) AddSyncHandler(sync GlobalRoleBindingHandlerFunc) {
s.Controller().AddHandler(sync)
}
func (s *globalRoleBindingClient) AddLifecycle(name string, lifecycle GlobalRoleBindingLifecycle) {
sync := NewGlobalRoleBindingLifecycleAdapter(name, s, lifecycle)
s.AddSyncHandler(sync)
}

View File

@@ -0,0 +1,51 @@
package v3
import (
"github.com/rancher/norman/lifecycle"
"k8s.io/apimachinery/pkg/runtime"
)
type GlobalRoleBindingLifecycle interface {
Create(obj *GlobalRoleBinding) (*GlobalRoleBinding, error)
Remove(obj *GlobalRoleBinding) (*GlobalRoleBinding, error)
Updated(obj *GlobalRoleBinding) (*GlobalRoleBinding, error)
}
type globalRoleBindingLifecycleAdapter struct {
lifecycle GlobalRoleBindingLifecycle
}
func (w *globalRoleBindingLifecycleAdapter) Create(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Create(obj.(*GlobalRoleBinding))
if o == nil {
return nil, err
}
return o, err
}
func (w *globalRoleBindingLifecycleAdapter) Finalize(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Remove(obj.(*GlobalRoleBinding))
if o == nil {
return nil, err
}
return o, err
}
func (w *globalRoleBindingLifecycleAdapter) Updated(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Updated(obj.(*GlobalRoleBinding))
if o == nil {
return nil, err
}
return o, err
}
func NewGlobalRoleBindingLifecycleAdapter(name string, client GlobalRoleBindingInterface, l GlobalRoleBindingLifecycle) GlobalRoleBindingHandlerFunc {
adapter := &globalRoleBindingLifecycleAdapter{lifecycle: l}
syncFn := lifecycle.NewObjectLifecycleAdapter(name, adapter, client.ObjectClient())
return func(key string, obj *GlobalRoleBinding) error {
if obj == nil {
return syncFn(key, nil)
}
return syncFn(key, obj)
}
}

View File

@@ -0,0 +1,204 @@
package v3
import (
"context"
"github.com/rancher/norman/clientbase"
"github.com/rancher/norman/controller"
"k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/apimachinery/pkg/watch"
"k8s.io/client-go/tools/cache"
)
var (
GlobalRoleGroupVersionKind = schema.GroupVersionKind{
Version: Version,
Group: GroupName,
Kind: "GlobalRole",
}
GlobalRoleResource = metav1.APIResource{
Name: "globalroles",
SingularName: "globalrole",
Namespaced: false,
Kind: GlobalRoleGroupVersionKind.Kind,
}
)
type GlobalRoleList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []GlobalRole
}
type GlobalRoleHandlerFunc func(key string, obj *GlobalRole) error
type GlobalRoleLister interface {
List(namespace string, selector labels.Selector) (ret []*GlobalRole, err error)
Get(namespace, name string) (*GlobalRole, error)
}
type GlobalRoleController interface {
Informer() cache.SharedIndexInformer
Lister() GlobalRoleLister
AddHandler(handler GlobalRoleHandlerFunc)
Enqueue(namespace, name string)
Sync(ctx context.Context) error
Start(ctx context.Context, threadiness int) error
}
type GlobalRoleInterface interface {
ObjectClient() *clientbase.ObjectClient
Create(*GlobalRole) (*GlobalRole, error)
Get(name string, opts metav1.GetOptions) (*GlobalRole, error)
Update(*GlobalRole) (*GlobalRole, error)
Delete(name string, options *metav1.DeleteOptions) error
List(opts metav1.ListOptions) (*GlobalRoleList, error)
Watch(opts metav1.ListOptions) (watch.Interface, error)
DeleteCollection(deleteOpts *metav1.DeleteOptions, listOpts metav1.ListOptions) error
Controller() GlobalRoleController
AddSyncHandler(sync GlobalRoleHandlerFunc)
AddLifecycle(name string, lifecycle GlobalRoleLifecycle)
}
type globalRoleLister struct {
controller *globalRoleController
}
func (l *globalRoleLister) List(namespace string, selector labels.Selector) (ret []*GlobalRole, err error) {
err = cache.ListAllByNamespace(l.controller.Informer().GetIndexer(), namespace, selector, func(obj interface{}) {
ret = append(ret, obj.(*GlobalRole))
})
return
}
func (l *globalRoleLister) Get(namespace, name string) (*GlobalRole, error) {
var key string
if namespace != "" {
key = namespace + "/" + name
} else {
key = name
}
obj, exists, err := l.controller.Informer().GetIndexer().GetByKey(key)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(schema.GroupResource{
Group: GlobalRoleGroupVersionKind.Group,
Resource: "globalRole",
}, name)
}
return obj.(*GlobalRole), nil
}
type globalRoleController struct {
controller.GenericController
}
func (c *globalRoleController) Lister() GlobalRoleLister {
return &globalRoleLister{
controller: c,
}
}
func (c *globalRoleController) AddHandler(handler GlobalRoleHandlerFunc) {
c.GenericController.AddHandler(func(key string) error {
obj, exists, err := c.Informer().GetStore().GetByKey(key)
if err != nil {
return err
}
if !exists {
return handler(key, nil)
}
return handler(key, obj.(*GlobalRole))
})
}
type globalRoleFactory struct {
}
func (c globalRoleFactory) Object() runtime.Object {
return &GlobalRole{}
}
func (c globalRoleFactory) List() runtime.Object {
return &GlobalRoleList{}
}
func (s *globalRoleClient) Controller() GlobalRoleController {
s.client.Lock()
defer s.client.Unlock()
c, ok := s.client.globalRoleControllers[s.ns]
if ok {
return c
}
genericController := controller.NewGenericController(GlobalRoleGroupVersionKind.Kind+"Controller",
s.objectClient)
c = &globalRoleController{
GenericController: genericController,
}
s.client.globalRoleControllers[s.ns] = c
s.client.starters = append(s.client.starters, c)
return c
}
type globalRoleClient struct {
client *Client
ns string
objectClient *clientbase.ObjectClient
controller GlobalRoleController
}
func (s *globalRoleClient) ObjectClient() *clientbase.ObjectClient {
return s.objectClient
}
func (s *globalRoleClient) Create(o *GlobalRole) (*GlobalRole, error) {
obj, err := s.objectClient.Create(o)
return obj.(*GlobalRole), err
}
func (s *globalRoleClient) Get(name string, opts metav1.GetOptions) (*GlobalRole, error) {
obj, err := s.objectClient.Get(name, opts)
return obj.(*GlobalRole), err
}
func (s *globalRoleClient) Update(o *GlobalRole) (*GlobalRole, error) {
obj, err := s.objectClient.Update(o.Name, o)
return obj.(*GlobalRole), err
}
func (s *globalRoleClient) Delete(name string, options *metav1.DeleteOptions) error {
return s.objectClient.Delete(name, options)
}
func (s *globalRoleClient) List(opts metav1.ListOptions) (*GlobalRoleList, error) {
obj, err := s.objectClient.List(opts)
return obj.(*GlobalRoleList), err
}
func (s *globalRoleClient) Watch(opts metav1.ListOptions) (watch.Interface, error) {
return s.objectClient.Watch(opts)
}
func (s *globalRoleClient) DeleteCollection(deleteOpts *metav1.DeleteOptions, listOpts metav1.ListOptions) error {
return s.objectClient.DeleteCollection(deleteOpts, listOpts)
}
func (s *globalRoleClient) AddSyncHandler(sync GlobalRoleHandlerFunc) {
s.Controller().AddHandler(sync)
}
func (s *globalRoleClient) AddLifecycle(name string, lifecycle GlobalRoleLifecycle) {
sync := NewGlobalRoleLifecycleAdapter(name, s, lifecycle)
s.AddSyncHandler(sync)
}

View File

@@ -0,0 +1,51 @@
package v3
import (
"github.com/rancher/norman/lifecycle"
"k8s.io/apimachinery/pkg/runtime"
)
type GlobalRoleLifecycle interface {
Create(obj *GlobalRole) (*GlobalRole, error)
Remove(obj *GlobalRole) (*GlobalRole, error)
Updated(obj *GlobalRole) (*GlobalRole, error)
}
type globalRoleLifecycleAdapter struct {
lifecycle GlobalRoleLifecycle
}
func (w *globalRoleLifecycleAdapter) Create(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Create(obj.(*GlobalRole))
if o == nil {
return nil, err
}
return o, err
}
func (w *globalRoleLifecycleAdapter) Finalize(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Remove(obj.(*GlobalRole))
if o == nil {
return nil, err
}
return o, err
}
func (w *globalRoleLifecycleAdapter) Updated(obj runtime.Object) (runtime.Object, error) {
o, err := w.lifecycle.Updated(obj.(*GlobalRole))
if o == nil {
return nil, err
}
return o, err
}
func NewGlobalRoleLifecycleAdapter(name string, client GlobalRoleInterface, l GlobalRoleLifecycle) GlobalRoleHandlerFunc {
adapter := &globalRoleLifecycleAdapter{lifecycle: l}
syncFn := lifecycle.NewObjectLifecycleAdapter(name, adapter, client.ObjectClient())
return func(key string, obj *GlobalRole) error {
if obj == nil {
return syncFn(key, nil)
}
return syncFn(key, obj)
}
}

View File

@@ -18,6 +18,8 @@ type Interface interface {
MachineDriversGetter
MachineTemplatesGetter
ProjectsGetter
GlobalRolesGetter
GlobalRoleBindingsGetter
RoleTemplatesGetter
PodSecurityPolicyTemplatesGetter
ClusterRoleTemplateBindingsGetter
@@ -45,6 +47,8 @@ type Client struct {
machineDriverControllers map[string]MachineDriverController
machineTemplateControllers map[string]MachineTemplateController
projectControllers map[string]ProjectController
globalRoleControllers map[string]GlobalRoleController
globalRoleBindingControllers map[string]GlobalRoleBindingController
roleTemplateControllers map[string]RoleTemplateController
podSecurityPolicyTemplateControllers map[string]PodSecurityPolicyTemplateController
clusterRoleTemplateBindingControllers map[string]ClusterRoleTemplateBindingController
@@ -81,6 +85,8 @@ func NewForConfig(config rest.Config) (Interface, error) {
machineDriverControllers: map[string]MachineDriverController{},
machineTemplateControllers: map[string]MachineTemplateController{},
projectControllers: map[string]ProjectController{},
globalRoleControllers: map[string]GlobalRoleController{},
globalRoleBindingControllers: map[string]GlobalRoleBindingController{},
roleTemplateControllers: map[string]RoleTemplateController{},
podSecurityPolicyTemplateControllers: map[string]PodSecurityPolicyTemplateController{},
clusterRoleTemplateBindingControllers: map[string]ClusterRoleTemplateBindingController{},
@@ -164,6 +170,32 @@ func (c *Client) Projects(namespace string) ProjectInterface {
}
}
type GlobalRolesGetter interface {
GlobalRoles(namespace string) GlobalRoleInterface
}
func (c *Client) GlobalRoles(namespace string) GlobalRoleInterface {
objectClient := clientbase.NewObjectClient(namespace, c.restClient, &GlobalRoleResource, GlobalRoleGroupVersionKind, globalRoleFactory{})
return &globalRoleClient{
ns: namespace,
client: c,
objectClient: objectClient,
}
}
type GlobalRoleBindingsGetter interface {
GlobalRoleBindings(namespace string) GlobalRoleBindingInterface
}
func (c *Client) GlobalRoleBindings(namespace string) GlobalRoleBindingInterface {
objectClient := clientbase.NewObjectClient(namespace, c.restClient, &GlobalRoleBindingResource, GlobalRoleBindingGroupVersionKind, globalRoleBindingFactory{})
return &globalRoleBindingClient{
ns: namespace,
client: c,
objectClient: objectClient,
}
}
type RoleTemplatesGetter interface {
RoleTemplates(namespace string) RoleTemplateInterface
}

View File

@@ -41,6 +41,10 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&MachineTemplateList{},
&Project{},
&ProjectList{},
&GlobalRole{},
&GlobalRoleList{},
&GlobalRoleBinding{},
&GlobalRoleBindingList{},
&RoleTemplate{},
&RoleTemplateList{},
&PodSecurityPolicyTemplate{},