update staging clients

This commit is contained in:
Michal Fojtik 2017-07-19 12:53:56 +02:00
parent dad4ee3108
commit d8a42416a6
No known key found for this signature in database
GPG Key ID: 172B61E538AAC0EE
90 changed files with 3452 additions and 3452 deletions

View File

@ -56,6 +56,38 @@ func newExternalAdmissionHookConfigurations(c *AdmissionregistrationV1alpha1Clie
}
}
// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any.
func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
result = &v1alpha1.ExternalAdmissionHookConfiguration{}
err = c.client.Get().
Resource("externaladmissionhookconfigurations").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors.
func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) {
result = &v1alpha1.ExternalAdmissionHookConfigurationList{}
err = c.client.Get().
Resource("externaladmissionhookconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations.
func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("externaladmissionhookconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a externalAdmissionHookConfiguration and creates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any.
func (c *externalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
result = &v1alpha1.ExternalAdmissionHookConfiguration{}
@ -99,38 +131,6 @@ func (c *externalAdmissionHookConfigurations) DeleteCollection(options *v1.Delet
Error()
}
// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any.
func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
result = &v1alpha1.ExternalAdmissionHookConfiguration{}
err = c.client.Get().
Resource("externaladmissionhookconfigurations").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors.
func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) {
result = &v1alpha1.ExternalAdmissionHookConfigurationList{}
err = c.client.Get().
Resource("externaladmissionhookconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations.
func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("externaladmissionhookconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched externalAdmissionHookConfiguration.
func (c *externalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
result = &v1alpha1.ExternalAdmissionHookConfiguration{}

View File

@ -35,37 +35,6 @@ var externaladmissionhookconfigurationsResource = schema.GroupVersionResource{Gr
var externaladmissionhookconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "ExternalAdmissionHookConfiguration"}
func (c *FakeExternalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(externaladmissionhookconfigurationsResource, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err
}
func (c *FakeExternalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(externaladmissionhookconfigurationsResource, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err
}
func (c *FakeExternalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(externaladmissionhookconfigurationsResource, name), &v1alpha1.ExternalAdmissionHookConfiguration{})
return err
}
func (c *FakeExternalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(externaladmissionhookconfigurationsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ExternalAdmissionHookConfigurationList{})
return err
}
func (c *FakeExternalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(externaladmissionhookconfigurationsResource, name), &v1alpha1.ExternalAdmissionHookConfiguration{})
@ -101,6 +70,37 @@ func (c *FakeExternalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (wa
InvokesWatch(testing.NewRootWatchAction(externaladmissionhookconfigurationsResource, opts))
}
func (c *FakeExternalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(externaladmissionhookconfigurationsResource, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err
}
func (c *FakeExternalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(externaladmissionhookconfigurationsResource, externalAdmissionHookConfiguration), &v1alpha1.ExternalAdmissionHookConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ExternalAdmissionHookConfiguration), err
}
func (c *FakeExternalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(externaladmissionhookconfigurationsResource, name), &v1alpha1.ExternalAdmissionHookConfiguration{})
return err
}
func (c *FakeExternalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(externaladmissionhookconfigurationsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ExternalAdmissionHookConfigurationList{})
return err
}
// Patch applies the patch and returns the patched externalAdmissionHookConfiguration.
func (c *FakeExternalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) {
obj, err := c.Fake.

View File

@ -35,37 +35,6 @@ var initializerconfigurationsResource = schema.GroupVersionResource{Group: "admi
var initializerconfigurationsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "InitializerConfiguration"}
func (c *FakeInitializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(initializerconfigurationsResource, initializerConfiguration), &v1alpha1.InitializerConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.InitializerConfiguration), err
}
func (c *FakeInitializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(initializerconfigurationsResource, initializerConfiguration), &v1alpha1.InitializerConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.InitializerConfiguration), err
}
func (c *FakeInitializerConfigurations) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(initializerconfigurationsResource, name), &v1alpha1.InitializerConfiguration{})
return err
}
func (c *FakeInitializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(initializerconfigurationsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.InitializerConfigurationList{})
return err
}
func (c *FakeInitializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(initializerconfigurationsResource, name), &v1alpha1.InitializerConfiguration{})
@ -101,6 +70,37 @@ func (c *FakeInitializerConfigurations) Watch(opts v1.ListOptions) (watch.Interf
InvokesWatch(testing.NewRootWatchAction(initializerconfigurationsResource, opts))
}
func (c *FakeInitializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(initializerconfigurationsResource, initializerConfiguration), &v1alpha1.InitializerConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.InitializerConfiguration), err
}
func (c *FakeInitializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(initializerconfigurationsResource, initializerConfiguration), &v1alpha1.InitializerConfiguration{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.InitializerConfiguration), err
}
func (c *FakeInitializerConfigurations) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(initializerconfigurationsResource, name), &v1alpha1.InitializerConfiguration{})
return err
}
func (c *FakeInitializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(initializerconfigurationsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.InitializerConfigurationList{})
return err
}
// Patch applies the patch and returns the patched initializerConfiguration.
func (c *FakeInitializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) {
obj, err := c.Fake.

View File

@ -56,6 +56,38 @@ func newInitializerConfigurations(c *AdmissionregistrationV1alpha1Client) *initi
}
}
// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any.
func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) {
result = &v1alpha1.InitializerConfiguration{}
err = c.client.Get().
Resource("initializerconfigurations").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors.
func (c *initializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) {
result = &v1alpha1.InitializerConfigurationList{}
err = c.client.Get().
Resource("initializerconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested initializerConfigurations.
func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("initializerconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a initializerConfiguration and creates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any.
func (c *initializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) {
result = &v1alpha1.InitializerConfiguration{}
@ -99,38 +131,6 @@ func (c *initializerConfigurations) DeleteCollection(options *v1.DeleteOptions,
Error()
}
// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any.
func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) {
result = &v1alpha1.InitializerConfiguration{}
err = c.client.Get().
Resource("initializerconfigurations").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors.
func (c *initializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) {
result = &v1alpha1.InitializerConfigurationList{}
err = c.client.Get().
Resource("initializerconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested initializerConfigurations.
func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("initializerconfigurations").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched initializerConfiguration.
func (c *initializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) {
result = &v1alpha1.InitializerConfiguration{}

View File

@ -58,6 +58,41 @@ func newControllerRevisions(c *AppsV1beta1Client, namespace string) *controllerR
}
}
// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any.
func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) {
result = &v1beta1.ControllerRevision{}
err = c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors.
func (c *controllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) {
result = &v1beta1.ControllerRevisionList{}
err = c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested controllerRevisions.
func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a controllerRevision and creates it. Returns the server's representation of the controllerRevision, and an error, if there is any.
func (c *controllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) {
result = &v1beta1.ControllerRevision{}
@ -105,41 +140,6 @@ func (c *controllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOp
Error()
}
// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any.
func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) {
result = &v1beta1.ControllerRevision{}
err = c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors.
func (c *controllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) {
result = &v1beta1.ControllerRevisionList{}
err = c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested controllerRevisions.
func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("controllerrevisions").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched controllerRevision.
func (c *controllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) {
result = &v1beta1.ControllerRevision{}

View File

@ -59,6 +59,41 @@ func newDeployments(c *AppsV1beta1Client, namespace string) *deployments {
}
}
// Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any.
func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Deployments that match those selectors.
func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
result = &v1beta1.DeploymentList{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a deployment and creates it. Returns the server's representation of the deployment, and an error, if there is any.
func (c *deployments) Create(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
@ -85,7 +120,7 @@ func (c *deployments) Update(deployment *v1beta1.Deployment) (result *v1beta1.De
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *deployments) UpdateStatus(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
@ -122,41 +157,6 @@ func (c *deployments) DeleteCollection(options *v1.DeleteOptions, listOptions v1
Error()
}
// Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any.
func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Deployments that match those selectors.
func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
result = &v1beta1.DeploymentList{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched deployment.
func (c *deployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}

View File

@ -36,40 +36,6 @@ var controllerrevisionsResource = schema.GroupVersionResource{Group: "apps", Ver
var controllerrevisionsKind = schema.GroupVersionKind{Group: "apps", Version: "v1beta1", Kind: "ControllerRevision"}
func (c *FakeControllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ControllerRevision), err
}
func (c *FakeControllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ControllerRevision), err
}
func (c *FakeControllerRevisions) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{})
return err
}
func (c *FakeControllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(controllerrevisionsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ControllerRevisionList{})
return err
}
func (c *FakeControllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{})
@ -108,6 +74,40 @@ func (c *FakeControllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, e
}
func (c *FakeControllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ControllerRevision), err
}
func (c *FakeControllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(controllerrevisionsResource, c.ns, controllerRevision), &v1beta1.ControllerRevision{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ControllerRevision), err
}
func (c *FakeControllerRevisions) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(controllerrevisionsResource, c.ns, name), &v1beta1.ControllerRevision{})
return err
}
func (c *FakeControllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(controllerrevisionsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ControllerRevisionList{})
return err
}
// Patch applies the patch and returns the patched controllerRevision.
func (c *FakeControllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) {
obj, err := c.Fake.

View File

@ -36,6 +36,44 @@ var deploymentsResource = schema.GroupVersionResource{Group: "apps", Version: "v
var deploymentsKind = schema.GroupVersionKind{Group: "apps", Version: "v1beta1", Kind: "Deployment"}
func (c *FakeDeployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(deploymentsResource, c.ns, name), &v1beta1.Deployment{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Deployment), err
}
func (c *FakeDeployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(deploymentsResource, deploymentsKind, c.ns, opts), &v1beta1.DeploymentList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DeploymentList{}
for _, item := range obj.(*v1beta1.DeploymentList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *FakeDeployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(deploymentsResource, c.ns, opts))
}
func (c *FakeDeployments) Create(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(deploymentsResource, c.ns, deployment), &v1beta1.Deployment{})
@ -80,44 +118,6 @@ func (c *FakeDeployments) DeleteCollection(options *v1.DeleteOptions, listOption
return err
}
func (c *FakeDeployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(deploymentsResource, c.ns, name), &v1beta1.Deployment{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Deployment), err
}
func (c *FakeDeployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(deploymentsResource, deploymentsKind, c.ns, opts), &v1beta1.DeploymentList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DeploymentList{}
for _, item := range obj.(*v1beta1.DeploymentList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *FakeDeployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(deploymentsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched deployment.
func (c *FakeDeployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.

View File

@ -36,6 +36,44 @@ var statefulsetsResource = schema.GroupVersionResource{Group: "apps", Version: "
var statefulsetsKind = schema.GroupVersionKind{Group: "apps", Version: "v1beta1", Kind: "StatefulSet"}
func (c *FakeStatefulSets) Get(name string, options v1.GetOptions) (result *v1beta1.StatefulSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(statefulsetsResource, c.ns, name), &v1beta1.StatefulSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StatefulSet), err
}
func (c *FakeStatefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(statefulsetsResource, statefulsetsKind, c.ns, opts), &v1beta1.StatefulSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.StatefulSetList{}
for _, item := range obj.(*v1beta1.StatefulSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested statefulSets.
func (c *FakeStatefulSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(statefulsetsResource, c.ns, opts))
}
func (c *FakeStatefulSets) Create(statefulSet *v1beta1.StatefulSet) (result *v1beta1.StatefulSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(statefulsetsResource, c.ns, statefulSet), &v1beta1.StatefulSet{})
@ -80,44 +118,6 @@ func (c *FakeStatefulSets) DeleteCollection(options *v1.DeleteOptions, listOptio
return err
}
func (c *FakeStatefulSets) Get(name string, options v1.GetOptions) (result *v1beta1.StatefulSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(statefulsetsResource, c.ns, name), &v1beta1.StatefulSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StatefulSet), err
}
func (c *FakeStatefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(statefulsetsResource, statefulsetsKind, c.ns, opts), &v1beta1.StatefulSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.StatefulSetList{}
for _, item := range obj.(*v1beta1.StatefulSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested statefulSets.
func (c *FakeStatefulSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(statefulsetsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched statefulSet.
func (c *FakeStatefulSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) {
obj, err := c.Fake.

View File

@ -59,6 +59,41 @@ func newStatefulSets(c *AppsV1beta1Client, namespace string) *statefulSets {
}
}
// Get takes name of the statefulSet, and returns the corresponding statefulSet object, and an error if there is any.
func (c *statefulSets) Get(name string, options v1.GetOptions) (result *v1beta1.StatefulSet, err error) {
result = &v1beta1.StatefulSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StatefulSets that match those selectors.
func (c *statefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetList, err error) {
result = &v1beta1.StatefulSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested statefulSets.
func (c *statefulSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a statefulSet and creates it. Returns the server's representation of the statefulSet, and an error, if there is any.
func (c *statefulSets) Create(statefulSet *v1beta1.StatefulSet) (result *v1beta1.StatefulSet, err error) {
result = &v1beta1.StatefulSet{}
@ -85,7 +120,7 @@ func (c *statefulSets) Update(statefulSet *v1beta1.StatefulSet) (result *v1beta1
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *statefulSets) UpdateStatus(statefulSet *v1beta1.StatefulSet) (result *v1beta1.StatefulSet, err error) {
result = &v1beta1.StatefulSet{}
@ -122,41 +157,6 @@ func (c *statefulSets) DeleteCollection(options *v1.DeleteOptions, listOptions v
Error()
}
// Get takes name of the statefulSet, and returns the corresponding statefulSet object, and an error if there is any.
func (c *statefulSets) Get(name string, options v1.GetOptions) (result *v1beta1.StatefulSet, err error) {
result = &v1beta1.StatefulSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StatefulSets that match those selectors.
func (c *statefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetList, err error) {
result = &v1beta1.StatefulSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested statefulSets.
func (c *statefulSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("statefulsets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched statefulSet.
func (c *statefulSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) {
result = &v1beta1.StatefulSet{}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/autoscaling/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
autoscaling_v1 "k8s.io/api/autoscaling/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var horizontalpodautoscalersResource = schema.GroupVersionResource{Group: "autos
var horizontalpodautoscalersKind = schema.GroupVersionKind{Group: "autoscaling", Version: "v1", Kind: "HorizontalPodAutoscaler"}
func (c *FakeHorizontalPodAutoscalers) Create(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (result *v1.HorizontalPodAutoscaler, err error) {
func (c *FakeHorizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *autoscaling_v1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(horizontalpodautoscalersResource, c.ns, horizontalPodAutoscaler), &v1.HorizontalPodAutoscaler{})
Invokes(testing.NewGetAction(horizontalpodautoscalersResource, c.ns, name), &autoscaling_v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v1.HorizontalPodAutoscaler), err
return obj.(*autoscaling_v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) Update(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (result *v1.HorizontalPodAutoscaler, err error) {
func (c *FakeHorizontalPodAutoscalers) List(opts v1.ListOptions) (result *autoscaling_v1.HorizontalPodAutoscalerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(horizontalpodautoscalersResource, c.ns, horizontalPodAutoscaler), &v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (*v1.HorizontalPodAutoscaler, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(horizontalpodautoscalersResource, "status", c.ns, horizontalPodAutoscaler), &v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(horizontalpodautoscalersResource, c.ns, name), &v1.HorizontalPodAutoscaler{})
return err
}
func (c *FakeHorizontalPodAutoscalers) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(horizontalpodautoscalersResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.HorizontalPodAutoscalerList{})
return err
}
func (c *FakeHorizontalPodAutoscalers) Get(name string, options meta_v1.GetOptions) (result *v1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(horizontalpodautoscalersResource, c.ns, name), &v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v1.HorizontalPodAutoscalerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(horizontalpodautoscalersResource, horizontalpodautoscalersKind, c.ns, opts), &v1.HorizontalPodAutoscalerList{})
Invokes(testing.NewListAction(horizontalpodautoscalersResource, horizontalpodautoscalersKind, c.ns, opts), &autoscaling_v1.HorizontalPodAutoscalerList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakeHorizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v
if label == nil {
label = labels.Everything()
}
list := &v1.HorizontalPodAutoscalerList{}
for _, item := range obj.(*v1.HorizontalPodAutoscalerList).Items {
list := &autoscaling_v1.HorizontalPodAutoscalerList{}
for _, item := range obj.(*autoscaling_v1.HorizontalPodAutoscalerList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakeHorizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *FakeHorizontalPodAutoscalers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeHorizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(horizontalpodautoscalersResource, c.ns, opts))
}
// Patch applies the patch and returns the patched horizontalPodAutoscaler.
func (c *FakeHorizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) {
func (c *FakeHorizontalPodAutoscalers) Create(horizontalPodAutoscaler *autoscaling_v1.HorizontalPodAutoscaler) (result *autoscaling_v1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(horizontalpodautoscalersResource, c.ns, name, data, subresources...), &v1.HorizontalPodAutoscaler{})
Invokes(testing.NewCreateAction(horizontalpodautoscalersResource, c.ns, horizontalPodAutoscaler), &autoscaling_v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v1.HorizontalPodAutoscaler), err
return obj.(*autoscaling_v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) Update(horizontalPodAutoscaler *autoscaling_v1.HorizontalPodAutoscaler) (result *autoscaling_v1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(horizontalpodautoscalersResource, c.ns, horizontalPodAutoscaler), &autoscaling_v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*autoscaling_v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *autoscaling_v1.HorizontalPodAutoscaler) (*autoscaling_v1.HorizontalPodAutoscaler, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(horizontalpodautoscalersResource, "status", c.ns, horizontalPodAutoscaler), &autoscaling_v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*autoscaling_v1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(horizontalpodautoscalersResource, c.ns, name), &autoscaling_v1.HorizontalPodAutoscaler{})
return err
}
func (c *FakeHorizontalPodAutoscalers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(horizontalpodautoscalersResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &autoscaling_v1.HorizontalPodAutoscalerList{})
return err
}
// Patch applies the patch and returns the patched horizontalPodAutoscaler.
func (c *FakeHorizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *autoscaling_v1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(horizontalpodautoscalersResource, c.ns, name, data, subresources...), &autoscaling_v1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*autoscaling_v1.HorizontalPodAutoscaler), err
}

View File

@ -59,6 +59,41 @@ func newHorizontalPodAutoscalers(c *AutoscalingV1Client, namespace string) *hori
}
}
// Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any.
func (c *horizontalPodAutoscalers) Get(name string, options meta_v1.GetOptions) (result *v1.HorizontalPodAutoscaler, err error) {
result = &v1.HorizontalPodAutoscaler{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors.
func (c *horizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v1.HorizontalPodAutoscalerList, err error) {
result = &v1.HorizontalPodAutoscalerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *horizontalPodAutoscalers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a horizontalPodAutoscaler and creates it. Returns the server's representation of the horizontalPodAutoscaler, and an error, if there is any.
func (c *horizontalPodAutoscalers) Create(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (result *v1.HorizontalPodAutoscaler, err error) {
result = &v1.HorizontalPodAutoscaler{}
@ -85,7 +120,7 @@ func (c *horizontalPodAutoscalers) Update(horizontalPodAutoscaler *v1.Horizontal
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *horizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (result *v1.HorizontalPodAutoscaler, err error) {
result = &v1.HorizontalPodAutoscaler{}
@ -122,41 +157,6 @@ func (c *horizontalPodAutoscalers) DeleteCollection(options *meta_v1.DeleteOptio
Error()
}
// Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any.
func (c *horizontalPodAutoscalers) Get(name string, options meta_v1.GetOptions) (result *v1.HorizontalPodAutoscaler, err error) {
result = &v1.HorizontalPodAutoscaler{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors.
func (c *horizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v1.HorizontalPodAutoscalerList, err error) {
result = &v1.HorizontalPodAutoscalerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *horizontalPodAutoscalers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched horizontalPodAutoscaler.
func (c *horizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) {
result = &v1.HorizontalPodAutoscaler{}

View File

@ -36,6 +36,44 @@ var horizontalpodautoscalersResource = schema.GroupVersionResource{Group: "autos
var horizontalpodautoscalersKind = schema.GroupVersionKind{Group: "autoscaling", Version: "v2alpha1", Kind: "HorizontalPodAutoscaler"}
func (c *FakeHorizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(horizontalpodautoscalersResource, c.ns, name), &v2alpha1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v2alpha1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) List(opts v1.ListOptions) (result *v2alpha1.HorizontalPodAutoscalerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(horizontalpodautoscalersResource, horizontalpodautoscalersKind, c.ns, opts), &v2alpha1.HorizontalPodAutoscalerList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v2alpha1.HorizontalPodAutoscalerList{}
for _, item := range obj.(*v2alpha1.HorizontalPodAutoscalerList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *FakeHorizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(horizontalpodautoscalersResource, c.ns, opts))
}
func (c *FakeHorizontalPodAutoscalers) Create(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(horizontalpodautoscalersResource, c.ns, horizontalPodAutoscaler), &v2alpha1.HorizontalPodAutoscaler{})
@ -80,44 +118,6 @@ func (c *FakeHorizontalPodAutoscalers) DeleteCollection(options *v1.DeleteOption
return err
}
func (c *FakeHorizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(horizontalpodautoscalersResource, c.ns, name), &v2alpha1.HorizontalPodAutoscaler{})
if obj == nil {
return nil, err
}
return obj.(*v2alpha1.HorizontalPodAutoscaler), err
}
func (c *FakeHorizontalPodAutoscalers) List(opts v1.ListOptions) (result *v2alpha1.HorizontalPodAutoscalerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(horizontalpodautoscalersResource, horizontalpodautoscalersKind, c.ns, opts), &v2alpha1.HorizontalPodAutoscalerList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v2alpha1.HorizontalPodAutoscalerList{}
for _, item := range obj.(*v2alpha1.HorizontalPodAutoscalerList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *FakeHorizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(horizontalpodautoscalersResource, c.ns, opts))
}
// Patch applies the patch and returns the patched horizontalPodAutoscaler.
func (c *FakeHorizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
obj, err := c.Fake.

View File

@ -59,6 +59,41 @@ func newHorizontalPodAutoscalers(c *AutoscalingV2alpha1Client, namespace string)
}
}
// Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any.
func (c *horizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
result = &v2alpha1.HorizontalPodAutoscaler{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors.
func (c *horizontalPodAutoscalers) List(opts v1.ListOptions) (result *v2alpha1.HorizontalPodAutoscalerList, err error) {
result = &v2alpha1.HorizontalPodAutoscalerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *horizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a horizontalPodAutoscaler and creates it. Returns the server's representation of the horizontalPodAutoscaler, and an error, if there is any.
func (c *horizontalPodAutoscalers) Create(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
result = &v2alpha1.HorizontalPodAutoscaler{}
@ -85,7 +120,7 @@ func (c *horizontalPodAutoscalers) Update(horizontalPodAutoscaler *v2alpha1.Hori
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *horizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
result = &v2alpha1.HorizontalPodAutoscaler{}
@ -122,41 +157,6 @@ func (c *horizontalPodAutoscalers) DeleteCollection(options *v1.DeleteOptions, l
Error()
}
// Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any.
func (c *horizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
result = &v2alpha1.HorizontalPodAutoscaler{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors.
func (c *horizontalPodAutoscalers) List(opts v1.ListOptions) (result *v2alpha1.HorizontalPodAutoscalerList, err error) {
result = &v2alpha1.HorizontalPodAutoscalerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers.
func (c *horizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("horizontalpodautoscalers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched horizontalPodAutoscaler.
func (c *horizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.HorizontalPodAutoscaler, err error) {
result = &v2alpha1.HorizontalPodAutoscaler{}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/batch/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
batch_v1 "k8s.io/api/batch/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var jobsResource = schema.GroupVersionResource{Group: "batch", Version: "v1", Re
var jobsKind = schema.GroupVersionKind{Group: "batch", Version: "v1", Kind: "Job"}
func (c *FakeJobs) Create(job *v1.Job) (result *v1.Job, err error) {
func (c *FakeJobs) Get(name string, options v1.GetOptions) (result *batch_v1.Job, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(jobsResource, c.ns, job), &v1.Job{})
Invokes(testing.NewGetAction(jobsResource, c.ns, name), &batch_v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*v1.Job), err
return obj.(*batch_v1.Job), err
}
func (c *FakeJobs) Update(job *v1.Job) (result *v1.Job, err error) {
func (c *FakeJobs) List(opts v1.ListOptions) (result *batch_v1.JobList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(jobsResource, c.ns, job), &v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*v1.Job), err
}
func (c *FakeJobs) UpdateStatus(job *v1.Job) (*v1.Job, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(jobsResource, "status", c.ns, job), &v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*v1.Job), err
}
func (c *FakeJobs) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(jobsResource, c.ns, name), &v1.Job{})
return err
}
func (c *FakeJobs) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(jobsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.JobList{})
return err
}
func (c *FakeJobs) Get(name string, options meta_v1.GetOptions) (result *v1.Job, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(jobsResource, c.ns, name), &v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*v1.Job), err
}
func (c *FakeJobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(jobsResource, jobsKind, c.ns, opts), &v1.JobList{})
Invokes(testing.NewListAction(jobsResource, jobsKind, c.ns, opts), &batch_v1.JobList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakeJobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error
if label == nil {
label = labels.Everything()
}
list := &v1.JobList{}
for _, item := range obj.(*v1.JobList).Items {
list := &batch_v1.JobList{}
for _, item := range obj.(*batch_v1.JobList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakeJobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error
}
// Watch returns a watch.Interface that watches the requested jobs.
func (c *FakeJobs) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeJobs) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(jobsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched job.
func (c *FakeJobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) {
func (c *FakeJobs) Create(job *batch_v1.Job) (result *batch_v1.Job, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(jobsResource, c.ns, name, data, subresources...), &v1.Job{})
Invokes(testing.NewCreateAction(jobsResource, c.ns, job), &batch_v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*v1.Job), err
return obj.(*batch_v1.Job), err
}
func (c *FakeJobs) Update(job *batch_v1.Job) (result *batch_v1.Job, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(jobsResource, c.ns, job), &batch_v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*batch_v1.Job), err
}
func (c *FakeJobs) UpdateStatus(job *batch_v1.Job) (*batch_v1.Job, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(jobsResource, "status", c.ns, job), &batch_v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*batch_v1.Job), err
}
func (c *FakeJobs) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(jobsResource, c.ns, name), &batch_v1.Job{})
return err
}
func (c *FakeJobs) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(jobsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &batch_v1.JobList{})
return err
}
// Patch applies the patch and returns the patched job.
func (c *FakeJobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *batch_v1.Job, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(jobsResource, c.ns, name, data, subresources...), &batch_v1.Job{})
if obj == nil {
return nil, err
}
return obj.(*batch_v1.Job), err
}

View File

@ -59,6 +59,41 @@ func newJobs(c *BatchV1Client, namespace string) *jobs {
}
}
// Get takes name of the job, and returns the corresponding job object, and an error if there is any.
func (c *jobs) Get(name string, options meta_v1.GetOptions) (result *v1.Job, err error) {
result = &v1.Job{}
err = c.client.Get().
Namespace(c.ns).
Resource("jobs").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Jobs that match those selectors.
func (c *jobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error) {
result = &v1.JobList{}
err = c.client.Get().
Namespace(c.ns).
Resource("jobs").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested jobs.
func (c *jobs) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("jobs").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a job and creates it. Returns the server's representation of the job, and an error, if there is any.
func (c *jobs) Create(job *v1.Job) (result *v1.Job, err error) {
result = &v1.Job{}
@ -85,7 +120,7 @@ func (c *jobs) Update(job *v1.Job) (result *v1.Job, err error) {
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *jobs) UpdateStatus(job *v1.Job) (result *v1.Job, err error) {
result = &v1.Job{}
@ -122,41 +157,6 @@ func (c *jobs) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta
Error()
}
// Get takes name of the job, and returns the corresponding job object, and an error if there is any.
func (c *jobs) Get(name string, options meta_v1.GetOptions) (result *v1.Job, err error) {
result = &v1.Job{}
err = c.client.Get().
Namespace(c.ns).
Resource("jobs").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Jobs that match those selectors.
func (c *jobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error) {
result = &v1.JobList{}
err = c.client.Get().
Namespace(c.ns).
Resource("jobs").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested jobs.
func (c *jobs) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("jobs").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched job.
func (c *jobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) {
result = &v1.Job{}

View File

@ -59,6 +59,41 @@ func newCronJobs(c *BatchV2alpha1Client, namespace string) *cronJobs {
}
}
// Get takes name of the cronJob, and returns the corresponding cronJob object, and an error if there is any.
func (c *cronJobs) Get(name string, options v1.GetOptions) (result *v2alpha1.CronJob, err error) {
result = &v2alpha1.CronJob{}
err = c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of CronJobs that match those selectors.
func (c *cronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err error) {
result = &v2alpha1.CronJobList{}
err = c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested cronJobs.
func (c *cronJobs) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a cronJob and creates it. Returns the server's representation of the cronJob, and an error, if there is any.
func (c *cronJobs) Create(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob, err error) {
result = &v2alpha1.CronJob{}
@ -85,7 +120,7 @@ func (c *cronJobs) Update(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob,
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *cronJobs) UpdateStatus(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob, err error) {
result = &v2alpha1.CronJob{}
@ -122,41 +157,6 @@ func (c *cronJobs) DeleteCollection(options *v1.DeleteOptions, listOptions v1.Li
Error()
}
// Get takes name of the cronJob, and returns the corresponding cronJob object, and an error if there is any.
func (c *cronJobs) Get(name string, options v1.GetOptions) (result *v2alpha1.CronJob, err error) {
result = &v2alpha1.CronJob{}
err = c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of CronJobs that match those selectors.
func (c *cronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err error) {
result = &v2alpha1.CronJobList{}
err = c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested cronJobs.
func (c *cronJobs) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("cronjobs").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched cronJob.
func (c *cronJobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) {
result = &v2alpha1.CronJob{}

View File

@ -36,6 +36,44 @@ var cronjobsResource = schema.GroupVersionResource{Group: "batch", Version: "v2a
var cronjobsKind = schema.GroupVersionKind{Group: "batch", Version: "v2alpha1", Kind: "CronJob"}
func (c *FakeCronJobs) Get(name string, options v1.GetOptions) (result *v2alpha1.CronJob, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(cronjobsResource, c.ns, name), &v2alpha1.CronJob{})
if obj == nil {
return nil, err
}
return obj.(*v2alpha1.CronJob), err
}
func (c *FakeCronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(cronjobsResource, cronjobsKind, c.ns, opts), &v2alpha1.CronJobList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v2alpha1.CronJobList{}
for _, item := range obj.(*v2alpha1.CronJobList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested cronJobs.
func (c *FakeCronJobs) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(cronjobsResource, c.ns, opts))
}
func (c *FakeCronJobs) Create(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(cronjobsResource, c.ns, cronJob), &v2alpha1.CronJob{})
@ -80,44 +118,6 @@ func (c *FakeCronJobs) DeleteCollection(options *v1.DeleteOptions, listOptions v
return err
}
func (c *FakeCronJobs) Get(name string, options v1.GetOptions) (result *v2alpha1.CronJob, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(cronjobsResource, c.ns, name), &v2alpha1.CronJob{})
if obj == nil {
return nil, err
}
return obj.(*v2alpha1.CronJob), err
}
func (c *FakeCronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(cronjobsResource, cronjobsKind, c.ns, opts), &v2alpha1.CronJobList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v2alpha1.CronJobList{}
for _, item := range obj.(*v2alpha1.CronJobList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested cronJobs.
func (c *FakeCronJobs) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(cronjobsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched cronJob.
func (c *FakeCronJobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) {
obj, err := c.Fake.

View File

@ -57,6 +57,38 @@ func newCertificateSigningRequests(c *CertificatesV1beta1Client) *certificateSig
}
}
// Get takes name of the certificateSigningRequest, and returns the corresponding certificateSigningRequest object, and an error if there is any.
func (c *certificateSigningRequests) Get(name string, options v1.GetOptions) (result *v1beta1.CertificateSigningRequest, err error) {
result = &v1beta1.CertificateSigningRequest{}
err = c.client.Get().
Resource("certificatesigningrequests").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of CertificateSigningRequests that match those selectors.
func (c *certificateSigningRequests) List(opts v1.ListOptions) (result *v1beta1.CertificateSigningRequestList, err error) {
result = &v1beta1.CertificateSigningRequestList{}
err = c.client.Get().
Resource("certificatesigningrequests").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested certificateSigningRequests.
func (c *certificateSigningRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("certificatesigningrequests").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a certificateSigningRequest and creates it. Returns the server's representation of the certificateSigningRequest, and an error, if there is any.
func (c *certificateSigningRequests) Create(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) {
result = &v1beta1.CertificateSigningRequest{}
@ -81,7 +113,7 @@ func (c *certificateSigningRequests) Update(certificateSigningRequest *v1beta1.C
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *certificateSigningRequests) UpdateStatus(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) {
result = &v1beta1.CertificateSigningRequest{}
@ -115,38 +147,6 @@ func (c *certificateSigningRequests) DeleteCollection(options *v1.DeleteOptions,
Error()
}
// Get takes name of the certificateSigningRequest, and returns the corresponding certificateSigningRequest object, and an error if there is any.
func (c *certificateSigningRequests) Get(name string, options v1.GetOptions) (result *v1beta1.CertificateSigningRequest, err error) {
result = &v1beta1.CertificateSigningRequest{}
err = c.client.Get().
Resource("certificatesigningrequests").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of CertificateSigningRequests that match those selectors.
func (c *certificateSigningRequests) List(opts v1.ListOptions) (result *v1beta1.CertificateSigningRequestList, err error) {
result = &v1beta1.CertificateSigningRequestList{}
err = c.client.Get().
Resource("certificatesigningrequests").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested certificateSigningRequests.
func (c *certificateSigningRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("certificatesigningrequests").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched certificateSigningRequest.
func (c *certificateSigningRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CertificateSigningRequest, err error) {
result = &v1beta1.CertificateSigningRequest{}

View File

@ -35,6 +35,41 @@ var certificatesigningrequestsResource = schema.GroupVersionResource{Group: "cer
var certificatesigningrequestsKind = schema.GroupVersionKind{Group: "certificates.k8s.io", Version: "v1beta1", Kind: "CertificateSigningRequest"}
func (c *FakeCertificateSigningRequests) Get(name string, options v1.GetOptions) (result *v1beta1.CertificateSigningRequest, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(certificatesigningrequestsResource, name), &v1beta1.CertificateSigningRequest{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.CertificateSigningRequest), err
}
func (c *FakeCertificateSigningRequests) List(opts v1.ListOptions) (result *v1beta1.CertificateSigningRequestList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(certificatesigningrequestsResource, certificatesigningrequestsKind, opts), &v1beta1.CertificateSigningRequestList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.CertificateSigningRequestList{}
for _, item := range obj.(*v1beta1.CertificateSigningRequestList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested certificateSigningRequests.
func (c *FakeCertificateSigningRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(certificatesigningrequestsResource, opts))
}
func (c *FakeCertificateSigningRequests) Create(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(certificatesigningrequestsResource, certificateSigningRequest), &v1beta1.CertificateSigningRequest{})
@ -75,41 +110,6 @@ func (c *FakeCertificateSigningRequests) DeleteCollection(options *v1.DeleteOpti
return err
}
func (c *FakeCertificateSigningRequests) Get(name string, options v1.GetOptions) (result *v1beta1.CertificateSigningRequest, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(certificatesigningrequestsResource, name), &v1beta1.CertificateSigningRequest{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.CertificateSigningRequest), err
}
func (c *FakeCertificateSigningRequests) List(opts v1.ListOptions) (result *v1beta1.CertificateSigningRequestList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(certificatesigningrequestsResource, certificatesigningrequestsKind, opts), &v1beta1.CertificateSigningRequestList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.CertificateSigningRequestList{}
for _, item := range obj.(*v1beta1.CertificateSigningRequestList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested certificateSigningRequests.
func (c *FakeCertificateSigningRequests) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(certificatesigningrequestsResource, opts))
}
// Patch applies the patch and returns the patched certificateSigningRequest.
func (c *FakeCertificateSigningRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CertificateSigningRequest, err error) {
obj, err := c.Fake.

View File

@ -56,6 +56,38 @@ func newComponentStatuses(c *CoreV1Client) *componentStatuses {
}
}
// Get takes name of the componentStatus, and returns the corresponding componentStatus object, and an error if there is any.
func (c *componentStatuses) Get(name string, options meta_v1.GetOptions) (result *v1.ComponentStatus, err error) {
result = &v1.ComponentStatus{}
err = c.client.Get().
Resource("componentstatuses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ComponentStatuses that match those selectors.
func (c *componentStatuses) List(opts meta_v1.ListOptions) (result *v1.ComponentStatusList, err error) {
result = &v1.ComponentStatusList{}
err = c.client.Get().
Resource("componentstatuses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested componentStatuses.
func (c *componentStatuses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("componentstatuses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a componentStatus and creates it. Returns the server's representation of the componentStatus, and an error, if there is any.
func (c *componentStatuses) Create(componentStatus *v1.ComponentStatus) (result *v1.ComponentStatus, err error) {
result = &v1.ComponentStatus{}
@ -99,38 +131,6 @@ func (c *componentStatuses) DeleteCollection(options *meta_v1.DeleteOptions, lis
Error()
}
// Get takes name of the componentStatus, and returns the corresponding componentStatus object, and an error if there is any.
func (c *componentStatuses) Get(name string, options meta_v1.GetOptions) (result *v1.ComponentStatus, err error) {
result = &v1.ComponentStatus{}
err = c.client.Get().
Resource("componentstatuses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ComponentStatuses that match those selectors.
func (c *componentStatuses) List(opts meta_v1.ListOptions) (result *v1.ComponentStatusList, err error) {
result = &v1.ComponentStatusList{}
err = c.client.Get().
Resource("componentstatuses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested componentStatuses.
func (c *componentStatuses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("componentstatuses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched componentStatus.
func (c *componentStatuses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) {
result = &v1.ComponentStatus{}

View File

@ -58,6 +58,41 @@ func newConfigMaps(c *CoreV1Client, namespace string) *configMaps {
}
}
// Get takes name of the configMap, and returns the corresponding configMap object, and an error if there is any.
func (c *configMaps) Get(name string, options meta_v1.GetOptions) (result *v1.ConfigMap, err error) {
result = &v1.ConfigMap{}
err = c.client.Get().
Namespace(c.ns).
Resource("configmaps").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ConfigMaps that match those selectors.
func (c *configMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapList, err error) {
result = &v1.ConfigMapList{}
err = c.client.Get().
Namespace(c.ns).
Resource("configmaps").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested configMaps.
func (c *configMaps) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("configmaps").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a configMap and creates it. Returns the server's representation of the configMap, and an error, if there is any.
func (c *configMaps) Create(configMap *v1.ConfigMap) (result *v1.ConfigMap, err error) {
result = &v1.ConfigMap{}
@ -105,41 +140,6 @@ func (c *configMaps) DeleteCollection(options *meta_v1.DeleteOptions, listOption
Error()
}
// Get takes name of the configMap, and returns the corresponding configMap object, and an error if there is any.
func (c *configMaps) Get(name string, options meta_v1.GetOptions) (result *v1.ConfigMap, err error) {
result = &v1.ConfigMap{}
err = c.client.Get().
Namespace(c.ns).
Resource("configmaps").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ConfigMaps that match those selectors.
func (c *configMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapList, err error) {
result = &v1.ConfigMapList{}
err = c.client.Get().
Namespace(c.ns).
Resource("configmaps").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested configMaps.
func (c *configMaps) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("configmaps").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched configMap.
func (c *configMaps) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) {
result = &v1.ConfigMap{}

View File

@ -58,6 +58,41 @@ func newEndpoints(c *CoreV1Client, namespace string) *endpoints {
}
}
// Get takes name of the endpoints, and returns the corresponding endpoints object, and an error if there is any.
func (c *endpoints) Get(name string, options meta_v1.GetOptions) (result *v1.Endpoints, err error) {
result = &v1.Endpoints{}
err = c.client.Get().
Namespace(c.ns).
Resource("endpoints").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Endpoints that match those selectors.
func (c *endpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList, err error) {
result = &v1.EndpointsList{}
err = c.client.Get().
Namespace(c.ns).
Resource("endpoints").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested endpoints.
func (c *endpoints) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("endpoints").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a endpoints and creates it. Returns the server's representation of the endpoints, and an error, if there is any.
func (c *endpoints) Create(endpoints *v1.Endpoints) (result *v1.Endpoints, err error) {
result = &v1.Endpoints{}
@ -105,41 +140,6 @@ func (c *endpoints) DeleteCollection(options *meta_v1.DeleteOptions, listOptions
Error()
}
// Get takes name of the endpoints, and returns the corresponding endpoints object, and an error if there is any.
func (c *endpoints) Get(name string, options meta_v1.GetOptions) (result *v1.Endpoints, err error) {
result = &v1.Endpoints{}
err = c.client.Get().
Namespace(c.ns).
Resource("endpoints").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Endpoints that match those selectors.
func (c *endpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList, err error) {
result = &v1.EndpointsList{}
err = c.client.Get().
Namespace(c.ns).
Resource("endpoints").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested endpoints.
func (c *endpoints) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("endpoints").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched endpoints.
func (c *endpoints) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) {
result = &v1.Endpoints{}

View File

@ -58,6 +58,41 @@ func newEvents(c *CoreV1Client, namespace string) *events {
}
}
// Get takes name of the event, and returns the corresponding event object, and an error if there is any.
func (c *events) Get(name string, options meta_v1.GetOptions) (result *v1.Event, err error) {
result = &v1.Event{}
err = c.client.Get().
Namespace(c.ns).
Resource("events").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Events that match those selectors.
func (c *events) List(opts meta_v1.ListOptions) (result *v1.EventList, err error) {
result = &v1.EventList{}
err = c.client.Get().
Namespace(c.ns).
Resource("events").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested events.
func (c *events) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("events").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a event and creates it. Returns the server's representation of the event, and an error, if there is any.
func (c *events) Create(event *v1.Event) (result *v1.Event, err error) {
result = &v1.Event{}
@ -105,41 +140,6 @@ func (c *events) DeleteCollection(options *meta_v1.DeleteOptions, listOptions me
Error()
}
// Get takes name of the event, and returns the corresponding event object, and an error if there is any.
func (c *events) Get(name string, options meta_v1.GetOptions) (result *v1.Event, err error) {
result = &v1.Event{}
err = c.client.Get().
Namespace(c.ns).
Resource("events").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Events that match those selectors.
func (c *events) List(opts meta_v1.ListOptions) (result *v1.EventList, err error) {
result = &v1.EventList{}
err = c.client.Get().
Namespace(c.ns).
Resource("events").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested events.
func (c *events) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("events").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched event.
func (c *events) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) {
result = &v1.Event{}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -35,49 +35,18 @@ var componentstatusesResource = schema.GroupVersionResource{Group: "", Version:
var componentstatusesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "ComponentStatus"}
func (c *FakeComponentStatuses) Create(componentStatus *v1.ComponentStatus) (result *v1.ComponentStatus, err error) {
func (c *FakeComponentStatuses) Get(name string, options v1.GetOptions) (result *core_v1.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(componentstatusesResource, componentStatus), &v1.ComponentStatus{})
Invokes(testing.NewRootGetAction(componentstatusesResource, name), &core_v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*v1.ComponentStatus), err
return obj.(*core_v1.ComponentStatus), err
}
func (c *FakeComponentStatuses) Update(componentStatus *v1.ComponentStatus) (result *v1.ComponentStatus, err error) {
func (c *FakeComponentStatuses) List(opts v1.ListOptions) (result *core_v1.ComponentStatusList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(componentstatusesResource, componentStatus), &v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*v1.ComponentStatus), err
}
func (c *FakeComponentStatuses) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(componentstatusesResource, name), &v1.ComponentStatus{})
return err
}
func (c *FakeComponentStatuses) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(componentstatusesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1.ComponentStatusList{})
return err
}
func (c *FakeComponentStatuses) Get(name string, options meta_v1.GetOptions) (result *v1.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(componentstatusesResource, name), &v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*v1.ComponentStatus), err
}
func (c *FakeComponentStatuses) List(opts meta_v1.ListOptions) (result *v1.ComponentStatusList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(componentstatusesResource, componentstatusesKind, opts), &v1.ComponentStatusList{})
Invokes(testing.NewRootListAction(componentstatusesResource, componentstatusesKind, opts), &core_v1.ComponentStatusList{})
if obj == nil {
return nil, err
}
@ -86,8 +55,8 @@ func (c *FakeComponentStatuses) List(opts meta_v1.ListOptions) (result *v1.Compo
if label == nil {
label = labels.Everything()
}
list := &v1.ComponentStatusList{}
for _, item := range obj.(*v1.ComponentStatusList).Items {
list := &core_v1.ComponentStatusList{}
for _, item := range obj.(*core_v1.ComponentStatusList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -96,17 +65,48 @@ func (c *FakeComponentStatuses) List(opts meta_v1.ListOptions) (result *v1.Compo
}
// Watch returns a watch.Interface that watches the requested componentStatuses.
func (c *FakeComponentStatuses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeComponentStatuses) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(componentstatusesResource, opts))
}
// Patch applies the patch and returns the patched componentStatus.
func (c *FakeComponentStatuses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) {
func (c *FakeComponentStatuses) Create(componentStatus *core_v1.ComponentStatus) (result *core_v1.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(componentstatusesResource, name, data, subresources...), &v1.ComponentStatus{})
Invokes(testing.NewRootCreateAction(componentstatusesResource, componentStatus), &core_v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*v1.ComponentStatus), err
return obj.(*core_v1.ComponentStatus), err
}
func (c *FakeComponentStatuses) Update(componentStatus *core_v1.ComponentStatus) (result *core_v1.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(componentstatusesResource, componentStatus), &core_v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ComponentStatus), err
}
func (c *FakeComponentStatuses) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(componentstatusesResource, name), &core_v1.ComponentStatus{})
return err
}
func (c *FakeComponentStatuses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(componentstatusesResource, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ComponentStatusList{})
return err
}
// Patch applies the patch and returns the patched componentStatus.
func (c *FakeComponentStatuses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(componentstatusesResource, name, data, subresources...), &core_v1.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ComponentStatus), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var configmapsResource = schema.GroupVersionResource{Group: "", Version: "v1", R
var configmapsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "ConfigMap"}
func (c *FakeConfigMaps) Create(configMap *v1.ConfigMap) (result *v1.ConfigMap, err error) {
func (c *FakeConfigMaps) Get(name string, options v1.GetOptions) (result *core_v1.ConfigMap, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(configmapsResource, c.ns, configMap), &v1.ConfigMap{})
Invokes(testing.NewGetAction(configmapsResource, c.ns, name), &core_v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*v1.ConfigMap), err
return obj.(*core_v1.ConfigMap), err
}
func (c *FakeConfigMaps) Update(configMap *v1.ConfigMap) (result *v1.ConfigMap, err error) {
func (c *FakeConfigMaps) List(opts v1.ListOptions) (result *core_v1.ConfigMapList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(configmapsResource, c.ns, configMap), &v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*v1.ConfigMap), err
}
func (c *FakeConfigMaps) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(configmapsResource, c.ns, name), &v1.ConfigMap{})
return err
}
func (c *FakeConfigMaps) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(configmapsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.ConfigMapList{})
return err
}
func (c *FakeConfigMaps) Get(name string, options meta_v1.GetOptions) (result *v1.ConfigMap, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(configmapsResource, c.ns, name), &v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*v1.ConfigMap), err
}
func (c *FakeConfigMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(configmapsResource, configmapsKind, c.ns, opts), &v1.ConfigMapList{})
Invokes(testing.NewListAction(configmapsResource, configmapsKind, c.ns, opts), &core_v1.ConfigMapList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeConfigMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapLis
if label == nil {
label = labels.Everything()
}
list := &v1.ConfigMapList{}
for _, item := range obj.(*v1.ConfigMapList).Items {
list := &core_v1.ConfigMapList{}
for _, item := range obj.(*core_v1.ConfigMapList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeConfigMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapLis
}
// Watch returns a watch.Interface that watches the requested configMaps.
func (c *FakeConfigMaps) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeConfigMaps) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(configmapsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched configMap.
func (c *FakeConfigMaps) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) {
func (c *FakeConfigMaps) Create(configMap *core_v1.ConfigMap) (result *core_v1.ConfigMap, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(configmapsResource, c.ns, name, data, subresources...), &v1.ConfigMap{})
Invokes(testing.NewCreateAction(configmapsResource, c.ns, configMap), &core_v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*v1.ConfigMap), err
return obj.(*core_v1.ConfigMap), err
}
func (c *FakeConfigMaps) Update(configMap *core_v1.ConfigMap) (result *core_v1.ConfigMap, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(configmapsResource, c.ns, configMap), &core_v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ConfigMap), err
}
func (c *FakeConfigMaps) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(configmapsResource, c.ns, name), &core_v1.ConfigMap{})
return err
}
func (c *FakeConfigMaps) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(configmapsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ConfigMapList{})
return err
}
// Patch applies the patch and returns the patched configMap.
func (c *FakeConfigMaps) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.ConfigMap, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(configmapsResource, c.ns, name, data, subresources...), &core_v1.ConfigMap{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ConfigMap), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var endpointsResource = schema.GroupVersionResource{Group: "", Version: "v1", Re
var endpointsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Endpoints"}
func (c *FakeEndpoints) Create(endpoints *v1.Endpoints) (result *v1.Endpoints, err error) {
func (c *FakeEndpoints) Get(name string, options v1.GetOptions) (result *core_v1.Endpoints, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(endpointsResource, c.ns, endpoints), &v1.Endpoints{})
Invokes(testing.NewGetAction(endpointsResource, c.ns, name), &core_v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*v1.Endpoints), err
return obj.(*core_v1.Endpoints), err
}
func (c *FakeEndpoints) Update(endpoints *v1.Endpoints) (result *v1.Endpoints, err error) {
func (c *FakeEndpoints) List(opts v1.ListOptions) (result *core_v1.EndpointsList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(endpointsResource, c.ns, endpoints), &v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*v1.Endpoints), err
}
func (c *FakeEndpoints) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(endpointsResource, c.ns, name), &v1.Endpoints{})
return err
}
func (c *FakeEndpoints) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(endpointsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.EndpointsList{})
return err
}
func (c *FakeEndpoints) Get(name string, options meta_v1.GetOptions) (result *v1.Endpoints, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(endpointsResource, c.ns, name), &v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*v1.Endpoints), err
}
func (c *FakeEndpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(endpointsResource, endpointsKind, c.ns, opts), &v1.EndpointsList{})
Invokes(testing.NewListAction(endpointsResource, endpointsKind, c.ns, opts), &core_v1.EndpointsList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeEndpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList
if label == nil {
label = labels.Everything()
}
list := &v1.EndpointsList{}
for _, item := range obj.(*v1.EndpointsList).Items {
list := &core_v1.EndpointsList{}
for _, item := range obj.(*core_v1.EndpointsList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeEndpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList
}
// Watch returns a watch.Interface that watches the requested endpoints.
func (c *FakeEndpoints) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeEndpoints) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(endpointsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched endpoints.
func (c *FakeEndpoints) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) {
func (c *FakeEndpoints) Create(endpoints *core_v1.Endpoints) (result *core_v1.Endpoints, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(endpointsResource, c.ns, name, data, subresources...), &v1.Endpoints{})
Invokes(testing.NewCreateAction(endpointsResource, c.ns, endpoints), &core_v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*v1.Endpoints), err
return obj.(*core_v1.Endpoints), err
}
func (c *FakeEndpoints) Update(endpoints *core_v1.Endpoints) (result *core_v1.Endpoints, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(endpointsResource, c.ns, endpoints), &core_v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Endpoints), err
}
func (c *FakeEndpoints) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(endpointsResource, c.ns, name), &core_v1.Endpoints{})
return err
}
func (c *FakeEndpoints) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(endpointsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.EndpointsList{})
return err
}
// Patch applies the patch and returns the patched endpoints.
func (c *FakeEndpoints) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Endpoints, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(endpointsResource, c.ns, name, data, subresources...), &core_v1.Endpoints{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Endpoints), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var eventsResource = schema.GroupVersionResource{Group: "", Version: "v1", Resou
var eventsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Event"}
func (c *FakeEvents) Create(event *v1.Event) (result *v1.Event, err error) {
func (c *FakeEvents) Get(name string, options v1.GetOptions) (result *core_v1.Event, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(eventsResource, c.ns, event), &v1.Event{})
Invokes(testing.NewGetAction(eventsResource, c.ns, name), &core_v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*v1.Event), err
return obj.(*core_v1.Event), err
}
func (c *FakeEvents) Update(event *v1.Event) (result *v1.Event, err error) {
func (c *FakeEvents) List(opts v1.ListOptions) (result *core_v1.EventList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(eventsResource, c.ns, event), &v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*v1.Event), err
}
func (c *FakeEvents) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(eventsResource, c.ns, name), &v1.Event{})
return err
}
func (c *FakeEvents) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(eventsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.EventList{})
return err
}
func (c *FakeEvents) Get(name string, options meta_v1.GetOptions) (result *v1.Event, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(eventsResource, c.ns, name), &v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*v1.Event), err
}
func (c *FakeEvents) List(opts meta_v1.ListOptions) (result *v1.EventList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(eventsResource, eventsKind, c.ns, opts), &v1.EventList{})
Invokes(testing.NewListAction(eventsResource, eventsKind, c.ns, opts), &core_v1.EventList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeEvents) List(opts meta_v1.ListOptions) (result *v1.EventList, err e
if label == nil {
label = labels.Everything()
}
list := &v1.EventList{}
for _, item := range obj.(*v1.EventList).Items {
list := &core_v1.EventList{}
for _, item := range obj.(*core_v1.EventList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeEvents) List(opts meta_v1.ListOptions) (result *v1.EventList, err e
}
// Watch returns a watch.Interface that watches the requested events.
func (c *FakeEvents) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeEvents) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(eventsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched event.
func (c *FakeEvents) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) {
func (c *FakeEvents) Create(event *core_v1.Event) (result *core_v1.Event, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(eventsResource, c.ns, name, data, subresources...), &v1.Event{})
Invokes(testing.NewCreateAction(eventsResource, c.ns, event), &core_v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*v1.Event), err
return obj.(*core_v1.Event), err
}
func (c *FakeEvents) Update(event *core_v1.Event) (result *core_v1.Event, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(eventsResource, c.ns, event), &core_v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Event), err
}
func (c *FakeEvents) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(eventsResource, c.ns, name), &core_v1.Event{})
return err
}
func (c *FakeEvents) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(eventsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.EventList{})
return err
}
// Patch applies the patch and returns the patched event.
func (c *FakeEvents) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Event, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(eventsResource, c.ns, name, data, subresources...), &core_v1.Event{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Event), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var limitrangesResource = schema.GroupVersionResource{Group: "", Version: "v1",
var limitrangesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "LimitRange"}
func (c *FakeLimitRanges) Create(limitRange *v1.LimitRange) (result *v1.LimitRange, err error) {
func (c *FakeLimitRanges) Get(name string, options v1.GetOptions) (result *core_v1.LimitRange, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(limitrangesResource, c.ns, limitRange), &v1.LimitRange{})
Invokes(testing.NewGetAction(limitrangesResource, c.ns, name), &core_v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*v1.LimitRange), err
return obj.(*core_v1.LimitRange), err
}
func (c *FakeLimitRanges) Update(limitRange *v1.LimitRange) (result *v1.LimitRange, err error) {
func (c *FakeLimitRanges) List(opts v1.ListOptions) (result *core_v1.LimitRangeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(limitrangesResource, c.ns, limitRange), &v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*v1.LimitRange), err
}
func (c *FakeLimitRanges) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(limitrangesResource, c.ns, name), &v1.LimitRange{})
return err
}
func (c *FakeLimitRanges) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(limitrangesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.LimitRangeList{})
return err
}
func (c *FakeLimitRanges) Get(name string, options meta_v1.GetOptions) (result *v1.LimitRange, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(limitrangesResource, c.ns, name), &v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*v1.LimitRange), err
}
func (c *FakeLimitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(limitrangesResource, limitrangesKind, c.ns, opts), &v1.LimitRangeList{})
Invokes(testing.NewListAction(limitrangesResource, limitrangesKind, c.ns, opts), &core_v1.LimitRangeList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeLimitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeL
if label == nil {
label = labels.Everything()
}
list := &v1.LimitRangeList{}
for _, item := range obj.(*v1.LimitRangeList).Items {
list := &core_v1.LimitRangeList{}
for _, item := range obj.(*core_v1.LimitRangeList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeLimitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeL
}
// Watch returns a watch.Interface that watches the requested limitRanges.
func (c *FakeLimitRanges) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeLimitRanges) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(limitrangesResource, c.ns, opts))
}
// Patch applies the patch and returns the patched limitRange.
func (c *FakeLimitRanges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) {
func (c *FakeLimitRanges) Create(limitRange *core_v1.LimitRange) (result *core_v1.LimitRange, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(limitrangesResource, c.ns, name, data, subresources...), &v1.LimitRange{})
Invokes(testing.NewCreateAction(limitrangesResource, c.ns, limitRange), &core_v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*v1.LimitRange), err
return obj.(*core_v1.LimitRange), err
}
func (c *FakeLimitRanges) Update(limitRange *core_v1.LimitRange) (result *core_v1.LimitRange, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(limitrangesResource, c.ns, limitRange), &core_v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.LimitRange), err
}
func (c *FakeLimitRanges) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(limitrangesResource, c.ns, name), &core_v1.LimitRange{})
return err
}
func (c *FakeLimitRanges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(limitrangesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.LimitRangeList{})
return err
}
// Patch applies the patch and returns the patched limitRange.
func (c *FakeLimitRanges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.LimitRange, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(limitrangesResource, c.ns, name, data, subresources...), &core_v1.LimitRange{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.LimitRange), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -35,58 +35,18 @@ var namespacesResource = schema.GroupVersionResource{Group: "", Version: "v1", R
var namespacesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Namespace"}
func (c *FakeNamespaces) Create(namespace *v1.Namespace) (result *v1.Namespace, err error) {
func (c *FakeNamespaces) Get(name string, options v1.GetOptions) (result *core_v1.Namespace, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(namespacesResource, namespace), &v1.Namespace{})
Invokes(testing.NewRootGetAction(namespacesResource, name), &core_v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*v1.Namespace), err
return obj.(*core_v1.Namespace), err
}
func (c *FakeNamespaces) Update(namespace *v1.Namespace) (result *v1.Namespace, err error) {
func (c *FakeNamespaces) List(opts v1.ListOptions) (result *core_v1.NamespaceList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(namespacesResource, namespace), &v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*v1.Namespace), err
}
func (c *FakeNamespaces) UpdateStatus(namespace *v1.Namespace) (*v1.Namespace, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(namespacesResource, "status", namespace), &v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*v1.Namespace), err
}
func (c *FakeNamespaces) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(namespacesResource, name), &v1.Namespace{})
return err
}
func (c *FakeNamespaces) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(namespacesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1.NamespaceList{})
return err
}
func (c *FakeNamespaces) Get(name string, options meta_v1.GetOptions) (result *v1.Namespace, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(namespacesResource, name), &v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*v1.Namespace), err
}
func (c *FakeNamespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(namespacesResource, namespacesKind, opts), &v1.NamespaceList{})
Invokes(testing.NewRootListAction(namespacesResource, namespacesKind, opts), &core_v1.NamespaceList{})
if obj == nil {
return nil, err
}
@ -95,8 +55,8 @@ func (c *FakeNamespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceLis
if label == nil {
label = labels.Everything()
}
list := &v1.NamespaceList{}
for _, item := range obj.(*v1.NamespaceList).Items {
list := &core_v1.NamespaceList{}
for _, item := range obj.(*core_v1.NamespaceList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -105,17 +65,57 @@ func (c *FakeNamespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceLis
}
// Watch returns a watch.Interface that watches the requested namespaces.
func (c *FakeNamespaces) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeNamespaces) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(namespacesResource, opts))
}
// Patch applies the patch and returns the patched namespace.
func (c *FakeNamespaces) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) {
func (c *FakeNamespaces) Create(namespace *core_v1.Namespace) (result *core_v1.Namespace, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(namespacesResource, name, data, subresources...), &v1.Namespace{})
Invokes(testing.NewRootCreateAction(namespacesResource, namespace), &core_v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*v1.Namespace), err
return obj.(*core_v1.Namespace), err
}
func (c *FakeNamespaces) Update(namespace *core_v1.Namespace) (result *core_v1.Namespace, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(namespacesResource, namespace), &core_v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Namespace), err
}
func (c *FakeNamespaces) UpdateStatus(namespace *core_v1.Namespace) (*core_v1.Namespace, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(namespacesResource, "status", namespace), &core_v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Namespace), err
}
func (c *FakeNamespaces) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(namespacesResource, name), &core_v1.Namespace{})
return err
}
func (c *FakeNamespaces) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(namespacesResource, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.NamespaceList{})
return err
}
// Patch applies the patch and returns the patched namespace.
func (c *FakeNamespaces) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Namespace, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(namespacesResource, name, data, subresources...), &core_v1.Namespace{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Namespace), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -35,58 +35,18 @@ var nodesResource = schema.GroupVersionResource{Group: "", Version: "v1", Resour
var nodesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Node"}
func (c *FakeNodes) Create(node *v1.Node) (result *v1.Node, err error) {
func (c *FakeNodes) Get(name string, options v1.GetOptions) (result *core_v1.Node, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(nodesResource, node), &v1.Node{})
Invokes(testing.NewRootGetAction(nodesResource, name), &core_v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*v1.Node), err
return obj.(*core_v1.Node), err
}
func (c *FakeNodes) Update(node *v1.Node) (result *v1.Node, err error) {
func (c *FakeNodes) List(opts v1.ListOptions) (result *core_v1.NodeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(nodesResource, node), &v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*v1.Node), err
}
func (c *FakeNodes) UpdateStatus(node *v1.Node) (*v1.Node, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(nodesResource, "status", node), &v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*v1.Node), err
}
func (c *FakeNodes) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(nodesResource, name), &v1.Node{})
return err
}
func (c *FakeNodes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(nodesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1.NodeList{})
return err
}
func (c *FakeNodes) Get(name string, options meta_v1.GetOptions) (result *v1.Node, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(nodesResource, name), &v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*v1.Node), err
}
func (c *FakeNodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(nodesResource, nodesKind, opts), &v1.NodeList{})
Invokes(testing.NewRootListAction(nodesResource, nodesKind, opts), &core_v1.NodeList{})
if obj == nil {
return nil, err
}
@ -95,8 +55,8 @@ func (c *FakeNodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err err
if label == nil {
label = labels.Everything()
}
list := &v1.NodeList{}
for _, item := range obj.(*v1.NodeList).Items {
list := &core_v1.NodeList{}
for _, item := range obj.(*core_v1.NodeList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -105,17 +65,57 @@ func (c *FakeNodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err err
}
// Watch returns a watch.Interface that watches the requested nodes.
func (c *FakeNodes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeNodes) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(nodesResource, opts))
}
// Patch applies the patch and returns the patched node.
func (c *FakeNodes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) {
func (c *FakeNodes) Create(node *core_v1.Node) (result *core_v1.Node, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(nodesResource, name, data, subresources...), &v1.Node{})
Invokes(testing.NewRootCreateAction(nodesResource, node), &core_v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*v1.Node), err
return obj.(*core_v1.Node), err
}
func (c *FakeNodes) Update(node *core_v1.Node) (result *core_v1.Node, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(nodesResource, node), &core_v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Node), err
}
func (c *FakeNodes) UpdateStatus(node *core_v1.Node) (*core_v1.Node, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(nodesResource, "status", node), &core_v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Node), err
}
func (c *FakeNodes) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(nodesResource, name), &core_v1.Node{})
return err
}
func (c *FakeNodes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(nodesResource, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.NodeList{})
return err
}
// Patch applies the patch and returns the patched node.
func (c *FakeNodes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Node, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(nodesResource, name, data, subresources...), &core_v1.Node{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Node), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -35,58 +35,18 @@ var persistentvolumesResource = schema.GroupVersionResource{Group: "", Version:
var persistentvolumesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "PersistentVolume"}
func (c *FakePersistentVolumes) Create(persistentVolume *v1.PersistentVolume) (result *v1.PersistentVolume, err error) {
func (c *FakePersistentVolumes) Get(name string, options v1.GetOptions) (result *core_v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(persistentvolumesResource, persistentVolume), &v1.PersistentVolume{})
Invokes(testing.NewRootGetAction(persistentvolumesResource, name), &core_v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
return obj.(*core_v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) Update(persistentVolume *v1.PersistentVolume) (result *v1.PersistentVolume, err error) {
func (c *FakePersistentVolumes) List(opts v1.ListOptions) (result *core_v1.PersistentVolumeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(persistentvolumesResource, persistentVolume), &v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) UpdateStatus(persistentVolume *v1.PersistentVolume) (*v1.PersistentVolume, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(persistentvolumesResource, "status", persistentVolume), &v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(persistentvolumesResource, name), &v1.PersistentVolume{})
return err
}
func (c *FakePersistentVolumes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(persistentvolumesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1.PersistentVolumeList{})
return err
}
func (c *FakePersistentVolumes) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(persistentvolumesResource, name), &v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(persistentvolumesResource, persistentvolumesKind, opts), &v1.PersistentVolumeList{})
Invokes(testing.NewRootListAction(persistentvolumesResource, persistentvolumesKind, opts), &core_v1.PersistentVolumeList{})
if obj == nil {
return nil, err
}
@ -95,8 +55,8 @@ func (c *FakePersistentVolumes) List(opts meta_v1.ListOptions) (result *v1.Persi
if label == nil {
label = labels.Everything()
}
list := &v1.PersistentVolumeList{}
for _, item := range obj.(*v1.PersistentVolumeList).Items {
list := &core_v1.PersistentVolumeList{}
for _, item := range obj.(*core_v1.PersistentVolumeList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -105,17 +65,57 @@ func (c *FakePersistentVolumes) List(opts meta_v1.ListOptions) (result *v1.Persi
}
// Watch returns a watch.Interface that watches the requested persistentVolumes.
func (c *FakePersistentVolumes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakePersistentVolumes) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(persistentvolumesResource, opts))
}
// Patch applies the patch and returns the patched persistentVolume.
func (c *FakePersistentVolumes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) {
func (c *FakePersistentVolumes) Create(persistentVolume *core_v1.PersistentVolume) (result *core_v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(persistentvolumesResource, name, data, subresources...), &v1.PersistentVolume{})
Invokes(testing.NewRootCreateAction(persistentvolumesResource, persistentVolume), &core_v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
return obj.(*core_v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) Update(persistentVolume *core_v1.PersistentVolume) (result *core_v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(persistentvolumesResource, persistentVolume), &core_v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) UpdateStatus(persistentVolume *core_v1.PersistentVolume) (*core_v1.PersistentVolume, error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateSubresourceAction(persistentvolumesResource, "status", persistentVolume), &core_v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolume), err
}
func (c *FakePersistentVolumes) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(persistentvolumesResource, name), &core_v1.PersistentVolume{})
return err
}
func (c *FakePersistentVolumes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(persistentvolumesResource, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.PersistentVolumeList{})
return err
}
// Patch applies the patch and returns the patched persistentVolume.
func (c *FakePersistentVolumes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(persistentvolumesResource, name, data, subresources...), &core_v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolume), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var persistentvolumeclaimsResource = schema.GroupVersionResource{Group: "", Vers
var persistentvolumeclaimsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "PersistentVolumeClaim"}
func (c *FakePersistentVolumeClaims) Create(persistentVolumeClaim *v1.PersistentVolumeClaim) (result *v1.PersistentVolumeClaim, err error) {
func (c *FakePersistentVolumeClaims) Get(name string, options v1.GetOptions) (result *core_v1.PersistentVolumeClaim, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(persistentvolumeclaimsResource, c.ns, persistentVolumeClaim), &v1.PersistentVolumeClaim{})
Invokes(testing.NewGetAction(persistentvolumeclaimsResource, c.ns, name), &core_v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolumeClaim), err
return obj.(*core_v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) Update(persistentVolumeClaim *v1.PersistentVolumeClaim) (result *v1.PersistentVolumeClaim, err error) {
func (c *FakePersistentVolumeClaims) List(opts v1.ListOptions) (result *core_v1.PersistentVolumeClaimList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(persistentvolumeclaimsResource, c.ns, persistentVolumeClaim), &v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) UpdateStatus(persistentVolumeClaim *v1.PersistentVolumeClaim) (*v1.PersistentVolumeClaim, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(persistentvolumeclaimsResource, "status", c.ns, persistentVolumeClaim), &v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(persistentvolumeclaimsResource, c.ns, name), &v1.PersistentVolumeClaim{})
return err
}
func (c *FakePersistentVolumeClaims) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(persistentvolumeclaimsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.PersistentVolumeClaimList{})
return err
}
func (c *FakePersistentVolumeClaims) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolumeClaim, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(persistentvolumeclaimsResource, c.ns, name), &v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeClaimList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(persistentvolumeclaimsResource, persistentvolumeclaimsKind, c.ns, opts), &v1.PersistentVolumeClaimList{})
Invokes(testing.NewListAction(persistentvolumeclaimsResource, persistentvolumeclaimsKind, c.ns, opts), &core_v1.PersistentVolumeClaimList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakePersistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.
if label == nil {
label = labels.Everything()
}
list := &v1.PersistentVolumeClaimList{}
for _, item := range obj.(*v1.PersistentVolumeClaimList).Items {
list := &core_v1.PersistentVolumeClaimList{}
for _, item := range obj.(*core_v1.PersistentVolumeClaimList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakePersistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.
}
// Watch returns a watch.Interface that watches the requested persistentVolumeClaims.
func (c *FakePersistentVolumeClaims) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakePersistentVolumeClaims) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(persistentvolumeclaimsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched persistentVolumeClaim.
func (c *FakePersistentVolumeClaims) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) {
func (c *FakePersistentVolumeClaims) Create(persistentVolumeClaim *core_v1.PersistentVolumeClaim) (result *core_v1.PersistentVolumeClaim, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(persistentvolumeclaimsResource, c.ns, name, data, subresources...), &v1.PersistentVolumeClaim{})
Invokes(testing.NewCreateAction(persistentvolumeclaimsResource, c.ns, persistentVolumeClaim), &core_v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolumeClaim), err
return obj.(*core_v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) Update(persistentVolumeClaim *core_v1.PersistentVolumeClaim) (result *core_v1.PersistentVolumeClaim, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(persistentvolumeclaimsResource, c.ns, persistentVolumeClaim), &core_v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) UpdateStatus(persistentVolumeClaim *core_v1.PersistentVolumeClaim) (*core_v1.PersistentVolumeClaim, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(persistentvolumeclaimsResource, "status", c.ns, persistentVolumeClaim), &core_v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolumeClaim), err
}
func (c *FakePersistentVolumeClaims) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(persistentvolumeclaimsResource, c.ns, name), &core_v1.PersistentVolumeClaim{})
return err
}
func (c *FakePersistentVolumeClaims) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(persistentvolumeclaimsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.PersistentVolumeClaimList{})
return err
}
// Patch applies the patch and returns the patched persistentVolumeClaim.
func (c *FakePersistentVolumeClaims) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.PersistentVolumeClaim, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(persistentvolumeclaimsResource, c.ns, name, data, subresources...), &core_v1.PersistentVolumeClaim{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PersistentVolumeClaim), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var podsResource = schema.GroupVersionResource{Group: "", Version: "v1", Resourc
var podsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Pod"}
func (c *FakePods) Create(pod *v1.Pod) (result *v1.Pod, err error) {
func (c *FakePods) Get(name string, options v1.GetOptions) (result *core_v1.Pod, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(podsResource, c.ns, pod), &v1.Pod{})
Invokes(testing.NewGetAction(podsResource, c.ns, name), &core_v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*v1.Pod), err
return obj.(*core_v1.Pod), err
}
func (c *FakePods) Update(pod *v1.Pod) (result *v1.Pod, err error) {
func (c *FakePods) List(opts v1.ListOptions) (result *core_v1.PodList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podsResource, c.ns, pod), &v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*v1.Pod), err
}
func (c *FakePods) UpdateStatus(pod *v1.Pod) (*v1.Pod, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(podsResource, "status", c.ns, pod), &v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*v1.Pod), err
}
func (c *FakePods) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podsResource, c.ns, name), &v1.Pod{})
return err
}
func (c *FakePods) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.PodList{})
return err
}
func (c *FakePods) Get(name string, options meta_v1.GetOptions) (result *v1.Pod, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(podsResource, c.ns, name), &v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*v1.Pod), err
}
func (c *FakePods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(podsResource, podsKind, c.ns, opts), &v1.PodList{})
Invokes(testing.NewListAction(podsResource, podsKind, c.ns, opts), &core_v1.PodList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakePods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error
if label == nil {
label = labels.Everything()
}
list := &v1.PodList{}
for _, item := range obj.(*v1.PodList).Items {
list := &core_v1.PodList{}
for _, item := range obj.(*core_v1.PodList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakePods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error
}
// Watch returns a watch.Interface that watches the requested pods.
func (c *FakePods) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakePods) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(podsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched pod.
func (c *FakePods) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) {
func (c *FakePods) Create(pod *core_v1.Pod) (result *core_v1.Pod, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(podsResource, c.ns, name, data, subresources...), &v1.Pod{})
Invokes(testing.NewCreateAction(podsResource, c.ns, pod), &core_v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*v1.Pod), err
return obj.(*core_v1.Pod), err
}
func (c *FakePods) Update(pod *core_v1.Pod) (result *core_v1.Pod, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podsResource, c.ns, pod), &core_v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Pod), err
}
func (c *FakePods) UpdateStatus(pod *core_v1.Pod) (*core_v1.Pod, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(podsResource, "status", c.ns, pod), &core_v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Pod), err
}
func (c *FakePods) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podsResource, c.ns, name), &core_v1.Pod{})
return err
}
func (c *FakePods) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.PodList{})
return err
}
// Patch applies the patch and returns the patched pod.
func (c *FakePods) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Pod, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(podsResource, c.ns, name, data, subresources...), &core_v1.Pod{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Pod), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var podtemplatesResource = schema.GroupVersionResource{Group: "", Version: "v1",
var podtemplatesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "PodTemplate"}
func (c *FakePodTemplates) Create(podTemplate *v1.PodTemplate) (result *v1.PodTemplate, err error) {
func (c *FakePodTemplates) Get(name string, options v1.GetOptions) (result *core_v1.PodTemplate, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(podtemplatesResource, c.ns, podTemplate), &v1.PodTemplate{})
Invokes(testing.NewGetAction(podtemplatesResource, c.ns, name), &core_v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*v1.PodTemplate), err
return obj.(*core_v1.PodTemplate), err
}
func (c *FakePodTemplates) Update(podTemplate *v1.PodTemplate) (result *v1.PodTemplate, err error) {
func (c *FakePodTemplates) List(opts v1.ListOptions) (result *core_v1.PodTemplateList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podtemplatesResource, c.ns, podTemplate), &v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*v1.PodTemplate), err
}
func (c *FakePodTemplates) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podtemplatesResource, c.ns, name), &v1.PodTemplate{})
return err
}
func (c *FakePodTemplates) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podtemplatesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.PodTemplateList{})
return err
}
func (c *FakePodTemplates) Get(name string, options meta_v1.GetOptions) (result *v1.PodTemplate, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(podtemplatesResource, c.ns, name), &v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*v1.PodTemplate), err
}
func (c *FakePodTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplateList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(podtemplatesResource, podtemplatesKind, c.ns, opts), &v1.PodTemplateList{})
Invokes(testing.NewListAction(podtemplatesResource, podtemplatesKind, c.ns, opts), &core_v1.PodTemplateList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakePodTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplat
if label == nil {
label = labels.Everything()
}
list := &v1.PodTemplateList{}
for _, item := range obj.(*v1.PodTemplateList).Items {
list := &core_v1.PodTemplateList{}
for _, item := range obj.(*core_v1.PodTemplateList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakePodTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplat
}
// Watch returns a watch.Interface that watches the requested podTemplates.
func (c *FakePodTemplates) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakePodTemplates) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(podtemplatesResource, c.ns, opts))
}
// Patch applies the patch and returns the patched podTemplate.
func (c *FakePodTemplates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) {
func (c *FakePodTemplates) Create(podTemplate *core_v1.PodTemplate) (result *core_v1.PodTemplate, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(podtemplatesResource, c.ns, name, data, subresources...), &v1.PodTemplate{})
Invokes(testing.NewCreateAction(podtemplatesResource, c.ns, podTemplate), &core_v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*v1.PodTemplate), err
return obj.(*core_v1.PodTemplate), err
}
func (c *FakePodTemplates) Update(podTemplate *core_v1.PodTemplate) (result *core_v1.PodTemplate, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podtemplatesResource, c.ns, podTemplate), &core_v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PodTemplate), err
}
func (c *FakePodTemplates) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podtemplatesResource, c.ns, name), &core_v1.PodTemplate{})
return err
}
func (c *FakePodTemplates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podtemplatesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.PodTemplateList{})
return err
}
// Patch applies the patch and returns the patched podTemplate.
func (c *FakePodTemplates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.PodTemplate, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(podtemplatesResource, c.ns, name, data, subresources...), &core_v1.PodTemplate{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.PodTemplate), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var replicationcontrollersResource = schema.GroupVersionResource{Group: "", Vers
var replicationcontrollersKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "ReplicationController"}
func (c *FakeReplicationControllers) Create(replicationController *v1.ReplicationController) (result *v1.ReplicationController, err error) {
func (c *FakeReplicationControllers) Get(name string, options v1.GetOptions) (result *core_v1.ReplicationController, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(replicationcontrollersResource, c.ns, replicationController), &v1.ReplicationController{})
Invokes(testing.NewGetAction(replicationcontrollersResource, c.ns, name), &core_v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*v1.ReplicationController), err
return obj.(*core_v1.ReplicationController), err
}
func (c *FakeReplicationControllers) Update(replicationController *v1.ReplicationController) (result *v1.ReplicationController, err error) {
func (c *FakeReplicationControllers) List(opts v1.ListOptions) (result *core_v1.ReplicationControllerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(replicationcontrollersResource, c.ns, replicationController), &v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*v1.ReplicationController), err
}
func (c *FakeReplicationControllers) UpdateStatus(replicationController *v1.ReplicationController) (*v1.ReplicationController, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(replicationcontrollersResource, "status", c.ns, replicationController), &v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*v1.ReplicationController), err
}
func (c *FakeReplicationControllers) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(replicationcontrollersResource, c.ns, name), &v1.ReplicationController{})
return err
}
func (c *FakeReplicationControllers) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(replicationcontrollersResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.ReplicationControllerList{})
return err
}
func (c *FakeReplicationControllers) Get(name string, options meta_v1.GetOptions) (result *v1.ReplicationController, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(replicationcontrollersResource, c.ns, name), &v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*v1.ReplicationController), err
}
func (c *FakeReplicationControllers) List(opts meta_v1.ListOptions) (result *v1.ReplicationControllerList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(replicationcontrollersResource, replicationcontrollersKind, c.ns, opts), &v1.ReplicationControllerList{})
Invokes(testing.NewListAction(replicationcontrollersResource, replicationcontrollersKind, c.ns, opts), &core_v1.ReplicationControllerList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakeReplicationControllers) List(opts meta_v1.ListOptions) (result *v1.
if label == nil {
label = labels.Everything()
}
list := &v1.ReplicationControllerList{}
for _, item := range obj.(*v1.ReplicationControllerList).Items {
list := &core_v1.ReplicationControllerList{}
for _, item := range obj.(*core_v1.ReplicationControllerList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakeReplicationControllers) List(opts meta_v1.ListOptions) (result *v1.
}
// Watch returns a watch.Interface that watches the requested replicationControllers.
func (c *FakeReplicationControllers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeReplicationControllers) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(replicationcontrollersResource, c.ns, opts))
}
// Patch applies the patch and returns the patched replicationController.
func (c *FakeReplicationControllers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) {
func (c *FakeReplicationControllers) Create(replicationController *core_v1.ReplicationController) (result *core_v1.ReplicationController, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(replicationcontrollersResource, c.ns, name, data, subresources...), &v1.ReplicationController{})
Invokes(testing.NewCreateAction(replicationcontrollersResource, c.ns, replicationController), &core_v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*v1.ReplicationController), err
return obj.(*core_v1.ReplicationController), err
}
func (c *FakeReplicationControllers) Update(replicationController *core_v1.ReplicationController) (result *core_v1.ReplicationController, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(replicationcontrollersResource, c.ns, replicationController), &core_v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ReplicationController), err
}
func (c *FakeReplicationControllers) UpdateStatus(replicationController *core_v1.ReplicationController) (*core_v1.ReplicationController, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(replicationcontrollersResource, "status", c.ns, replicationController), &core_v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ReplicationController), err
}
func (c *FakeReplicationControllers) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(replicationcontrollersResource, c.ns, name), &core_v1.ReplicationController{})
return err
}
func (c *FakeReplicationControllers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(replicationcontrollersResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ReplicationControllerList{})
return err
}
// Patch applies the patch and returns the patched replicationController.
func (c *FakeReplicationControllers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.ReplicationController, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(replicationcontrollersResource, c.ns, name, data, subresources...), &core_v1.ReplicationController{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ReplicationController), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var resourcequotasResource = schema.GroupVersionResource{Group: "", Version: "v1
var resourcequotasKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "ResourceQuota"}
func (c *FakeResourceQuotas) Create(resourceQuota *v1.ResourceQuota) (result *v1.ResourceQuota, err error) {
func (c *FakeResourceQuotas) Get(name string, options v1.GetOptions) (result *core_v1.ResourceQuota, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(resourcequotasResource, c.ns, resourceQuota), &v1.ResourceQuota{})
Invokes(testing.NewGetAction(resourcequotasResource, c.ns, name), &core_v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*v1.ResourceQuota), err
return obj.(*core_v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) Update(resourceQuota *v1.ResourceQuota) (result *v1.ResourceQuota, err error) {
func (c *FakeResourceQuotas) List(opts v1.ListOptions) (result *core_v1.ResourceQuotaList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(resourcequotasResource, c.ns, resourceQuota), &v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) UpdateStatus(resourceQuota *v1.ResourceQuota) (*v1.ResourceQuota, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(resourcequotasResource, "status", c.ns, resourceQuota), &v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(resourcequotasResource, c.ns, name), &v1.ResourceQuota{})
return err
}
func (c *FakeResourceQuotas) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(resourcequotasResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.ResourceQuotaList{})
return err
}
func (c *FakeResourceQuotas) Get(name string, options meta_v1.GetOptions) (result *v1.ResourceQuota, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(resourcequotasResource, c.ns, name), &v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) List(opts meta_v1.ListOptions) (result *v1.ResourceQuotaList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(resourcequotasResource, resourcequotasKind, c.ns, opts), &v1.ResourceQuotaList{})
Invokes(testing.NewListAction(resourcequotasResource, resourcequotasKind, c.ns, opts), &core_v1.ResourceQuotaList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakeResourceQuotas) List(opts meta_v1.ListOptions) (result *v1.Resource
if label == nil {
label = labels.Everything()
}
list := &v1.ResourceQuotaList{}
for _, item := range obj.(*v1.ResourceQuotaList).Items {
list := &core_v1.ResourceQuotaList{}
for _, item := range obj.(*core_v1.ResourceQuotaList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakeResourceQuotas) List(opts meta_v1.ListOptions) (result *v1.Resource
}
// Watch returns a watch.Interface that watches the requested resourceQuotas.
func (c *FakeResourceQuotas) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeResourceQuotas) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(resourcequotasResource, c.ns, opts))
}
// Patch applies the patch and returns the patched resourceQuota.
func (c *FakeResourceQuotas) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) {
func (c *FakeResourceQuotas) Create(resourceQuota *core_v1.ResourceQuota) (result *core_v1.ResourceQuota, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(resourcequotasResource, c.ns, name, data, subresources...), &v1.ResourceQuota{})
Invokes(testing.NewCreateAction(resourcequotasResource, c.ns, resourceQuota), &core_v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*v1.ResourceQuota), err
return obj.(*core_v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) Update(resourceQuota *core_v1.ResourceQuota) (result *core_v1.ResourceQuota, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(resourcequotasResource, c.ns, resourceQuota), &core_v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) UpdateStatus(resourceQuota *core_v1.ResourceQuota) (*core_v1.ResourceQuota, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(resourcequotasResource, "status", c.ns, resourceQuota), &core_v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ResourceQuota), err
}
func (c *FakeResourceQuotas) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(resourcequotasResource, c.ns, name), &core_v1.ResourceQuota{})
return err
}
func (c *FakeResourceQuotas) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(resourcequotasResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ResourceQuotaList{})
return err
}
// Patch applies the patch and returns the patched resourceQuota.
func (c *FakeResourceQuotas) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.ResourceQuota, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(resourcequotasResource, c.ns, name, data, subresources...), &core_v1.ResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ResourceQuota), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var secretsResource = schema.GroupVersionResource{Group: "", Version: "v1", Reso
var secretsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Secret"}
func (c *FakeSecrets) Create(secret *v1.Secret) (result *v1.Secret, err error) {
func (c *FakeSecrets) Get(name string, options v1.GetOptions) (result *core_v1.Secret, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(secretsResource, c.ns, secret), &v1.Secret{})
Invokes(testing.NewGetAction(secretsResource, c.ns, name), &core_v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*v1.Secret), err
return obj.(*core_v1.Secret), err
}
func (c *FakeSecrets) Update(secret *v1.Secret) (result *v1.Secret, err error) {
func (c *FakeSecrets) List(opts v1.ListOptions) (result *core_v1.SecretList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(secretsResource, c.ns, secret), &v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*v1.Secret), err
}
func (c *FakeSecrets) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(secretsResource, c.ns, name), &v1.Secret{})
return err
}
func (c *FakeSecrets) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(secretsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.SecretList{})
return err
}
func (c *FakeSecrets) Get(name string, options meta_v1.GetOptions) (result *v1.Secret, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(secretsResource, c.ns, name), &v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*v1.Secret), err
}
func (c *FakeSecrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(secretsResource, secretsKind, c.ns, opts), &v1.SecretList{})
Invokes(testing.NewListAction(secretsResource, secretsKind, c.ns, opts), &core_v1.SecretList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeSecrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err
if label == nil {
label = labels.Everything()
}
list := &v1.SecretList{}
for _, item := range obj.(*v1.SecretList).Items {
list := &core_v1.SecretList{}
for _, item := range obj.(*core_v1.SecretList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeSecrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err
}
// Watch returns a watch.Interface that watches the requested secrets.
func (c *FakeSecrets) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeSecrets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(secretsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched secret.
func (c *FakeSecrets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) {
func (c *FakeSecrets) Create(secret *core_v1.Secret) (result *core_v1.Secret, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(secretsResource, c.ns, name, data, subresources...), &v1.Secret{})
Invokes(testing.NewCreateAction(secretsResource, c.ns, secret), &core_v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*v1.Secret), err
return obj.(*core_v1.Secret), err
}
func (c *FakeSecrets) Update(secret *core_v1.Secret) (result *core_v1.Secret, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(secretsResource, c.ns, secret), &core_v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Secret), err
}
func (c *FakeSecrets) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(secretsResource, c.ns, name), &core_v1.Secret{})
return err
}
func (c *FakeSecrets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(secretsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.SecretList{})
return err
}
// Patch applies the patch and returns the patched secret.
func (c *FakeSecrets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Secret, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(secretsResource, c.ns, name, data, subresources...), &core_v1.Secret{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Secret), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,63 +36,19 @@ var servicesResource = schema.GroupVersionResource{Group: "", Version: "v1", Res
var servicesKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "Service"}
func (c *FakeServices) Create(service *v1.Service) (result *v1.Service, err error) {
func (c *FakeServices) Get(name string, options v1.GetOptions) (result *core_v1.Service, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(servicesResource, c.ns, service), &v1.Service{})
Invokes(testing.NewGetAction(servicesResource, c.ns, name), &core_v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*v1.Service), err
return obj.(*core_v1.Service), err
}
func (c *FakeServices) Update(service *v1.Service) (result *v1.Service, err error) {
func (c *FakeServices) List(opts v1.ListOptions) (result *core_v1.ServiceList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(servicesResource, c.ns, service), &v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*v1.Service), err
}
func (c *FakeServices) UpdateStatus(service *v1.Service) (*v1.Service, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(servicesResource, "status", c.ns, service), &v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*v1.Service), err
}
func (c *FakeServices) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(servicesResource, c.ns, name), &v1.Service{})
return err
}
func (c *FakeServices) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(servicesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.ServiceList{})
return err
}
func (c *FakeServices) Get(name string, options meta_v1.GetOptions) (result *v1.Service, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(servicesResource, c.ns, name), &v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*v1.Service), err
}
func (c *FakeServices) List(opts meta_v1.ListOptions) (result *v1.ServiceList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(servicesResource, servicesKind, c.ns, opts), &v1.ServiceList{})
Invokes(testing.NewListAction(servicesResource, servicesKind, c.ns, opts), &core_v1.ServiceList{})
if obj == nil {
return nil, err
@ -102,8 +58,8 @@ func (c *FakeServices) List(opts meta_v1.ListOptions) (result *v1.ServiceList, e
if label == nil {
label = labels.Everything()
}
list := &v1.ServiceList{}
for _, item := range obj.(*v1.ServiceList).Items {
list := &core_v1.ServiceList{}
for _, item := range obj.(*core_v1.ServiceList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -112,19 +68,63 @@ func (c *FakeServices) List(opts meta_v1.ListOptions) (result *v1.ServiceList, e
}
// Watch returns a watch.Interface that watches the requested services.
func (c *FakeServices) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeServices) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(servicesResource, c.ns, opts))
}
// Patch applies the patch and returns the patched service.
func (c *FakeServices) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) {
func (c *FakeServices) Create(service *core_v1.Service) (result *core_v1.Service, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(servicesResource, c.ns, name, data, subresources...), &v1.Service{})
Invokes(testing.NewCreateAction(servicesResource, c.ns, service), &core_v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*v1.Service), err
return obj.(*core_v1.Service), err
}
func (c *FakeServices) Update(service *core_v1.Service) (result *core_v1.Service, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(servicesResource, c.ns, service), &core_v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Service), err
}
func (c *FakeServices) UpdateStatus(service *core_v1.Service) (*core_v1.Service, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(servicesResource, "status", c.ns, service), &core_v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Service), err
}
func (c *FakeServices) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(servicesResource, c.ns, name), &core_v1.Service{})
return err
}
func (c *FakeServices) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(servicesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ServiceList{})
return err
}
// Patch applies the patch and returns the patched service.
func (c *FakeServices) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.Service, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(servicesResource, c.ns, name, data, subresources...), &core_v1.Service{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.Service), err
}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/core/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
core_v1 "k8s.io/api/core/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var serviceaccountsResource = schema.GroupVersionResource{Group: "", Version: "v
var serviceaccountsKind = schema.GroupVersionKind{Group: "", Version: "v1", Kind: "ServiceAccount"}
func (c *FakeServiceAccounts) Create(serviceAccount *v1.ServiceAccount) (result *v1.ServiceAccount, err error) {
func (c *FakeServiceAccounts) Get(name string, options v1.GetOptions) (result *core_v1.ServiceAccount, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(serviceaccountsResource, c.ns, serviceAccount), &v1.ServiceAccount{})
Invokes(testing.NewGetAction(serviceaccountsResource, c.ns, name), &core_v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*v1.ServiceAccount), err
return obj.(*core_v1.ServiceAccount), err
}
func (c *FakeServiceAccounts) Update(serviceAccount *v1.ServiceAccount) (result *v1.ServiceAccount, err error) {
func (c *FakeServiceAccounts) List(opts v1.ListOptions) (result *core_v1.ServiceAccountList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(serviceaccountsResource, c.ns, serviceAccount), &v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*v1.ServiceAccount), err
}
func (c *FakeServiceAccounts) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(serviceaccountsResource, c.ns, name), &v1.ServiceAccount{})
return err
}
func (c *FakeServiceAccounts) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(serviceaccountsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.ServiceAccountList{})
return err
}
func (c *FakeServiceAccounts) Get(name string, options meta_v1.GetOptions) (result *v1.ServiceAccount, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(serviceaccountsResource, c.ns, name), &v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*v1.ServiceAccount), err
}
func (c *FakeServiceAccounts) List(opts meta_v1.ListOptions) (result *v1.ServiceAccountList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(serviceaccountsResource, serviceaccountsKind, c.ns, opts), &v1.ServiceAccountList{})
Invokes(testing.NewListAction(serviceaccountsResource, serviceaccountsKind, c.ns, opts), &core_v1.ServiceAccountList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeServiceAccounts) List(opts meta_v1.ListOptions) (result *v1.Service
if label == nil {
label = labels.Everything()
}
list := &v1.ServiceAccountList{}
for _, item := range obj.(*v1.ServiceAccountList).Items {
list := &core_v1.ServiceAccountList{}
for _, item := range obj.(*core_v1.ServiceAccountList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeServiceAccounts) List(opts meta_v1.ListOptions) (result *v1.Service
}
// Watch returns a watch.Interface that watches the requested serviceAccounts.
func (c *FakeServiceAccounts) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeServiceAccounts) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(serviceaccountsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched serviceAccount.
func (c *FakeServiceAccounts) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) {
func (c *FakeServiceAccounts) Create(serviceAccount *core_v1.ServiceAccount) (result *core_v1.ServiceAccount, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(serviceaccountsResource, c.ns, name, data, subresources...), &v1.ServiceAccount{})
Invokes(testing.NewCreateAction(serviceaccountsResource, c.ns, serviceAccount), &core_v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*v1.ServiceAccount), err
return obj.(*core_v1.ServiceAccount), err
}
func (c *FakeServiceAccounts) Update(serviceAccount *core_v1.ServiceAccount) (result *core_v1.ServiceAccount, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(serviceaccountsResource, c.ns, serviceAccount), &core_v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ServiceAccount), err
}
func (c *FakeServiceAccounts) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(serviceaccountsResource, c.ns, name), &core_v1.ServiceAccount{})
return err
}
func (c *FakeServiceAccounts) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(serviceaccountsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &core_v1.ServiceAccountList{})
return err
}
// Patch applies the patch and returns the patched serviceAccount.
func (c *FakeServiceAccounts) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *core_v1.ServiceAccount, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(serviceaccountsResource, c.ns, name, data, subresources...), &core_v1.ServiceAccount{})
if obj == nil {
return nil, err
}
return obj.(*core_v1.ServiceAccount), err
}

View File

@ -58,6 +58,41 @@ func newLimitRanges(c *CoreV1Client, namespace string) *limitRanges {
}
}
// Get takes name of the limitRange, and returns the corresponding limitRange object, and an error if there is any.
func (c *limitRanges) Get(name string, options meta_v1.GetOptions) (result *v1.LimitRange, err error) {
result = &v1.LimitRange{}
err = c.client.Get().
Namespace(c.ns).
Resource("limitranges").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of LimitRanges that match those selectors.
func (c *limitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeList, err error) {
result = &v1.LimitRangeList{}
err = c.client.Get().
Namespace(c.ns).
Resource("limitranges").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested limitRanges.
func (c *limitRanges) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("limitranges").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a limitRange and creates it. Returns the server's representation of the limitRange, and an error, if there is any.
func (c *limitRanges) Create(limitRange *v1.LimitRange) (result *v1.LimitRange, err error) {
result = &v1.LimitRange{}
@ -105,41 +140,6 @@ func (c *limitRanges) DeleteCollection(options *meta_v1.DeleteOptions, listOptio
Error()
}
// Get takes name of the limitRange, and returns the corresponding limitRange object, and an error if there is any.
func (c *limitRanges) Get(name string, options meta_v1.GetOptions) (result *v1.LimitRange, err error) {
result = &v1.LimitRange{}
err = c.client.Get().
Namespace(c.ns).
Resource("limitranges").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of LimitRanges that match those selectors.
func (c *limitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeList, err error) {
result = &v1.LimitRangeList{}
err = c.client.Get().
Namespace(c.ns).
Resource("limitranges").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested limitRanges.
func (c *limitRanges) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("limitranges").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched limitRange.
func (c *limitRanges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) {
result = &v1.LimitRange{}

View File

@ -57,6 +57,38 @@ func newNamespaces(c *CoreV1Client) *namespaces {
}
}
// Get takes name of the namespace, and returns the corresponding namespace object, and an error if there is any.
func (c *namespaces) Get(name string, options meta_v1.GetOptions) (result *v1.Namespace, err error) {
result = &v1.Namespace{}
err = c.client.Get().
Resource("namespaces").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Namespaces that match those selectors.
func (c *namespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceList, err error) {
result = &v1.NamespaceList{}
err = c.client.Get().
Resource("namespaces").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested namespaces.
func (c *namespaces) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("namespaces").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a namespace and creates it. Returns the server's representation of the namespace, and an error, if there is any.
func (c *namespaces) Create(namespace *v1.Namespace) (result *v1.Namespace, err error) {
result = &v1.Namespace{}
@ -81,7 +113,7 @@ func (c *namespaces) Update(namespace *v1.Namespace) (result *v1.Namespace, err
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *namespaces) UpdateStatus(namespace *v1.Namespace) (result *v1.Namespace, err error) {
result = &v1.Namespace{}
@ -115,38 +147,6 @@ func (c *namespaces) DeleteCollection(options *meta_v1.DeleteOptions, listOption
Error()
}
// Get takes name of the namespace, and returns the corresponding namespace object, and an error if there is any.
func (c *namespaces) Get(name string, options meta_v1.GetOptions) (result *v1.Namespace, err error) {
result = &v1.Namespace{}
err = c.client.Get().
Resource("namespaces").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Namespaces that match those selectors.
func (c *namespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceList, err error) {
result = &v1.NamespaceList{}
err = c.client.Get().
Resource("namespaces").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested namespaces.
func (c *namespaces) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("namespaces").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched namespace.
func (c *namespaces) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) {
result = &v1.Namespace{}

View File

@ -57,6 +57,38 @@ func newNodes(c *CoreV1Client) *nodes {
}
}
// Get takes name of the node, and returns the corresponding node object, and an error if there is any.
func (c *nodes) Get(name string, options meta_v1.GetOptions) (result *v1.Node, err error) {
result = &v1.Node{}
err = c.client.Get().
Resource("nodes").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Nodes that match those selectors.
func (c *nodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err error) {
result = &v1.NodeList{}
err = c.client.Get().
Resource("nodes").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested nodes.
func (c *nodes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("nodes").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a node and creates it. Returns the server's representation of the node, and an error, if there is any.
func (c *nodes) Create(node *v1.Node) (result *v1.Node, err error) {
result = &v1.Node{}
@ -81,7 +113,7 @@ func (c *nodes) Update(node *v1.Node) (result *v1.Node, err error) {
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *nodes) UpdateStatus(node *v1.Node) (result *v1.Node, err error) {
result = &v1.Node{}
@ -115,38 +147,6 @@ func (c *nodes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions met
Error()
}
// Get takes name of the node, and returns the corresponding node object, and an error if there is any.
func (c *nodes) Get(name string, options meta_v1.GetOptions) (result *v1.Node, err error) {
result = &v1.Node{}
err = c.client.Get().
Resource("nodes").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Nodes that match those selectors.
func (c *nodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err error) {
result = &v1.NodeList{}
err = c.client.Get().
Resource("nodes").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested nodes.
func (c *nodes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("nodes").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched node.
func (c *nodes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) {
result = &v1.Node{}

View File

@ -57,6 +57,38 @@ func newPersistentVolumes(c *CoreV1Client) *persistentVolumes {
}
}
// Get takes name of the persistentVolume, and returns the corresponding persistentVolume object, and an error if there is any.
func (c *persistentVolumes) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolume, err error) {
result = &v1.PersistentVolume{}
err = c.client.Get().
Resource("persistentvolumes").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PersistentVolumes that match those selectors.
func (c *persistentVolumes) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeList, err error) {
result = &v1.PersistentVolumeList{}
err = c.client.Get().
Resource("persistentvolumes").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested persistentVolumes.
func (c *persistentVolumes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("persistentvolumes").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a persistentVolume and creates it. Returns the server's representation of the persistentVolume, and an error, if there is any.
func (c *persistentVolumes) Create(persistentVolume *v1.PersistentVolume) (result *v1.PersistentVolume, err error) {
result = &v1.PersistentVolume{}
@ -81,7 +113,7 @@ func (c *persistentVolumes) Update(persistentVolume *v1.PersistentVolume) (resul
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *persistentVolumes) UpdateStatus(persistentVolume *v1.PersistentVolume) (result *v1.PersistentVolume, err error) {
result = &v1.PersistentVolume{}
@ -115,38 +147,6 @@ func (c *persistentVolumes) DeleteCollection(options *meta_v1.DeleteOptions, lis
Error()
}
// Get takes name of the persistentVolume, and returns the corresponding persistentVolume object, and an error if there is any.
func (c *persistentVolumes) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolume, err error) {
result = &v1.PersistentVolume{}
err = c.client.Get().
Resource("persistentvolumes").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PersistentVolumes that match those selectors.
func (c *persistentVolumes) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeList, err error) {
result = &v1.PersistentVolumeList{}
err = c.client.Get().
Resource("persistentvolumes").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested persistentVolumes.
func (c *persistentVolumes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("persistentvolumes").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched persistentVolume.
func (c *persistentVolumes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) {
result = &v1.PersistentVolume{}

View File

@ -59,6 +59,41 @@ func newPersistentVolumeClaims(c *CoreV1Client, namespace string) *persistentVol
}
}
// Get takes name of the persistentVolumeClaim, and returns the corresponding persistentVolumeClaim object, and an error if there is any.
func (c *persistentVolumeClaims) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolumeClaim, err error) {
result = &v1.PersistentVolumeClaim{}
err = c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PersistentVolumeClaims that match those selectors.
func (c *persistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeClaimList, err error) {
result = &v1.PersistentVolumeClaimList{}
err = c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested persistentVolumeClaims.
func (c *persistentVolumeClaims) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a persistentVolumeClaim and creates it. Returns the server's representation of the persistentVolumeClaim, and an error, if there is any.
func (c *persistentVolumeClaims) Create(persistentVolumeClaim *v1.PersistentVolumeClaim) (result *v1.PersistentVolumeClaim, err error) {
result = &v1.PersistentVolumeClaim{}
@ -85,7 +120,7 @@ func (c *persistentVolumeClaims) Update(persistentVolumeClaim *v1.PersistentVolu
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *persistentVolumeClaims) UpdateStatus(persistentVolumeClaim *v1.PersistentVolumeClaim) (result *v1.PersistentVolumeClaim, err error) {
result = &v1.PersistentVolumeClaim{}
@ -122,41 +157,6 @@ func (c *persistentVolumeClaims) DeleteCollection(options *meta_v1.DeleteOptions
Error()
}
// Get takes name of the persistentVolumeClaim, and returns the corresponding persistentVolumeClaim object, and an error if there is any.
func (c *persistentVolumeClaims) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolumeClaim, err error) {
result = &v1.PersistentVolumeClaim{}
err = c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PersistentVolumeClaims that match those selectors.
func (c *persistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeClaimList, err error) {
result = &v1.PersistentVolumeClaimList{}
err = c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested persistentVolumeClaims.
func (c *persistentVolumeClaims) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("persistentvolumeclaims").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched persistentVolumeClaim.
func (c *persistentVolumeClaims) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) {
result = &v1.PersistentVolumeClaim{}

View File

@ -59,6 +59,41 @@ func newPods(c *CoreV1Client, namespace string) *pods {
}
}
// Get takes name of the pod, and returns the corresponding pod object, and an error if there is any.
func (c *pods) Get(name string, options meta_v1.GetOptions) (result *v1.Pod, err error) {
result = &v1.Pod{}
err = c.client.Get().
Namespace(c.ns).
Resource("pods").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Pods that match those selectors.
func (c *pods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error) {
result = &v1.PodList{}
err = c.client.Get().
Namespace(c.ns).
Resource("pods").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested pods.
func (c *pods) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("pods").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a pod and creates it. Returns the server's representation of the pod, and an error, if there is any.
func (c *pods) Create(pod *v1.Pod) (result *v1.Pod, err error) {
result = &v1.Pod{}
@ -85,7 +120,7 @@ func (c *pods) Update(pod *v1.Pod) (result *v1.Pod, err error) {
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *pods) UpdateStatus(pod *v1.Pod) (result *v1.Pod, err error) {
result = &v1.Pod{}
@ -122,41 +157,6 @@ func (c *pods) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta
Error()
}
// Get takes name of the pod, and returns the corresponding pod object, and an error if there is any.
func (c *pods) Get(name string, options meta_v1.GetOptions) (result *v1.Pod, err error) {
result = &v1.Pod{}
err = c.client.Get().
Namespace(c.ns).
Resource("pods").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Pods that match those selectors.
func (c *pods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error) {
result = &v1.PodList{}
err = c.client.Get().
Namespace(c.ns).
Resource("pods").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested pods.
func (c *pods) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("pods").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched pod.
func (c *pods) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) {
result = &v1.Pod{}

View File

@ -58,6 +58,41 @@ func newPodTemplates(c *CoreV1Client, namespace string) *podTemplates {
}
}
// Get takes name of the podTemplate, and returns the corresponding podTemplate object, and an error if there is any.
func (c *podTemplates) Get(name string, options meta_v1.GetOptions) (result *v1.PodTemplate, err error) {
result = &v1.PodTemplate{}
err = c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodTemplates that match those selectors.
func (c *podTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplateList, err error) {
result = &v1.PodTemplateList{}
err = c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podTemplates.
func (c *podTemplates) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a podTemplate and creates it. Returns the server's representation of the podTemplate, and an error, if there is any.
func (c *podTemplates) Create(podTemplate *v1.PodTemplate) (result *v1.PodTemplate, err error) {
result = &v1.PodTemplate{}
@ -105,41 +140,6 @@ func (c *podTemplates) DeleteCollection(options *meta_v1.DeleteOptions, listOpti
Error()
}
// Get takes name of the podTemplate, and returns the corresponding podTemplate object, and an error if there is any.
func (c *podTemplates) Get(name string, options meta_v1.GetOptions) (result *v1.PodTemplate, err error) {
result = &v1.PodTemplate{}
err = c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodTemplates that match those selectors.
func (c *podTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplateList, err error) {
result = &v1.PodTemplateList{}
err = c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podTemplates.
func (c *podTemplates) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("podtemplates").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched podTemplate.
func (c *podTemplates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) {
result = &v1.PodTemplate{}

View File

@ -59,6 +59,41 @@ func newReplicationControllers(c *CoreV1Client, namespace string) *replicationCo
}
}
// Get takes name of the replicationController, and returns the corresponding replicationController object, and an error if there is any.
func (c *replicationControllers) Get(name string, options meta_v1.GetOptions) (result *v1.ReplicationController, err error) {
result = &v1.ReplicationController{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ReplicationControllers that match those selectors.
func (c *replicationControllers) List(opts meta_v1.ListOptions) (result *v1.ReplicationControllerList, err error) {
result = &v1.ReplicationControllerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested replicationControllers.
func (c *replicationControllers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a replicationController and creates it. Returns the server's representation of the replicationController, and an error, if there is any.
func (c *replicationControllers) Create(replicationController *v1.ReplicationController) (result *v1.ReplicationController, err error) {
result = &v1.ReplicationController{}
@ -85,7 +120,7 @@ func (c *replicationControllers) Update(replicationController *v1.ReplicationCon
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *replicationControllers) UpdateStatus(replicationController *v1.ReplicationController) (result *v1.ReplicationController, err error) {
result = &v1.ReplicationController{}
@ -122,41 +157,6 @@ func (c *replicationControllers) DeleteCollection(options *meta_v1.DeleteOptions
Error()
}
// Get takes name of the replicationController, and returns the corresponding replicationController object, and an error if there is any.
func (c *replicationControllers) Get(name string, options meta_v1.GetOptions) (result *v1.ReplicationController, err error) {
result = &v1.ReplicationController{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ReplicationControllers that match those selectors.
func (c *replicationControllers) List(opts meta_v1.ListOptions) (result *v1.ReplicationControllerList, err error) {
result = &v1.ReplicationControllerList{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested replicationControllers.
func (c *replicationControllers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("replicationcontrollers").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched replicationController.
func (c *replicationControllers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) {
result = &v1.ReplicationController{}

View File

@ -59,6 +59,41 @@ func newResourceQuotas(c *CoreV1Client, namespace string) *resourceQuotas {
}
}
// Get takes name of the resourceQuota, and returns the corresponding resourceQuota object, and an error if there is any.
func (c *resourceQuotas) Get(name string, options meta_v1.GetOptions) (result *v1.ResourceQuota, err error) {
result = &v1.ResourceQuota{}
err = c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ResourceQuotas that match those selectors.
func (c *resourceQuotas) List(opts meta_v1.ListOptions) (result *v1.ResourceQuotaList, err error) {
result = &v1.ResourceQuotaList{}
err = c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested resourceQuotas.
func (c *resourceQuotas) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a resourceQuota and creates it. Returns the server's representation of the resourceQuota, and an error, if there is any.
func (c *resourceQuotas) Create(resourceQuota *v1.ResourceQuota) (result *v1.ResourceQuota, err error) {
result = &v1.ResourceQuota{}
@ -85,7 +120,7 @@ func (c *resourceQuotas) Update(resourceQuota *v1.ResourceQuota) (result *v1.Res
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *resourceQuotas) UpdateStatus(resourceQuota *v1.ResourceQuota) (result *v1.ResourceQuota, err error) {
result = &v1.ResourceQuota{}
@ -122,41 +157,6 @@ func (c *resourceQuotas) DeleteCollection(options *meta_v1.DeleteOptions, listOp
Error()
}
// Get takes name of the resourceQuota, and returns the corresponding resourceQuota object, and an error if there is any.
func (c *resourceQuotas) Get(name string, options meta_v1.GetOptions) (result *v1.ResourceQuota, err error) {
result = &v1.ResourceQuota{}
err = c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ResourceQuotas that match those selectors.
func (c *resourceQuotas) List(opts meta_v1.ListOptions) (result *v1.ResourceQuotaList, err error) {
result = &v1.ResourceQuotaList{}
err = c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested resourceQuotas.
func (c *resourceQuotas) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("resourcequotas").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched resourceQuota.
func (c *resourceQuotas) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) {
result = &v1.ResourceQuota{}

View File

@ -58,6 +58,41 @@ func newSecrets(c *CoreV1Client, namespace string) *secrets {
}
}
// Get takes name of the secret, and returns the corresponding secret object, and an error if there is any.
func (c *secrets) Get(name string, options meta_v1.GetOptions) (result *v1.Secret, err error) {
result = &v1.Secret{}
err = c.client.Get().
Namespace(c.ns).
Resource("secrets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Secrets that match those selectors.
func (c *secrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err error) {
result = &v1.SecretList{}
err = c.client.Get().
Namespace(c.ns).
Resource("secrets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested secrets.
func (c *secrets) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("secrets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a secret and creates it. Returns the server's representation of the secret, and an error, if there is any.
func (c *secrets) Create(secret *v1.Secret) (result *v1.Secret, err error) {
result = &v1.Secret{}
@ -105,41 +140,6 @@ func (c *secrets) DeleteCollection(options *meta_v1.DeleteOptions, listOptions m
Error()
}
// Get takes name of the secret, and returns the corresponding secret object, and an error if there is any.
func (c *secrets) Get(name string, options meta_v1.GetOptions) (result *v1.Secret, err error) {
result = &v1.Secret{}
err = c.client.Get().
Namespace(c.ns).
Resource("secrets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Secrets that match those selectors.
func (c *secrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err error) {
result = &v1.SecretList{}
err = c.client.Get().
Namespace(c.ns).
Resource("secrets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested secrets.
func (c *secrets) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("secrets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched secret.
func (c *secrets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) {
result = &v1.Secret{}

View File

@ -59,6 +59,41 @@ func newServices(c *CoreV1Client, namespace string) *services {
}
}
// Get takes name of the service, and returns the corresponding service object, and an error if there is any.
func (c *services) Get(name string, options meta_v1.GetOptions) (result *v1.Service, err error) {
result = &v1.Service{}
err = c.client.Get().
Namespace(c.ns).
Resource("services").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Services that match those selectors.
func (c *services) List(opts meta_v1.ListOptions) (result *v1.ServiceList, err error) {
result = &v1.ServiceList{}
err = c.client.Get().
Namespace(c.ns).
Resource("services").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested services.
func (c *services) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("services").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a service and creates it. Returns the server's representation of the service, and an error, if there is any.
func (c *services) Create(service *v1.Service) (result *v1.Service, err error) {
result = &v1.Service{}
@ -85,7 +120,7 @@ func (c *services) Update(service *v1.Service) (result *v1.Service, err error) {
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *services) UpdateStatus(service *v1.Service) (result *v1.Service, err error) {
result = &v1.Service{}
@ -122,41 +157,6 @@ func (c *services) DeleteCollection(options *meta_v1.DeleteOptions, listOptions
Error()
}
// Get takes name of the service, and returns the corresponding service object, and an error if there is any.
func (c *services) Get(name string, options meta_v1.GetOptions) (result *v1.Service, err error) {
result = &v1.Service{}
err = c.client.Get().
Namespace(c.ns).
Resource("services").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Services that match those selectors.
func (c *services) List(opts meta_v1.ListOptions) (result *v1.ServiceList, err error) {
result = &v1.ServiceList{}
err = c.client.Get().
Namespace(c.ns).
Resource("services").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested services.
func (c *services) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("services").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched service.
func (c *services) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) {
result = &v1.Service{}

View File

@ -58,6 +58,41 @@ func newServiceAccounts(c *CoreV1Client, namespace string) *serviceAccounts {
}
}
// Get takes name of the serviceAccount, and returns the corresponding serviceAccount object, and an error if there is any.
func (c *serviceAccounts) Get(name string, options meta_v1.GetOptions) (result *v1.ServiceAccount, err error) {
result = &v1.ServiceAccount{}
err = c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ServiceAccounts that match those selectors.
func (c *serviceAccounts) List(opts meta_v1.ListOptions) (result *v1.ServiceAccountList, err error) {
result = &v1.ServiceAccountList{}
err = c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested serviceAccounts.
func (c *serviceAccounts) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a serviceAccount and creates it. Returns the server's representation of the serviceAccount, and an error, if there is any.
func (c *serviceAccounts) Create(serviceAccount *v1.ServiceAccount) (result *v1.ServiceAccount, err error) {
result = &v1.ServiceAccount{}
@ -105,41 +140,6 @@ func (c *serviceAccounts) DeleteCollection(options *meta_v1.DeleteOptions, listO
Error()
}
// Get takes name of the serviceAccount, and returns the corresponding serviceAccount object, and an error if there is any.
func (c *serviceAccounts) Get(name string, options meta_v1.GetOptions) (result *v1.ServiceAccount, err error) {
result = &v1.ServiceAccount{}
err = c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ServiceAccounts that match those selectors.
func (c *serviceAccounts) List(opts meta_v1.ListOptions) (result *v1.ServiceAccountList, err error) {
result = &v1.ServiceAccountList{}
err = c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested serviceAccounts.
func (c *serviceAccounts) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("serviceaccounts").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched serviceAccount.
func (c *serviceAccounts) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) {
result = &v1.ServiceAccount{}

View File

@ -59,6 +59,41 @@ func newDaemonSets(c *ExtensionsV1beta1Client, namespace string) *daemonSets {
}
}
// Get takes name of the daemonSet, and returns the corresponding daemonSet object, and an error if there is any.
func (c *daemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) {
result = &v1beta1.DaemonSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of DaemonSets that match those selectors.
func (c *daemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, err error) {
result = &v1beta1.DaemonSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested daemonSets.
func (c *daemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a daemonSet and creates it. Returns the server's representation of the daemonSet, and an error, if there is any.
func (c *daemonSets) Create(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) {
result = &v1beta1.DaemonSet{}
@ -85,7 +120,7 @@ func (c *daemonSets) Update(daemonSet *v1beta1.DaemonSet) (result *v1beta1.Daemo
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *daemonSets) UpdateStatus(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) {
result = &v1beta1.DaemonSet{}
@ -122,41 +157,6 @@ func (c *daemonSets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.
Error()
}
// Get takes name of the daemonSet, and returns the corresponding daemonSet object, and an error if there is any.
func (c *daemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) {
result = &v1beta1.DaemonSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of DaemonSets that match those selectors.
func (c *daemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, err error) {
result = &v1beta1.DaemonSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested daemonSets.
func (c *daemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("daemonsets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched daemonSet.
func (c *daemonSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) {
result = &v1beta1.DaemonSet{}

View File

@ -59,6 +59,41 @@ func newDeployments(c *ExtensionsV1beta1Client, namespace string) *deployments {
}
}
// Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any.
func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Deployments that match those selectors.
func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
result = &v1beta1.DeploymentList{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a deployment and creates it. Returns the server's representation of the deployment, and an error, if there is any.
func (c *deployments) Create(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
@ -85,7 +120,7 @@ func (c *deployments) Update(deployment *v1beta1.Deployment) (result *v1beta1.De
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *deployments) UpdateStatus(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
@ -122,41 +157,6 @@ func (c *deployments) DeleteCollection(options *v1.DeleteOptions, listOptions v1
Error()
}
// Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any.
func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Deployments that match those selectors.
func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
result = &v1beta1.DeploymentList{}
err = c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("deployments").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched deployment.
func (c *deployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) {
result = &v1beta1.Deployment{}

View File

@ -36,6 +36,44 @@ var daemonsetsResource = schema.GroupVersionResource{Group: "extensions", Versio
var daemonsetsKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "DaemonSet"}
func (c *FakeDaemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(daemonsetsResource, c.ns, name), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
func (c *FakeDaemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(daemonsetsResource, daemonsetsKind, c.ns, opts), &v1beta1.DaemonSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DaemonSetList{}
for _, item := range obj.(*v1beta1.DaemonSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested daemonSets.
func (c *FakeDaemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(daemonsetsResource, c.ns, opts))
}
func (c *FakeDaemonSets) Create(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(daemonsetsResource, c.ns, daemonSet), &v1beta1.DaemonSet{})
@ -80,44 +118,6 @@ func (c *FakeDaemonSets) DeleteCollection(options *v1.DeleteOptions, listOptions
return err
}
func (c *FakeDaemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(daemonsetsResource, c.ns, name), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
func (c *FakeDaemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(daemonsetsResource, daemonsetsKind, c.ns, opts), &v1beta1.DaemonSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DaemonSetList{}
for _, item := range obj.(*v1beta1.DaemonSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested daemonSets.
func (c *FakeDaemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(daemonsetsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched daemonSet.
func (c *FakeDaemonSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.

View File

@ -36,6 +36,44 @@ var deploymentsResource = schema.GroupVersionResource{Group: "extensions", Versi
var deploymentsKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "Deployment"}
func (c *FakeDeployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(deploymentsResource, c.ns, name), &v1beta1.Deployment{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Deployment), err
}
func (c *FakeDeployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(deploymentsResource, deploymentsKind, c.ns, opts), &v1beta1.DeploymentList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DeploymentList{}
for _, item := range obj.(*v1beta1.DeploymentList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *FakeDeployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(deploymentsResource, c.ns, opts))
}
func (c *FakeDeployments) Create(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(deploymentsResource, c.ns, deployment), &v1beta1.Deployment{})
@ -80,44 +118,6 @@ func (c *FakeDeployments) DeleteCollection(options *v1.DeleteOptions, listOption
return err
}
func (c *FakeDeployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(deploymentsResource, c.ns, name), &v1beta1.Deployment{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Deployment), err
}
func (c *FakeDeployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(deploymentsResource, deploymentsKind, c.ns, opts), &v1beta1.DeploymentList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DeploymentList{}
for _, item := range obj.(*v1beta1.DeploymentList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested deployments.
func (c *FakeDeployments) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(deploymentsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched deployment.
func (c *FakeDeployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) {
obj, err := c.Fake.

View File

@ -36,6 +36,44 @@ var ingressesResource = schema.GroupVersionResource{Group: "extensions", Version
var ingressesKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "Ingress"}
func (c *FakeIngresses) Get(name string, options v1.GetOptions) (result *v1beta1.Ingress, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(ingressesResource, c.ns, name), &v1beta1.Ingress{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Ingress), err
}
func (c *FakeIngresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(ingressesResource, ingressesKind, c.ns, opts), &v1beta1.IngressList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.IngressList{}
for _, item := range obj.(*v1beta1.IngressList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested ingresses.
func (c *FakeIngresses) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(ingressesResource, c.ns, opts))
}
func (c *FakeIngresses) Create(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(ingressesResource, c.ns, ingress), &v1beta1.Ingress{})
@ -80,44 +118,6 @@ func (c *FakeIngresses) DeleteCollection(options *v1.DeleteOptions, listOptions
return err
}
func (c *FakeIngresses) Get(name string, options v1.GetOptions) (result *v1beta1.Ingress, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(ingressesResource, c.ns, name), &v1beta1.Ingress{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Ingress), err
}
func (c *FakeIngresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(ingressesResource, ingressesKind, c.ns, opts), &v1beta1.IngressList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.IngressList{}
for _, item := range obj.(*v1beta1.IngressList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested ingresses.
func (c *FakeIngresses) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(ingressesResource, c.ns, opts))
}
// Patch applies the patch and returns the patched ingress.
func (c *FakeIngresses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) {
obj, err := c.Fake.

View File

@ -35,37 +35,6 @@ var podsecuritypoliciesResource = schema.GroupVersionResource{Group: "extensions
var podsecuritypoliciesKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "PodSecurityPolicy"}
func (c *FakePodSecurityPolicies) Create(podSecurityPolicy *v1beta1.PodSecurityPolicy) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(podsecuritypoliciesResource, podSecurityPolicy), &v1beta1.PodSecurityPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodSecurityPolicy), err
}
func (c *FakePodSecurityPolicies) Update(podSecurityPolicy *v1beta1.PodSecurityPolicy) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(podsecuritypoliciesResource, podSecurityPolicy), &v1beta1.PodSecurityPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodSecurityPolicy), err
}
func (c *FakePodSecurityPolicies) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(podsecuritypoliciesResource, name), &v1beta1.PodSecurityPolicy{})
return err
}
func (c *FakePodSecurityPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(podsecuritypoliciesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.PodSecurityPolicyList{})
return err
}
func (c *FakePodSecurityPolicies) Get(name string, options v1.GetOptions) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(podsecuritypoliciesResource, name), &v1beta1.PodSecurityPolicy{})
@ -101,6 +70,37 @@ func (c *FakePodSecurityPolicies) Watch(opts v1.ListOptions) (watch.Interface, e
InvokesWatch(testing.NewRootWatchAction(podsecuritypoliciesResource, opts))
}
func (c *FakePodSecurityPolicies) Create(podSecurityPolicy *v1beta1.PodSecurityPolicy) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(podsecuritypoliciesResource, podSecurityPolicy), &v1beta1.PodSecurityPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodSecurityPolicy), err
}
func (c *FakePodSecurityPolicies) Update(podSecurityPolicy *v1beta1.PodSecurityPolicy) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(podsecuritypoliciesResource, podSecurityPolicy), &v1beta1.PodSecurityPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodSecurityPolicy), err
}
func (c *FakePodSecurityPolicies) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(podsecuritypoliciesResource, name), &v1beta1.PodSecurityPolicy{})
return err
}
func (c *FakePodSecurityPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(podsecuritypoliciesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.PodSecurityPolicyList{})
return err
}
// Patch applies the patch and returns the patched podSecurityPolicy.
func (c *FakePodSecurityPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) {
obj, err := c.Fake.

View File

@ -36,6 +36,44 @@ var replicasetsResource = schema.GroupVersionResource{Group: "extensions", Versi
var replicasetsKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "ReplicaSet"}
func (c *FakeReplicaSets) Get(name string, options v1.GetOptions) (result *v1beta1.ReplicaSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(replicasetsResource, c.ns, name), &v1beta1.ReplicaSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ReplicaSet), err
}
func (c *FakeReplicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(replicasetsResource, replicasetsKind, c.ns, opts), &v1beta1.ReplicaSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.ReplicaSetList{}
for _, item := range obj.(*v1beta1.ReplicaSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested replicaSets.
func (c *FakeReplicaSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(replicasetsResource, c.ns, opts))
}
func (c *FakeReplicaSets) Create(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.ReplicaSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(replicasetsResource, c.ns, replicaSet), &v1beta1.ReplicaSet{})
@ -80,44 +118,6 @@ func (c *FakeReplicaSets) DeleteCollection(options *v1.DeleteOptions, listOption
return err
}
func (c *FakeReplicaSets) Get(name string, options v1.GetOptions) (result *v1beta1.ReplicaSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(replicasetsResource, c.ns, name), &v1beta1.ReplicaSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ReplicaSet), err
}
func (c *FakeReplicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(replicasetsResource, replicasetsKind, c.ns, opts), &v1beta1.ReplicaSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.ReplicaSetList{}
for _, item := range obj.(*v1beta1.ReplicaSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested replicaSets.
func (c *FakeReplicaSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(replicasetsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched replicaSet.
func (c *FakeReplicaSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) {
obj, err := c.Fake.

View File

@ -35,37 +35,6 @@ var thirdpartyresourcesResource = schema.GroupVersionResource{Group: "extensions
var thirdpartyresourcesKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "ThirdPartyResource"}
func (c *FakeThirdPartyResources) Create(thirdPartyResource *v1beta1.ThirdPartyResource) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(thirdpartyresourcesResource, thirdPartyResource), &v1beta1.ThirdPartyResource{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ThirdPartyResource), err
}
func (c *FakeThirdPartyResources) Update(thirdPartyResource *v1beta1.ThirdPartyResource) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(thirdpartyresourcesResource, thirdPartyResource), &v1beta1.ThirdPartyResource{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ThirdPartyResource), err
}
func (c *FakeThirdPartyResources) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(thirdpartyresourcesResource, name), &v1beta1.ThirdPartyResource{})
return err
}
func (c *FakeThirdPartyResources) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(thirdpartyresourcesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ThirdPartyResourceList{})
return err
}
func (c *FakeThirdPartyResources) Get(name string, options v1.GetOptions) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(thirdpartyresourcesResource, name), &v1beta1.ThirdPartyResource{})
@ -101,6 +70,37 @@ func (c *FakeThirdPartyResources) Watch(opts v1.ListOptions) (watch.Interface, e
InvokesWatch(testing.NewRootWatchAction(thirdpartyresourcesResource, opts))
}
func (c *FakeThirdPartyResources) Create(thirdPartyResource *v1beta1.ThirdPartyResource) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(thirdpartyresourcesResource, thirdPartyResource), &v1beta1.ThirdPartyResource{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ThirdPartyResource), err
}
func (c *FakeThirdPartyResources) Update(thirdPartyResource *v1beta1.ThirdPartyResource) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(thirdpartyresourcesResource, thirdPartyResource), &v1beta1.ThirdPartyResource{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ThirdPartyResource), err
}
func (c *FakeThirdPartyResources) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(thirdpartyresourcesResource, name), &v1beta1.ThirdPartyResource{})
return err
}
func (c *FakeThirdPartyResources) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(thirdpartyresourcesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ThirdPartyResourceList{})
return err
}
// Patch applies the patch and returns the patched thirdPartyResource.
func (c *FakeThirdPartyResources) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) {
obj, err := c.Fake.

View File

@ -59,6 +59,41 @@ func newIngresses(c *ExtensionsV1beta1Client, namespace string) *ingresses {
}
}
// Get takes name of the ingress, and returns the corresponding ingress object, and an error if there is any.
func (c *ingresses) Get(name string, options v1.GetOptions) (result *v1beta1.Ingress, err error) {
result = &v1beta1.Ingress{}
err = c.client.Get().
Namespace(c.ns).
Resource("ingresses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Ingresses that match those selectors.
func (c *ingresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err error) {
result = &v1beta1.IngressList{}
err = c.client.Get().
Namespace(c.ns).
Resource("ingresses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested ingresses.
func (c *ingresses) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("ingresses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a ingress and creates it. Returns the server's representation of the ingress, and an error, if there is any.
func (c *ingresses) Create(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, err error) {
result = &v1beta1.Ingress{}
@ -85,7 +120,7 @@ func (c *ingresses) Update(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, e
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *ingresses) UpdateStatus(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, err error) {
result = &v1beta1.Ingress{}
@ -122,41 +157,6 @@ func (c *ingresses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.L
Error()
}
// Get takes name of the ingress, and returns the corresponding ingress object, and an error if there is any.
func (c *ingresses) Get(name string, options v1.GetOptions) (result *v1beta1.Ingress, err error) {
result = &v1beta1.Ingress{}
err = c.client.Get().
Namespace(c.ns).
Resource("ingresses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Ingresses that match those selectors.
func (c *ingresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err error) {
result = &v1beta1.IngressList{}
err = c.client.Get().
Namespace(c.ns).
Resource("ingresses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested ingresses.
func (c *ingresses) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("ingresses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched ingress.
func (c *ingresses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) {
result = &v1beta1.Ingress{}

View File

@ -56,6 +56,38 @@ func newPodSecurityPolicies(c *ExtensionsV1beta1Client) *podSecurityPolicies {
}
}
// Get takes name of the podSecurityPolicy, and returns the corresponding podSecurityPolicy object, and an error if there is any.
func (c *podSecurityPolicies) Get(name string, options v1.GetOptions) (result *v1beta1.PodSecurityPolicy, err error) {
result = &v1beta1.PodSecurityPolicy{}
err = c.client.Get().
Resource("podsecuritypolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodSecurityPolicies that match those selectors.
func (c *podSecurityPolicies) List(opts v1.ListOptions) (result *v1beta1.PodSecurityPolicyList, err error) {
result = &v1beta1.PodSecurityPolicyList{}
err = c.client.Get().
Resource("podsecuritypolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podSecurityPolicies.
func (c *podSecurityPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("podsecuritypolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a podSecurityPolicy and creates it. Returns the server's representation of the podSecurityPolicy, and an error, if there is any.
func (c *podSecurityPolicies) Create(podSecurityPolicy *v1beta1.PodSecurityPolicy) (result *v1beta1.PodSecurityPolicy, err error) {
result = &v1beta1.PodSecurityPolicy{}
@ -99,38 +131,6 @@ func (c *podSecurityPolicies) DeleteCollection(options *v1.DeleteOptions, listOp
Error()
}
// Get takes name of the podSecurityPolicy, and returns the corresponding podSecurityPolicy object, and an error if there is any.
func (c *podSecurityPolicies) Get(name string, options v1.GetOptions) (result *v1beta1.PodSecurityPolicy, err error) {
result = &v1beta1.PodSecurityPolicy{}
err = c.client.Get().
Resource("podsecuritypolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodSecurityPolicies that match those selectors.
func (c *podSecurityPolicies) List(opts v1.ListOptions) (result *v1beta1.PodSecurityPolicyList, err error) {
result = &v1beta1.PodSecurityPolicyList{}
err = c.client.Get().
Resource("podsecuritypolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podSecurityPolicies.
func (c *podSecurityPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("podsecuritypolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched podSecurityPolicy.
func (c *podSecurityPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) {
result = &v1beta1.PodSecurityPolicy{}

View File

@ -59,6 +59,41 @@ func newReplicaSets(c *ExtensionsV1beta1Client, namespace string) *replicaSets {
}
}
// Get takes name of the replicaSet, and returns the corresponding replicaSet object, and an error if there is any.
func (c *replicaSets) Get(name string, options v1.GetOptions) (result *v1beta1.ReplicaSet, err error) {
result = &v1beta1.ReplicaSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicasets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ReplicaSets that match those selectors.
func (c *replicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, err error) {
result = &v1beta1.ReplicaSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicasets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested replicaSets.
func (c *replicaSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("replicasets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a replicaSet and creates it. Returns the server's representation of the replicaSet, and an error, if there is any.
func (c *replicaSets) Create(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.ReplicaSet, err error) {
result = &v1beta1.ReplicaSet{}
@ -85,7 +120,7 @@ func (c *replicaSets) Update(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.Re
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *replicaSets) UpdateStatus(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.ReplicaSet, err error) {
result = &v1beta1.ReplicaSet{}
@ -122,41 +157,6 @@ func (c *replicaSets) DeleteCollection(options *v1.DeleteOptions, listOptions v1
Error()
}
// Get takes name of the replicaSet, and returns the corresponding replicaSet object, and an error if there is any.
func (c *replicaSets) Get(name string, options v1.GetOptions) (result *v1beta1.ReplicaSet, err error) {
result = &v1beta1.ReplicaSet{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicasets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ReplicaSets that match those selectors.
func (c *replicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, err error) {
result = &v1beta1.ReplicaSetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("replicasets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested replicaSets.
func (c *replicaSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("replicasets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched replicaSet.
func (c *replicaSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) {
result = &v1beta1.ReplicaSet{}

View File

@ -56,6 +56,38 @@ func newThirdPartyResources(c *ExtensionsV1beta1Client) *thirdPartyResources {
}
}
// Get takes name of the thirdPartyResource, and returns the corresponding thirdPartyResource object, and an error if there is any.
func (c *thirdPartyResources) Get(name string, options v1.GetOptions) (result *v1beta1.ThirdPartyResource, err error) {
result = &v1beta1.ThirdPartyResource{}
err = c.client.Get().
Resource("thirdpartyresources").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ThirdPartyResources that match those selectors.
func (c *thirdPartyResources) List(opts v1.ListOptions) (result *v1beta1.ThirdPartyResourceList, err error) {
result = &v1beta1.ThirdPartyResourceList{}
err = c.client.Get().
Resource("thirdpartyresources").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested thirdPartyResources.
func (c *thirdPartyResources) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("thirdpartyresources").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a thirdPartyResource and creates it. Returns the server's representation of the thirdPartyResource, and an error, if there is any.
func (c *thirdPartyResources) Create(thirdPartyResource *v1beta1.ThirdPartyResource) (result *v1beta1.ThirdPartyResource, err error) {
result = &v1beta1.ThirdPartyResource{}
@ -99,38 +131,6 @@ func (c *thirdPartyResources) DeleteCollection(options *v1.DeleteOptions, listOp
Error()
}
// Get takes name of the thirdPartyResource, and returns the corresponding thirdPartyResource object, and an error if there is any.
func (c *thirdPartyResources) Get(name string, options v1.GetOptions) (result *v1beta1.ThirdPartyResource, err error) {
result = &v1beta1.ThirdPartyResource{}
err = c.client.Get().
Resource("thirdpartyresources").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ThirdPartyResources that match those selectors.
func (c *thirdPartyResources) List(opts v1.ListOptions) (result *v1beta1.ThirdPartyResourceList, err error) {
result = &v1beta1.ThirdPartyResourceList{}
err = c.client.Get().
Resource("thirdpartyresources").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested thirdPartyResources.
func (c *thirdPartyResources) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("thirdpartyresources").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched thirdPartyResource.
func (c *thirdPartyResources) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) {
result = &v1beta1.ThirdPartyResource{}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/networking/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
networking_v1 "k8s.io/api/networking/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -36,53 +36,19 @@ var networkpoliciesResource = schema.GroupVersionResource{Group: "networking.k8s
var networkpoliciesKind = schema.GroupVersionKind{Group: "networking.k8s.io", Version: "v1", Kind: "NetworkPolicy"}
func (c *FakeNetworkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) {
func (c *FakeNetworkPolicies) Get(name string, options v1.GetOptions) (result *networking_v1.NetworkPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{})
Invokes(testing.NewGetAction(networkpoliciesResource, c.ns, name), &networking_v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1.NetworkPolicy), err
return obj.(*networking_v1.NetworkPolicy), err
}
func (c *FakeNetworkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) {
func (c *FakeNetworkPolicies) List(opts v1.ListOptions) (result *networking_v1.NetworkPolicyList, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(networkpoliciesResource, c.ns, networkPolicy), &v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1.NetworkPolicy), err
}
func (c *FakeNetworkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{})
return err
}
func (c *FakeNetworkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(networkpoliciesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1.NetworkPolicyList{})
return err
}
func (c *FakeNetworkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(networkpoliciesResource, c.ns, name), &v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1.NetworkPolicy), err
}
func (c *FakeNetworkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(networkpoliciesResource, networkpoliciesKind, c.ns, opts), &v1.NetworkPolicyList{})
Invokes(testing.NewListAction(networkpoliciesResource, networkpoliciesKind, c.ns, opts), &networking_v1.NetworkPolicyList{})
if obj == nil {
return nil, err
@ -92,8 +58,8 @@ func (c *FakeNetworkPolicies) List(opts meta_v1.ListOptions) (result *v1.Network
if label == nil {
label = labels.Everything()
}
list := &v1.NetworkPolicyList{}
for _, item := range obj.(*v1.NetworkPolicyList).Items {
list := &networking_v1.NetworkPolicyList{}
for _, item := range obj.(*networking_v1.NetworkPolicyList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -102,19 +68,53 @@ func (c *FakeNetworkPolicies) List(opts meta_v1.ListOptions) (result *v1.Network
}
// Watch returns a watch.Interface that watches the requested networkPolicies.
func (c *FakeNetworkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeNetworkPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(networkpoliciesResource, c.ns, opts))
}
// Patch applies the patch and returns the patched networkPolicy.
func (c *FakeNetworkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) {
func (c *FakeNetworkPolicies) Create(networkPolicy *networking_v1.NetworkPolicy) (result *networking_v1.NetworkPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(networkpoliciesResource, c.ns, name, data, subresources...), &v1.NetworkPolicy{})
Invokes(testing.NewCreateAction(networkpoliciesResource, c.ns, networkPolicy), &networking_v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1.NetworkPolicy), err
return obj.(*networking_v1.NetworkPolicy), err
}
func (c *FakeNetworkPolicies) Update(networkPolicy *networking_v1.NetworkPolicy) (result *networking_v1.NetworkPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(networkpoliciesResource, c.ns, networkPolicy), &networking_v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*networking_v1.NetworkPolicy), err
}
func (c *FakeNetworkPolicies) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(networkpoliciesResource, c.ns, name), &networking_v1.NetworkPolicy{})
return err
}
func (c *FakeNetworkPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(networkpoliciesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &networking_v1.NetworkPolicyList{})
return err
}
// Patch applies the patch and returns the patched networkPolicy.
func (c *FakeNetworkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *networking_v1.NetworkPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(networkpoliciesResource, c.ns, name, data, subresources...), &networking_v1.NetworkPolicy{})
if obj == nil {
return nil, err
}
return obj.(*networking_v1.NetworkPolicy), err
}

View File

@ -58,6 +58,41 @@ func newNetworkPolicies(c *NetworkingV1Client, namespace string) *networkPolicie
}
}
// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any.
func (c *networkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) {
result = &v1.NetworkPolicy{}
err = c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors.
func (c *networkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) {
result = &v1.NetworkPolicyList{}
err = c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested networkPolicies.
func (c *networkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a networkPolicy and creates it. Returns the server's representation of the networkPolicy, and an error, if there is any.
func (c *networkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) {
result = &v1.NetworkPolicy{}
@ -105,41 +140,6 @@ func (c *networkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listO
Error()
}
// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any.
func (c *networkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) {
result = &v1.NetworkPolicy{}
err = c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors.
func (c *networkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) {
result = &v1.NetworkPolicyList{}
err = c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested networkPolicies.
func (c *networkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("networkpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched networkPolicy.
func (c *networkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) {
result = &v1.NetworkPolicy{}

View File

@ -36,6 +36,44 @@ var poddisruptionbudgetsResource = schema.GroupVersionResource{Group: "policy",
var poddisruptionbudgetsKind = schema.GroupVersionKind{Group: "policy", Version: "v1beta1", Kind: "PodDisruptionBudget"}
func (c *FakePodDisruptionBudgets) Get(name string, options v1.GetOptions) (result *v1beta1.PodDisruptionBudget, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(poddisruptionbudgetsResource, c.ns, name), &v1beta1.PodDisruptionBudget{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodDisruptionBudget), err
}
func (c *FakePodDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDisruptionBudgetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(poddisruptionbudgetsResource, poddisruptionbudgetsKind, c.ns, opts), &v1beta1.PodDisruptionBudgetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.PodDisruptionBudgetList{}
for _, item := range obj.(*v1beta1.PodDisruptionBudgetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested podDisruptionBudgets.
func (c *FakePodDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(poddisruptionbudgetsResource, c.ns, opts))
}
func (c *FakePodDisruptionBudgets) Create(podDisruptionBudget *v1beta1.PodDisruptionBudget) (result *v1beta1.PodDisruptionBudget, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(poddisruptionbudgetsResource, c.ns, podDisruptionBudget), &v1beta1.PodDisruptionBudget{})
@ -80,44 +118,6 @@ func (c *FakePodDisruptionBudgets) DeleteCollection(options *v1.DeleteOptions, l
return err
}
func (c *FakePodDisruptionBudgets) Get(name string, options v1.GetOptions) (result *v1beta1.PodDisruptionBudget, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(poddisruptionbudgetsResource, c.ns, name), &v1beta1.PodDisruptionBudget{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.PodDisruptionBudget), err
}
func (c *FakePodDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDisruptionBudgetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(poddisruptionbudgetsResource, poddisruptionbudgetsKind, c.ns, opts), &v1beta1.PodDisruptionBudgetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.PodDisruptionBudgetList{}
for _, item := range obj.(*v1beta1.PodDisruptionBudgetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested podDisruptionBudgets.
func (c *FakePodDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(poddisruptionbudgetsResource, c.ns, opts))
}
// Patch applies the patch and returns the patched podDisruptionBudget.
func (c *FakePodDisruptionBudgets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) {
obj, err := c.Fake.

View File

@ -59,6 +59,41 @@ func newPodDisruptionBudgets(c *PolicyV1beta1Client, namespace string) *podDisru
}
}
// Get takes name of the podDisruptionBudget, and returns the corresponding podDisruptionBudget object, and an error if there is any.
func (c *podDisruptionBudgets) Get(name string, options v1.GetOptions) (result *v1beta1.PodDisruptionBudget, err error) {
result = &v1beta1.PodDisruptionBudget{}
err = c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodDisruptionBudgets that match those selectors.
func (c *podDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDisruptionBudgetList, err error) {
result = &v1beta1.PodDisruptionBudgetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podDisruptionBudgets.
func (c *podDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a podDisruptionBudget and creates it. Returns the server's representation of the podDisruptionBudget, and an error, if there is any.
func (c *podDisruptionBudgets) Create(podDisruptionBudget *v1beta1.PodDisruptionBudget) (result *v1beta1.PodDisruptionBudget, err error) {
result = &v1beta1.PodDisruptionBudget{}
@ -85,7 +120,7 @@ func (c *podDisruptionBudgets) Update(podDisruptionBudget *v1beta1.PodDisruption
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus().
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *podDisruptionBudgets) UpdateStatus(podDisruptionBudget *v1beta1.PodDisruptionBudget) (result *v1beta1.PodDisruptionBudget, err error) {
result = &v1beta1.PodDisruptionBudget{}
@ -122,41 +157,6 @@ func (c *podDisruptionBudgets) DeleteCollection(options *v1.DeleteOptions, listO
Error()
}
// Get takes name of the podDisruptionBudget, and returns the corresponding podDisruptionBudget object, and an error if there is any.
func (c *podDisruptionBudgets) Get(name string, options v1.GetOptions) (result *v1beta1.PodDisruptionBudget, err error) {
result = &v1beta1.PodDisruptionBudget{}
err = c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodDisruptionBudgets that match those selectors.
func (c *podDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDisruptionBudgetList, err error) {
result = &v1beta1.PodDisruptionBudgetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podDisruptionBudgets.
func (c *podDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("poddisruptionbudgets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched podDisruptionBudget.
func (c *podDisruptionBudgets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) {
result = &v1beta1.PodDisruptionBudget{}

View File

@ -56,6 +56,38 @@ func newClusterRoles(c *RbacV1alpha1Client) *clusterRoles {
}
}
// Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any.
func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRole, err error) {
result = &v1alpha1.ClusterRole{}
err = c.client.Get().
Resource("clusterroles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoles that match those selectors.
func (c *clusterRoles) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleList, err error) {
result = &v1alpha1.ClusterRoleList{}
err = c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoles.
func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a clusterRole and creates it. Returns the server's representation of the clusterRole, and an error, if there is any.
func (c *clusterRoles) Create(clusterRole *v1alpha1.ClusterRole) (result *v1alpha1.ClusterRole, err error) {
result = &v1alpha1.ClusterRole{}
@ -99,38 +131,6 @@ func (c *clusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v
Error()
}
// Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any.
func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRole, err error) {
result = &v1alpha1.ClusterRole{}
err = c.client.Get().
Resource("clusterroles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoles that match those selectors.
func (c *clusterRoles) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleList, err error) {
result = &v1alpha1.ClusterRoleList{}
err = c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoles.
func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched clusterRole.
func (c *clusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) {
result = &v1alpha1.ClusterRole{}

View File

@ -56,6 +56,38 @@ func newClusterRoleBindings(c *RbacV1alpha1Client) *clusterRoleBindings {
}
}
// Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any.
func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRoleBinding, err error) {
result = &v1alpha1.ClusterRoleBinding{}
err = c.client.Get().
Resource("clusterrolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoleBindings that match those selectors.
func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleBindingList, err error) {
result = &v1alpha1.ClusterRoleBindingList{}
err = c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoleBindings.
func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a clusterRoleBinding and creates it. Returns the server's representation of the clusterRoleBinding, and an error, if there is any.
func (c *clusterRoleBindings) Create(clusterRoleBinding *v1alpha1.ClusterRoleBinding) (result *v1alpha1.ClusterRoleBinding, err error) {
result = &v1alpha1.ClusterRoleBinding{}
@ -99,38 +131,6 @@ func (c *clusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOp
Error()
}
// Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any.
func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRoleBinding, err error) {
result = &v1alpha1.ClusterRoleBinding{}
err = c.client.Get().
Resource("clusterrolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoleBindings that match those selectors.
func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleBindingList, err error) {
result = &v1alpha1.ClusterRoleBindingList{}
err = c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoleBindings.
func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched clusterRoleBinding.
func (c *clusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) {
result = &v1alpha1.ClusterRoleBinding{}

View File

@ -35,37 +35,6 @@ var clusterrolesResource = schema.GroupVersionResource{Group: "rbac.authorizatio
var clusterrolesKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRole"}
func (c *FakeClusterRoles) Create(clusterRole *v1alpha1.ClusterRole) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolesResource, clusterRole), &v1alpha1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRole), err
}
func (c *FakeClusterRoles) Update(clusterRole *v1alpha1.ClusterRole) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolesResource, clusterRole), &v1alpha1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRole), err
}
func (c *FakeClusterRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolesResource, name), &v1alpha1.ClusterRole{})
return err
}
func (c *FakeClusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ClusterRoleList{})
return err
}
func (c *FakeClusterRoles) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(clusterrolesResource, name), &v1alpha1.ClusterRole{})
@ -101,6 +70,37 @@ func (c *FakeClusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
InvokesWatch(testing.NewRootWatchAction(clusterrolesResource, opts))
}
func (c *FakeClusterRoles) Create(clusterRole *v1alpha1.ClusterRole) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolesResource, clusterRole), &v1alpha1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRole), err
}
func (c *FakeClusterRoles) Update(clusterRole *v1alpha1.ClusterRole) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolesResource, clusterRole), &v1alpha1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRole), err
}
func (c *FakeClusterRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolesResource, name), &v1alpha1.ClusterRole{})
return err
}
func (c *FakeClusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ClusterRoleList{})
return err
}
// Patch applies the patch and returns the patched clusterRole.
func (c *FakeClusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) {
obj, err := c.Fake.

View File

@ -35,37 +35,6 @@ var clusterrolebindingsResource = schema.GroupVersionResource{Group: "rbac.autho
var clusterrolebindingsKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "ClusterRoleBinding"}
func (c *FakeClusterRoleBindings) Create(clusterRoleBinding *v1alpha1.ClusterRoleBinding) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolebindingsResource, clusterRoleBinding), &v1alpha1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Update(clusterRoleBinding *v1alpha1.ClusterRoleBinding) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolebindingsResource, clusterRoleBinding), &v1alpha1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolebindingsResource, name), &v1alpha1.ClusterRoleBinding{})
return err
}
func (c *FakeClusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolebindingsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ClusterRoleBindingList{})
return err
}
func (c *FakeClusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(clusterrolebindingsResource, name), &v1alpha1.ClusterRoleBinding{})
@ -101,6 +70,37 @@ func (c *FakeClusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, e
InvokesWatch(testing.NewRootWatchAction(clusterrolebindingsResource, opts))
}
func (c *FakeClusterRoleBindings) Create(clusterRoleBinding *v1alpha1.ClusterRoleBinding) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolebindingsResource, clusterRoleBinding), &v1alpha1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Update(clusterRoleBinding *v1alpha1.ClusterRoleBinding) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolebindingsResource, clusterRoleBinding), &v1alpha1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolebindingsResource, name), &v1alpha1.ClusterRoleBinding{})
return err
}
func (c *FakeClusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolebindingsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.ClusterRoleBindingList{})
return err
}
// Patch applies the patch and returns the patched clusterRoleBinding.
func (c *FakeClusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) {
obj, err := c.Fake.

View File

@ -36,40 +36,6 @@ var rolesResource = schema.GroupVersionResource{Group: "rbac.authorization.k8s.i
var rolesKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "Role"}
func (c *FakeRoles) Create(role *v1alpha1.Role) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolesResource, c.ns, role), &v1alpha1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.Role), err
}
func (c *FakeRoles) Update(role *v1alpha1.Role) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolesResource, c.ns, role), &v1alpha1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.Role), err
}
func (c *FakeRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolesResource, c.ns, name), &v1alpha1.Role{})
return err
}
func (c *FakeRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.RoleList{})
return err
}
func (c *FakeRoles) Get(name string, options v1.GetOptions) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(rolesResource, c.ns, name), &v1alpha1.Role{})
@ -108,6 +74,40 @@ func (c *FakeRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
}
func (c *FakeRoles) Create(role *v1alpha1.Role) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolesResource, c.ns, role), &v1alpha1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.Role), err
}
func (c *FakeRoles) Update(role *v1alpha1.Role) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolesResource, c.ns, role), &v1alpha1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.Role), err
}
func (c *FakeRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolesResource, c.ns, name), &v1alpha1.Role{})
return err
}
func (c *FakeRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.RoleList{})
return err
}
// Patch applies the patch and returns the patched role.
func (c *FakeRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) {
obj, err := c.Fake.

View File

@ -36,40 +36,6 @@ var rolebindingsResource = schema.GroupVersionResource{Group: "rbac.authorizatio
var rolebindingsKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1alpha1", Kind: "RoleBinding"}
func (c *FakeRoleBindings) Create(roleBinding *v1alpha1.RoleBinding) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolebindingsResource, c.ns, roleBinding), &v1alpha1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.RoleBinding), err
}
func (c *FakeRoleBindings) Update(roleBinding *v1alpha1.RoleBinding) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolebindingsResource, c.ns, roleBinding), &v1alpha1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.RoleBinding), err
}
func (c *FakeRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolebindingsResource, c.ns, name), &v1alpha1.RoleBinding{})
return err
}
func (c *FakeRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolebindingsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.RoleBindingList{})
return err
}
func (c *FakeRoleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(rolebindingsResource, c.ns, name), &v1alpha1.RoleBinding{})
@ -108,6 +74,40 @@ func (c *FakeRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
}
func (c *FakeRoleBindings) Create(roleBinding *v1alpha1.RoleBinding) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolebindingsResource, c.ns, roleBinding), &v1alpha1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.RoleBinding), err
}
func (c *FakeRoleBindings) Update(roleBinding *v1alpha1.RoleBinding) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolebindingsResource, c.ns, roleBinding), &v1alpha1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.RoleBinding), err
}
func (c *FakeRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolebindingsResource, c.ns, name), &v1alpha1.RoleBinding{})
return err
}
func (c *FakeRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolebindingsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.RoleBindingList{})
return err
}
// Patch applies the patch and returns the patched roleBinding.
func (c *FakeRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) {
obj, err := c.Fake.

View File

@ -58,6 +58,41 @@ func newRoles(c *RbacV1alpha1Client, namespace string) *roles {
}
}
// Get takes name of the role, and returns the corresponding role object, and an error if there is any.
func (c *roles) Get(name string, options v1.GetOptions) (result *v1alpha1.Role, err error) {
result = &v1alpha1.Role{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Roles that match those selectors.
func (c *roles) List(opts v1.ListOptions) (result *v1alpha1.RoleList, err error) {
result = &v1alpha1.RoleList{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roles.
func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a role and creates it. Returns the server's representation of the role, and an error, if there is any.
func (c *roles) Create(role *v1alpha1.Role) (result *v1alpha1.Role, err error) {
result = &v1alpha1.Role{}
@ -105,41 +140,6 @@ func (c *roles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListO
Error()
}
// Get takes name of the role, and returns the corresponding role object, and an error if there is any.
func (c *roles) Get(name string, options v1.GetOptions) (result *v1alpha1.Role, err error) {
result = &v1alpha1.Role{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Roles that match those selectors.
func (c *roles) List(opts v1.ListOptions) (result *v1alpha1.RoleList, err error) {
result = &v1alpha1.RoleList{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roles.
func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched role.
func (c *roles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) {
result = &v1alpha1.Role{}

View File

@ -58,6 +58,41 @@ func newRoleBindings(c *RbacV1alpha1Client, namespace string) *roleBindings {
}
}
// Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any.
func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.RoleBinding, err error) {
result = &v1alpha1.RoleBinding{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of RoleBindings that match those selectors.
func (c *roleBindings) List(opts v1.ListOptions) (result *v1alpha1.RoleBindingList, err error) {
result = &v1alpha1.RoleBindingList{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roleBindings.
func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a roleBinding and creates it. Returns the server's representation of the roleBinding, and an error, if there is any.
func (c *roleBindings) Create(roleBinding *v1alpha1.RoleBinding) (result *v1alpha1.RoleBinding, err error) {
result = &v1alpha1.RoleBinding{}
@ -105,41 +140,6 @@ func (c *roleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v
Error()
}
// Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any.
func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.RoleBinding, err error) {
result = &v1alpha1.RoleBinding{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of RoleBindings that match those selectors.
func (c *roleBindings) List(opts v1.ListOptions) (result *v1alpha1.RoleBindingList, err error) {
result = &v1alpha1.RoleBindingList{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roleBindings.
func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched roleBinding.
func (c *roleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) {
result = &v1alpha1.RoleBinding{}

View File

@ -56,6 +56,38 @@ func newClusterRoles(c *RbacV1beta1Client) *clusterRoles {
}
}
// Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any.
func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRole, err error) {
result = &v1beta1.ClusterRole{}
err = c.client.Get().
Resource("clusterroles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoles that match those selectors.
func (c *clusterRoles) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleList, err error) {
result = &v1beta1.ClusterRoleList{}
err = c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoles.
func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a clusterRole and creates it. Returns the server's representation of the clusterRole, and an error, if there is any.
func (c *clusterRoles) Create(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) {
result = &v1beta1.ClusterRole{}
@ -99,38 +131,6 @@ func (c *clusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v
Error()
}
// Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any.
func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRole, err error) {
result = &v1beta1.ClusterRole{}
err = c.client.Get().
Resource("clusterroles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoles that match those selectors.
func (c *clusterRoles) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleList, err error) {
result = &v1beta1.ClusterRoleList{}
err = c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoles.
func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterroles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched clusterRole.
func (c *clusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRole, err error) {
result = &v1beta1.ClusterRole{}

View File

@ -56,6 +56,38 @@ func newClusterRoleBindings(c *RbacV1beta1Client) *clusterRoleBindings {
}
}
// Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any.
func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRoleBinding, err error) {
result = &v1beta1.ClusterRoleBinding{}
err = c.client.Get().
Resource("clusterrolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoleBindings that match those selectors.
func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleBindingList, err error) {
result = &v1beta1.ClusterRoleBindingList{}
err = c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoleBindings.
func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a clusterRoleBinding and creates it. Returns the server's representation of the clusterRoleBinding, and an error, if there is any.
func (c *clusterRoleBindings) Create(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) {
result = &v1beta1.ClusterRoleBinding{}
@ -99,38 +131,6 @@ func (c *clusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOp
Error()
}
// Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any.
func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRoleBinding, err error) {
result = &v1beta1.ClusterRoleBinding{}
err = c.client.Get().
Resource("clusterrolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of ClusterRoleBindings that match those selectors.
func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleBindingList, err error) {
result = &v1beta1.ClusterRoleBindingList{}
err = c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested clusterRoleBindings.
func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("clusterrolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched clusterRoleBinding.
func (c *clusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRoleBinding, err error) {
result = &v1beta1.ClusterRoleBinding{}

View File

@ -35,37 +35,6 @@ var clusterrolesResource = schema.GroupVersionResource{Group: "rbac.authorizatio
var clusterrolesKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRole"}
func (c *FakeClusterRoles) Create(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolesResource, clusterRole), &v1beta1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRole), err
}
func (c *FakeClusterRoles) Update(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolesResource, clusterRole), &v1beta1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRole), err
}
func (c *FakeClusterRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolesResource, name), &v1beta1.ClusterRole{})
return err
}
func (c *FakeClusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ClusterRoleList{})
return err
}
func (c *FakeClusterRoles) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(clusterrolesResource, name), &v1beta1.ClusterRole{})
@ -101,6 +70,37 @@ func (c *FakeClusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
InvokesWatch(testing.NewRootWatchAction(clusterrolesResource, opts))
}
func (c *FakeClusterRoles) Create(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolesResource, clusterRole), &v1beta1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRole), err
}
func (c *FakeClusterRoles) Update(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolesResource, clusterRole), &v1beta1.ClusterRole{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRole), err
}
func (c *FakeClusterRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolesResource, name), &v1beta1.ClusterRole{})
return err
}
func (c *FakeClusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ClusterRoleList{})
return err
}
// Patch applies the patch and returns the patched clusterRole.
func (c *FakeClusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRole, err error) {
obj, err := c.Fake.

View File

@ -35,37 +35,6 @@ var clusterrolebindingsResource = schema.GroupVersionResource{Group: "rbac.autho
var clusterrolebindingsKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "ClusterRoleBinding"}
func (c *FakeClusterRoleBindings) Create(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolebindingsResource, clusterRoleBinding), &v1beta1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Update(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolebindingsResource, clusterRoleBinding), &v1beta1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolebindingsResource, name), &v1beta1.ClusterRoleBinding{})
return err
}
func (c *FakeClusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolebindingsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ClusterRoleBindingList{})
return err
}
func (c *FakeClusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(clusterrolebindingsResource, name), &v1beta1.ClusterRoleBinding{})
@ -101,6 +70,37 @@ func (c *FakeClusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, e
InvokesWatch(testing.NewRootWatchAction(clusterrolebindingsResource, opts))
}
func (c *FakeClusterRoleBindings) Create(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(clusterrolebindingsResource, clusterRoleBinding), &v1beta1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Update(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(clusterrolebindingsResource, clusterRoleBinding), &v1beta1.ClusterRoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.ClusterRoleBinding), err
}
func (c *FakeClusterRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(clusterrolebindingsResource, name), &v1beta1.ClusterRoleBinding{})
return err
}
func (c *FakeClusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(clusterrolebindingsResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.ClusterRoleBindingList{})
return err
}
// Patch applies the patch and returns the patched clusterRoleBinding.
func (c *FakeClusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRoleBinding, err error) {
obj, err := c.Fake.

View File

@ -36,40 +36,6 @@ var rolesResource = schema.GroupVersionResource{Group: "rbac.authorization.k8s.i
var rolesKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "Role"}
func (c *FakeRoles) Create(role *v1beta1.Role) (result *v1beta1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolesResource, c.ns, role), &v1beta1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Role), err
}
func (c *FakeRoles) Update(role *v1beta1.Role) (result *v1beta1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolesResource, c.ns, role), &v1beta1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Role), err
}
func (c *FakeRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolesResource, c.ns, name), &v1beta1.Role{})
return err
}
func (c *FakeRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.RoleList{})
return err
}
func (c *FakeRoles) Get(name string, options v1.GetOptions) (result *v1beta1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(rolesResource, c.ns, name), &v1beta1.Role{})
@ -108,6 +74,40 @@ func (c *FakeRoles) Watch(opts v1.ListOptions) (watch.Interface, error) {
}
func (c *FakeRoles) Create(role *v1beta1.Role) (result *v1beta1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolesResource, c.ns, role), &v1beta1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Role), err
}
func (c *FakeRoles) Update(role *v1beta1.Role) (result *v1beta1.Role, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolesResource, c.ns, role), &v1beta1.Role{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.Role), err
}
func (c *FakeRoles) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolesResource, c.ns, name), &v1beta1.Role{})
return err
}
func (c *FakeRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolesResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.RoleList{})
return err
}
// Patch applies the patch and returns the patched role.
func (c *FakeRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Role, err error) {
obj, err := c.Fake.

View File

@ -36,40 +36,6 @@ var rolebindingsResource = schema.GroupVersionResource{Group: "rbac.authorizatio
var rolebindingsKind = schema.GroupVersionKind{Group: "rbac.authorization.k8s.io", Version: "v1beta1", Kind: "RoleBinding"}
func (c *FakeRoleBindings) Create(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolebindingsResource, c.ns, roleBinding), &v1beta1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.RoleBinding), err
}
func (c *FakeRoleBindings) Update(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolebindingsResource, c.ns, roleBinding), &v1beta1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.RoleBinding), err
}
func (c *FakeRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolebindingsResource, c.ns, name), &v1beta1.RoleBinding{})
return err
}
func (c *FakeRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolebindingsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.RoleBindingList{})
return err
}
func (c *FakeRoleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(rolebindingsResource, c.ns, name), &v1beta1.RoleBinding{})
@ -108,6 +74,40 @@ func (c *FakeRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
}
func (c *FakeRoleBindings) Create(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(rolebindingsResource, c.ns, roleBinding), &v1beta1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.RoleBinding), err
}
func (c *FakeRoleBindings) Update(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(rolebindingsResource, c.ns, roleBinding), &v1beta1.RoleBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.RoleBinding), err
}
func (c *FakeRoleBindings) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(rolebindingsResource, c.ns, name), &v1beta1.RoleBinding{})
return err
}
func (c *FakeRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(rolebindingsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.RoleBindingList{})
return err
}
// Patch applies the patch and returns the patched roleBinding.
func (c *FakeRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.RoleBinding, err error) {
obj, err := c.Fake.

View File

@ -58,6 +58,41 @@ func newRoles(c *RbacV1beta1Client, namespace string) *roles {
}
}
// Get takes name of the role, and returns the corresponding role object, and an error if there is any.
func (c *roles) Get(name string, options v1.GetOptions) (result *v1beta1.Role, err error) {
result = &v1beta1.Role{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Roles that match those selectors.
func (c *roles) List(opts v1.ListOptions) (result *v1beta1.RoleList, err error) {
result = &v1beta1.RoleList{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roles.
func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a role and creates it. Returns the server's representation of the role, and an error, if there is any.
func (c *roles) Create(role *v1beta1.Role) (result *v1beta1.Role, err error) {
result = &v1beta1.Role{}
@ -105,41 +140,6 @@ func (c *roles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListO
Error()
}
// Get takes name of the role, and returns the corresponding role object, and an error if there is any.
func (c *roles) Get(name string, options v1.GetOptions) (result *v1beta1.Role, err error) {
result = &v1beta1.Role{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of Roles that match those selectors.
func (c *roles) List(opts v1.ListOptions) (result *v1beta1.RoleList, err error) {
result = &v1beta1.RoleList{}
err = c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roles.
func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("roles").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched role.
func (c *roles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Role, err error) {
result = &v1beta1.Role{}

View File

@ -58,6 +58,41 @@ func newRoleBindings(c *RbacV1beta1Client, namespace string) *roleBindings {
}
}
// Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any.
func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.RoleBinding, err error) {
result = &v1beta1.RoleBinding{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of RoleBindings that match those selectors.
func (c *roleBindings) List(opts v1.ListOptions) (result *v1beta1.RoleBindingList, err error) {
result = &v1beta1.RoleBindingList{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roleBindings.
func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a roleBinding and creates it. Returns the server's representation of the roleBinding, and an error, if there is any.
func (c *roleBindings) Create(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) {
result = &v1beta1.RoleBinding{}
@ -105,41 +140,6 @@ func (c *roleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v
Error()
}
// Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any.
func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.RoleBinding, err error) {
result = &v1beta1.RoleBinding{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of RoleBindings that match those selectors.
func (c *roleBindings) List(opts v1.ListOptions) (result *v1beta1.RoleBindingList, err error) {
result = &v1beta1.RoleBindingList{}
err = c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested roleBindings.
func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("rolebindings").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched roleBinding.
func (c *roleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.RoleBinding, err error) {
result = &v1beta1.RoleBinding{}

View File

@ -36,40 +36,6 @@ var podpresetsResource = schema.GroupVersionResource{Group: "settings.k8s.io", V
var podpresetsKind = schema.GroupVersionKind{Group: "settings.k8s.io", Version: "v1alpha1", Kind: "PodPreset"}
func (c *FakePodPresets) Create(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(podpresetsResource, c.ns, podPreset), &v1alpha1.PodPreset{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PodPreset), err
}
func (c *FakePodPresets) Update(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podpresetsResource, c.ns, podPreset), &v1alpha1.PodPreset{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PodPreset), err
}
func (c *FakePodPresets) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podpresetsResource, c.ns, name), &v1alpha1.PodPreset{})
return err
}
func (c *FakePodPresets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podpresetsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.PodPresetList{})
return err
}
func (c *FakePodPresets) Get(name string, options v1.GetOptions) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(podpresetsResource, c.ns, name), &v1alpha1.PodPreset{})
@ -108,6 +74,40 @@ func (c *FakePodPresets) Watch(opts v1.ListOptions) (watch.Interface, error) {
}
func (c *FakePodPresets) Create(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(podpresetsResource, c.ns, podPreset), &v1alpha1.PodPreset{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PodPreset), err
}
func (c *FakePodPresets) Update(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(podpresetsResource, c.ns, podPreset), &v1alpha1.PodPreset{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PodPreset), err
}
func (c *FakePodPresets) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(podpresetsResource, c.ns, name), &v1alpha1.PodPreset{})
return err
}
func (c *FakePodPresets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(podpresetsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1alpha1.PodPresetList{})
return err
}
// Patch applies the patch and returns the patched podPreset.
func (c *FakePodPresets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodPreset, err error) {
obj, err := c.Fake.

View File

@ -58,6 +58,41 @@ func newPodPresets(c *SettingsV1alpha1Client, namespace string) *podPresets {
}
}
// Get takes name of the podPreset, and returns the corresponding podPreset object, and an error if there is any.
func (c *podPresets) Get(name string, options v1.GetOptions) (result *v1alpha1.PodPreset, err error) {
result = &v1alpha1.PodPreset{}
err = c.client.Get().
Namespace(c.ns).
Resource("podpresets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodPresets that match those selectors.
func (c *podPresets) List(opts v1.ListOptions) (result *v1alpha1.PodPresetList, err error) {
result = &v1alpha1.PodPresetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("podpresets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podPresets.
func (c *podPresets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("podpresets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a podPreset and creates it. Returns the server's representation of the podPreset, and an error, if there is any.
func (c *podPresets) Create(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) {
result = &v1alpha1.PodPreset{}
@ -105,41 +140,6 @@ func (c *podPresets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.
Error()
}
// Get takes name of the podPreset, and returns the corresponding podPreset object, and an error if there is any.
func (c *podPresets) Get(name string, options v1.GetOptions) (result *v1alpha1.PodPreset, err error) {
result = &v1alpha1.PodPreset{}
err = c.client.Get().
Namespace(c.ns).
Resource("podpresets").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of PodPresets that match those selectors.
func (c *podPresets) List(opts v1.ListOptions) (result *v1alpha1.PodPresetList, err error) {
result = &v1alpha1.PodPresetList{}
err = c.client.Get().
Namespace(c.ns).
Resource("podpresets").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested podPresets.
func (c *podPresets) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("podpresets").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched podPreset.
func (c *podPresets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodPreset, err error) {
result = &v1alpha1.PodPreset{}

View File

@ -17,8 +17,8 @@ limitations under the License.
package fake
import (
v1 "k8s.io/api/storage/v1"
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
storage_v1 "k8s.io/api/storage/v1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
@ -35,49 +35,18 @@ var storageclassesResource = schema.GroupVersionResource{Group: "storage.k8s.io"
var storageclassesKind = schema.GroupVersionKind{Group: "storage.k8s.io", Version: "v1", Kind: "StorageClass"}
func (c *FakeStorageClasses) Create(storageClass *v1.StorageClass) (result *v1.StorageClass, err error) {
func (c *FakeStorageClasses) Get(name string, options v1.GetOptions) (result *storage_v1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(storageclassesResource, storageClass), &v1.StorageClass{})
Invokes(testing.NewRootGetAction(storageclassesResource, name), &storage_v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1.StorageClass), err
return obj.(*storage_v1.StorageClass), err
}
func (c *FakeStorageClasses) Update(storageClass *v1.StorageClass) (result *v1.StorageClass, err error) {
func (c *FakeStorageClasses) List(opts v1.ListOptions) (result *storage_v1.StorageClassList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(storageclassesResource, storageClass), &v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1.StorageClass), err
}
func (c *FakeStorageClasses) Delete(name string, options *meta_v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(storageclassesResource, name), &v1.StorageClass{})
return err
}
func (c *FakeStorageClasses) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(storageclassesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1.StorageClassList{})
return err
}
func (c *FakeStorageClasses) Get(name string, options meta_v1.GetOptions) (result *v1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(storageclassesResource, name), &v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1.StorageClass), err
}
func (c *FakeStorageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageClassList, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootListAction(storageclassesResource, storageclassesKind, opts), &v1.StorageClassList{})
Invokes(testing.NewRootListAction(storageclassesResource, storageclassesKind, opts), &storage_v1.StorageClassList{})
if obj == nil {
return nil, err
}
@ -86,8 +55,8 @@ func (c *FakeStorageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageC
if label == nil {
label = labels.Everything()
}
list := &v1.StorageClassList{}
for _, item := range obj.(*v1.StorageClassList).Items {
list := &storage_v1.StorageClassList{}
for _, item := range obj.(*storage_v1.StorageClassList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
@ -96,17 +65,48 @@ func (c *FakeStorageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageC
}
// Watch returns a watch.Interface that watches the requested storageClasses.
func (c *FakeStorageClasses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
func (c *FakeStorageClasses) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewRootWatchAction(storageclassesResource, opts))
}
// Patch applies the patch and returns the patched storageClass.
func (c *FakeStorageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.StorageClass, err error) {
func (c *FakeStorageClasses) Create(storageClass *storage_v1.StorageClass) (result *storage_v1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(storageclassesResource, name, data, subresources...), &v1.StorageClass{})
Invokes(testing.NewRootCreateAction(storageclassesResource, storageClass), &storage_v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1.StorageClass), err
return obj.(*storage_v1.StorageClass), err
}
func (c *FakeStorageClasses) Update(storageClass *storage_v1.StorageClass) (result *storage_v1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(storageclassesResource, storageClass), &storage_v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*storage_v1.StorageClass), err
}
func (c *FakeStorageClasses) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(storageclassesResource, name), &storage_v1.StorageClass{})
return err
}
func (c *FakeStorageClasses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(storageclassesResource, listOptions)
_, err := c.Fake.Invokes(action, &storage_v1.StorageClassList{})
return err
}
// Patch applies the patch and returns the patched storageClass.
func (c *FakeStorageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *storage_v1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootPatchSubresourceAction(storageclassesResource, name, data, subresources...), &storage_v1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*storage_v1.StorageClass), err
}

View File

@ -56,6 +56,38 @@ func newStorageClasses(c *StorageV1Client) *storageClasses {
}
}
// Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any.
func (c *storageClasses) Get(name string, options meta_v1.GetOptions) (result *v1.StorageClass, err error) {
result = &v1.StorageClass{}
err = c.client.Get().
Resource("storageclasses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StorageClasses that match those selectors.
func (c *storageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageClassList, err error) {
result = &v1.StorageClassList{}
err = c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested storageClasses.
func (c *storageClasses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a storageClass and creates it. Returns the server's representation of the storageClass, and an error, if there is any.
func (c *storageClasses) Create(storageClass *v1.StorageClass) (result *v1.StorageClass, err error) {
result = &v1.StorageClass{}
@ -99,38 +131,6 @@ func (c *storageClasses) DeleteCollection(options *meta_v1.DeleteOptions, listOp
Error()
}
// Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any.
func (c *storageClasses) Get(name string, options meta_v1.GetOptions) (result *v1.StorageClass, err error) {
result = &v1.StorageClass{}
err = c.client.Get().
Resource("storageclasses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StorageClasses that match those selectors.
func (c *storageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageClassList, err error) {
result = &v1.StorageClassList{}
err = c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested storageClasses.
func (c *storageClasses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched storageClass.
func (c *storageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.StorageClass, err error) {
result = &v1.StorageClass{}

View File

@ -35,37 +35,6 @@ var storageclassesResource = schema.GroupVersionResource{Group: "storage.k8s.io"
var storageclassesKind = schema.GroupVersionKind{Group: "storage.k8s.io", Version: "v1beta1", Kind: "StorageClass"}
func (c *FakeStorageClasses) Create(storageClass *v1beta1.StorageClass) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(storageclassesResource, storageClass), &v1beta1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StorageClass), err
}
func (c *FakeStorageClasses) Update(storageClass *v1beta1.StorageClass) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(storageclassesResource, storageClass), &v1beta1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StorageClass), err
}
func (c *FakeStorageClasses) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(storageclassesResource, name), &v1beta1.StorageClass{})
return err
}
func (c *FakeStorageClasses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(storageclassesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.StorageClassList{})
return err
}
func (c *FakeStorageClasses) Get(name string, options v1.GetOptions) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootGetAction(storageclassesResource, name), &v1beta1.StorageClass{})
@ -101,6 +70,37 @@ func (c *FakeStorageClasses) Watch(opts v1.ListOptions) (watch.Interface, error)
InvokesWatch(testing.NewRootWatchAction(storageclassesResource, opts))
}
func (c *FakeStorageClasses) Create(storageClass *v1beta1.StorageClass) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootCreateAction(storageclassesResource, storageClass), &v1beta1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StorageClass), err
}
func (c *FakeStorageClasses) Update(storageClass *v1beta1.StorageClass) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(testing.NewRootUpdateAction(storageclassesResource, storageClass), &v1beta1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StorageClass), err
}
func (c *FakeStorageClasses) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewRootDeleteAction(storageclassesResource, name), &v1beta1.StorageClass{})
return err
}
func (c *FakeStorageClasses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewRootDeleteCollectionAction(storageclassesResource, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.StorageClassList{})
return err
}
// Patch applies the patch and returns the patched storageClass.
func (c *FakeStorageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.

View File

@ -56,6 +56,38 @@ func newStorageClasses(c *StorageV1beta1Client) *storageClasses {
}
}
// Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any.
func (c *storageClasses) Get(name string, options v1.GetOptions) (result *v1beta1.StorageClass, err error) {
result = &v1beta1.StorageClass{}
err = c.client.Get().
Resource("storageclasses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StorageClasses that match those selectors.
func (c *storageClasses) List(opts v1.ListOptions) (result *v1beta1.StorageClassList, err error) {
result = &v1beta1.StorageClassList{}
err = c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested storageClasses.
func (c *storageClasses) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Create takes the representation of a storageClass and creates it. Returns the server's representation of the storageClass, and an error, if there is any.
func (c *storageClasses) Create(storageClass *v1beta1.StorageClass) (result *v1beta1.StorageClass, err error) {
result = &v1beta1.StorageClass{}
@ -99,38 +131,6 @@ func (c *storageClasses) DeleteCollection(options *v1.DeleteOptions, listOptions
Error()
}
// Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any.
func (c *storageClasses) Get(name string, options v1.GetOptions) (result *v1beta1.StorageClass, err error) {
result = &v1beta1.StorageClass{}
err = c.client.Get().
Resource("storageclasses").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of StorageClasses that match those selectors.
func (c *storageClasses) List(opts v1.ListOptions) (result *v1beta1.StorageClassList, err error) {
result = &v1beta1.StorageClassList{}
err = c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested storageClasses.
func (c *storageClasses) Watch(opts v1.ListOptions) (watch.Interface, error) {
opts.Watch = true
return c.client.Get().
Resource("storageclasses").
VersionedParams(&opts, scheme.ParameterCodec).
Watch()
}
// Patch applies the patch and returns the patched storageClass.
func (c *storageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) {
result = &v1beta1.StorageClass{}