mirror of
https://github.com/kubernetes/sample-controller.git
synced 2026-04-12 00:00:26 +08:00
Merge pull request #65645 from sttts/sttts-gengo-import-aliases
Automatic merge from submit-queue (batch tested with PRs 65582, 65480, 65310, 65644, 65645). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Bump gengo to remove _ from generated import aliases Pickup https://github.com/kubernetes/gengo/pull/113 and https://github.com/kubernetes/gengo/pull/111. Avoid tons of golint exceptions for https://github.com/kubernetes/kubernetes/pull/64664. Kubernetes-commit: a9be647e65c02c26528cec3cf912d06d12d374c2
This commit is contained in:
Generated
Vendored
+22
-22
@@ -25,7 +25,7 @@ import (
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
testing "k8s.io/client-go/testing"
|
||||
example_v1 "k8s.io/code-generator/_examples/apiserver/apis/example/v1"
|
||||
examplev1 "k8s.io/code-generator/_examples/apiserver/apis/example/v1"
|
||||
)
|
||||
|
||||
// FakeTestTypes implements TestTypeInterface
|
||||
@@ -39,20 +39,20 @@ var testtypesResource = schema.GroupVersionResource{Group: "example.apiserver.co
|
||||
var testtypesKind = schema.GroupVersionKind{Group: "example.apiserver.code-generator.k8s.io", Version: "v1", Kind: "TestType"}
|
||||
|
||||
// Get takes name of the testType, and returns the corresponding testType object, and an error if there is any.
|
||||
func (c *FakeTestTypes) Get(name string, options v1.GetOptions) (result *example_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Get(name string, options v1.GetOptions) (result *examplev1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(testtypesResource, c.ns, name), &example_v1.TestType{})
|
||||
Invokes(testing.NewGetAction(testtypesResource, c.ns, name), &examplev1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example_v1.TestType), err
|
||||
return obj.(*examplev1.TestType), err
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of TestTypes that match those selectors.
|
||||
func (c *FakeTestTypes) List(opts v1.ListOptions) (result *example_v1.TestTypeList, err error) {
|
||||
func (c *FakeTestTypes) List(opts v1.ListOptions) (result *examplev1.TestTypeList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(testtypesResource, testtypesKind, c.ns, opts), &example_v1.TestTypeList{})
|
||||
Invokes(testing.NewListAction(testtypesResource, testtypesKind, c.ns, opts), &examplev1.TestTypeList{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
@@ -62,8 +62,8 @@ func (c *FakeTestTypes) List(opts v1.ListOptions) (result *example_v1.TestTypeLi
|
||||
if label == nil {
|
||||
label = labels.Everything()
|
||||
}
|
||||
list := &example_v1.TestTypeList{ListMeta: obj.(*example_v1.TestTypeList).ListMeta}
|
||||
for _, item := range obj.(*example_v1.TestTypeList).Items {
|
||||
list := &examplev1.TestTypeList{ListMeta: obj.(*examplev1.TestTypeList).ListMeta}
|
||||
for _, item := range obj.(*examplev1.TestTypeList).Items {
|
||||
if label.Matches(labels.Set(item.Labels)) {
|
||||
list.Items = append(list.Items, item)
|
||||
}
|
||||
@@ -79,43 +79,43 @@ func (c *FakeTestTypes) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
}
|
||||
|
||||
// Create takes the representation of a testType and creates it. Returns the server's representation of the testType, and an error, if there is any.
|
||||
func (c *FakeTestTypes) Create(testType *example_v1.TestType) (result *example_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Create(testType *examplev1.TestType) (result *examplev1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(testtypesResource, c.ns, testType), &example_v1.TestType{})
|
||||
Invokes(testing.NewCreateAction(testtypesResource, c.ns, testType), &examplev1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example_v1.TestType), err
|
||||
return obj.(*examplev1.TestType), err
|
||||
}
|
||||
|
||||
// Update takes the representation of a testType and updates it. Returns the server's representation of the testType, and an error, if there is any.
|
||||
func (c *FakeTestTypes) Update(testType *example_v1.TestType) (result *example_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Update(testType *examplev1.TestType) (result *examplev1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(testtypesResource, c.ns, testType), &example_v1.TestType{})
|
||||
Invokes(testing.NewUpdateAction(testtypesResource, c.ns, testType), &examplev1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example_v1.TestType), err
|
||||
return obj.(*examplev1.TestType), err
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeTestTypes) UpdateStatus(testType *example_v1.TestType) (*example_v1.TestType, error) {
|
||||
func (c *FakeTestTypes) UpdateStatus(testType *examplev1.TestType) (*examplev1.TestType, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(testtypesResource, "status", c.ns, testType), &example_v1.TestType{})
|
||||
Invokes(testing.NewUpdateSubresourceAction(testtypesResource, "status", c.ns, testType), &examplev1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example_v1.TestType), err
|
||||
return obj.(*examplev1.TestType), err
|
||||
}
|
||||
|
||||
// Delete takes name of the testType and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeTestTypes) Delete(name string, options *v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(testtypesResource, c.ns, name), &example_v1.TestType{})
|
||||
Invokes(testing.NewDeleteAction(testtypesResource, c.ns, name), &examplev1.TestType{})
|
||||
|
||||
return err
|
||||
}
|
||||
@@ -124,17 +124,17 @@ func (c *FakeTestTypes) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeTestTypes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(testtypesResource, c.ns, listOptions)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &example_v1.TestTypeList{})
|
||||
_, err := c.Fake.Invokes(action, &examplev1.TestTypeList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched testType.
|
||||
func (c *FakeTestTypes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *example_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *examplev1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(testtypesResource, c.ns, name, data, subresources...), &example_v1.TestType{})
|
||||
Invokes(testing.NewPatchSubresourceAction(testtypesResource, c.ns, name, data, subresources...), &examplev1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example_v1.TestType), err
|
||||
return obj.(*examplev1.TestType), err
|
||||
}
|
||||
|
||||
Generated
Vendored
+11
-11
@@ -19,7 +19,7 @@ limitations under the License.
|
||||
package v1
|
||||
|
||||
import (
|
||||
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
rest "k8s.io/client-go/rest"
|
||||
@@ -38,11 +38,11 @@ type TestTypeInterface interface {
|
||||
Create(*v1.TestType) (*v1.TestType, error)
|
||||
Update(*v1.TestType) (*v1.TestType, error)
|
||||
UpdateStatus(*v1.TestType) (*v1.TestType, error)
|
||||
Delete(name string, options *meta_v1.DeleteOptions) error
|
||||
DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error
|
||||
Get(name string, options meta_v1.GetOptions) (*v1.TestType, error)
|
||||
List(opts meta_v1.ListOptions) (*v1.TestTypeList, error)
|
||||
Watch(opts meta_v1.ListOptions) (watch.Interface, error)
|
||||
Delete(name string, options *metav1.DeleteOptions) error
|
||||
DeleteCollection(options *metav1.DeleteOptions, listOptions metav1.ListOptions) error
|
||||
Get(name string, options metav1.GetOptions) (*v1.TestType, error)
|
||||
List(opts metav1.ListOptions) (*v1.TestTypeList, error)
|
||||
Watch(opts metav1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.TestType, err error)
|
||||
TestTypeExpansion
|
||||
}
|
||||
@@ -62,7 +62,7 @@ func newTestTypes(c *ExampleV1Client, namespace string) *testTypes {
|
||||
}
|
||||
|
||||
// Get takes name of the testType, and returns the corresponding testType object, and an error if there is any.
|
||||
func (c *testTypes) Get(name string, options meta_v1.GetOptions) (result *v1.TestType, err error) {
|
||||
func (c *testTypes) Get(name string, options metav1.GetOptions) (result *v1.TestType, err error) {
|
||||
result = &v1.TestType{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -75,7 +75,7 @@ func (c *testTypes) Get(name string, options meta_v1.GetOptions) (result *v1.Tes
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of TestTypes that match those selectors.
|
||||
func (c *testTypes) List(opts meta_v1.ListOptions) (result *v1.TestTypeList, err error) {
|
||||
func (c *testTypes) List(opts metav1.ListOptions) (result *v1.TestTypeList, err error) {
|
||||
result = &v1.TestTypeList{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -87,7 +87,7 @@ func (c *testTypes) List(opts meta_v1.ListOptions) (result *v1.TestTypeList, err
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested testTypes.
|
||||
func (c *testTypes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *testTypes) Watch(opts metav1.ListOptions) (watch.Interface, error) {
|
||||
opts.Watch = true
|
||||
return c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -138,7 +138,7 @@ func (c *testTypes) UpdateStatus(testType *v1.TestType) (result *v1.TestType, er
|
||||
}
|
||||
|
||||
// Delete takes name of the testType and deletes it. Returns an error if one occurs.
|
||||
func (c *testTypes) Delete(name string, options *meta_v1.DeleteOptions) error {
|
||||
func (c *testTypes) Delete(name string, options *metav1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("testtypes").
|
||||
@@ -149,7 +149,7 @@ func (c *testTypes) Delete(name string, options *meta_v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *testTypes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
|
||||
func (c *testTypes) DeleteCollection(options *metav1.DeleteOptions, listOptions metav1.ListOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("testtypes").
|
||||
|
||||
Generated
Vendored
+22
-22
@@ -25,7 +25,7 @@ import (
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
testing "k8s.io/client-go/testing"
|
||||
example2_v1 "k8s.io/code-generator/_examples/apiserver/apis/example2/v1"
|
||||
example2v1 "k8s.io/code-generator/_examples/apiserver/apis/example2/v1"
|
||||
)
|
||||
|
||||
// FakeTestTypes implements TestTypeInterface
|
||||
@@ -39,20 +39,20 @@ var testtypesResource = schema.GroupVersionResource{Group: "example.test.apiserv
|
||||
var testtypesKind = schema.GroupVersionKind{Group: "example.test.apiserver.code-generator.k8s.io", Version: "v1", Kind: "TestType"}
|
||||
|
||||
// Get takes name of the testType, and returns the corresponding testType object, and an error if there is any.
|
||||
func (c *FakeTestTypes) Get(name string, options v1.GetOptions) (result *example2_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Get(name string, options v1.GetOptions) (result *example2v1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewGetAction(testtypesResource, c.ns, name), &example2_v1.TestType{})
|
||||
Invokes(testing.NewGetAction(testtypesResource, c.ns, name), &example2v1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example2_v1.TestType), err
|
||||
return obj.(*example2v1.TestType), err
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of TestTypes that match those selectors.
|
||||
func (c *FakeTestTypes) List(opts v1.ListOptions) (result *example2_v1.TestTypeList, err error) {
|
||||
func (c *FakeTestTypes) List(opts v1.ListOptions) (result *example2v1.TestTypeList, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewListAction(testtypesResource, testtypesKind, c.ns, opts), &example2_v1.TestTypeList{})
|
||||
Invokes(testing.NewListAction(testtypesResource, testtypesKind, c.ns, opts), &example2v1.TestTypeList{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
@@ -62,8 +62,8 @@ func (c *FakeTestTypes) List(opts v1.ListOptions) (result *example2_v1.TestTypeL
|
||||
if label == nil {
|
||||
label = labels.Everything()
|
||||
}
|
||||
list := &example2_v1.TestTypeList{ListMeta: obj.(*example2_v1.TestTypeList).ListMeta}
|
||||
for _, item := range obj.(*example2_v1.TestTypeList).Items {
|
||||
list := &example2v1.TestTypeList{ListMeta: obj.(*example2v1.TestTypeList).ListMeta}
|
||||
for _, item := range obj.(*example2v1.TestTypeList).Items {
|
||||
if label.Matches(labels.Set(item.Labels)) {
|
||||
list.Items = append(list.Items, item)
|
||||
}
|
||||
@@ -79,43 +79,43 @@ func (c *FakeTestTypes) Watch(opts v1.ListOptions) (watch.Interface, error) {
|
||||
}
|
||||
|
||||
// Create takes the representation of a testType and creates it. Returns the server's representation of the testType, and an error, if there is any.
|
||||
func (c *FakeTestTypes) Create(testType *example2_v1.TestType) (result *example2_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Create(testType *example2v1.TestType) (result *example2v1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewCreateAction(testtypesResource, c.ns, testType), &example2_v1.TestType{})
|
||||
Invokes(testing.NewCreateAction(testtypesResource, c.ns, testType), &example2v1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example2_v1.TestType), err
|
||||
return obj.(*example2v1.TestType), err
|
||||
}
|
||||
|
||||
// Update takes the representation of a testType and updates it. Returns the server's representation of the testType, and an error, if there is any.
|
||||
func (c *FakeTestTypes) Update(testType *example2_v1.TestType) (result *example2_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Update(testType *example2v1.TestType) (result *example2v1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateAction(testtypesResource, c.ns, testType), &example2_v1.TestType{})
|
||||
Invokes(testing.NewUpdateAction(testtypesResource, c.ns, testType), &example2v1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example2_v1.TestType), err
|
||||
return obj.(*example2v1.TestType), err
|
||||
}
|
||||
|
||||
// UpdateStatus was generated because the type contains a Status member.
|
||||
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||
func (c *FakeTestTypes) UpdateStatus(testType *example2_v1.TestType) (*example2_v1.TestType, error) {
|
||||
func (c *FakeTestTypes) UpdateStatus(testType *example2v1.TestType) (*example2v1.TestType, error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewUpdateSubresourceAction(testtypesResource, "status", c.ns, testType), &example2_v1.TestType{})
|
||||
Invokes(testing.NewUpdateSubresourceAction(testtypesResource, "status", c.ns, testType), &example2v1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example2_v1.TestType), err
|
||||
return obj.(*example2v1.TestType), err
|
||||
}
|
||||
|
||||
// Delete takes name of the testType and deletes it. Returns an error if one occurs.
|
||||
func (c *FakeTestTypes) Delete(name string, options *v1.DeleteOptions) error {
|
||||
_, err := c.Fake.
|
||||
Invokes(testing.NewDeleteAction(testtypesResource, c.ns, name), &example2_v1.TestType{})
|
||||
Invokes(testing.NewDeleteAction(testtypesResource, c.ns, name), &example2v1.TestType{})
|
||||
|
||||
return err
|
||||
}
|
||||
@@ -124,17 +124,17 @@ func (c *FakeTestTypes) Delete(name string, options *v1.DeleteOptions) error {
|
||||
func (c *FakeTestTypes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
action := testing.NewDeleteCollectionAction(testtypesResource, c.ns, listOptions)
|
||||
|
||||
_, err := c.Fake.Invokes(action, &example2_v1.TestTypeList{})
|
||||
_, err := c.Fake.Invokes(action, &example2v1.TestTypeList{})
|
||||
return err
|
||||
}
|
||||
|
||||
// Patch applies the patch and returns the patched testType.
|
||||
func (c *FakeTestTypes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *example2_v1.TestType, err error) {
|
||||
func (c *FakeTestTypes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *example2v1.TestType, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewPatchSubresourceAction(testtypesResource, c.ns, name, data, subresources...), &example2_v1.TestType{})
|
||||
Invokes(testing.NewPatchSubresourceAction(testtypesResource, c.ns, name, data, subresources...), &example2v1.TestType{})
|
||||
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
return obj.(*example2_v1.TestType), err
|
||||
return obj.(*example2v1.TestType), err
|
||||
}
|
||||
|
||||
Generated
Vendored
+11
-11
@@ -19,7 +19,7 @@ limitations under the License.
|
||||
package v1
|
||||
|
||||
import (
|
||||
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
rest "k8s.io/client-go/rest"
|
||||
@@ -38,11 +38,11 @@ type TestTypeInterface interface {
|
||||
Create(*v1.TestType) (*v1.TestType, error)
|
||||
Update(*v1.TestType) (*v1.TestType, error)
|
||||
UpdateStatus(*v1.TestType) (*v1.TestType, error)
|
||||
Delete(name string, options *meta_v1.DeleteOptions) error
|
||||
DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error
|
||||
Get(name string, options meta_v1.GetOptions) (*v1.TestType, error)
|
||||
List(opts meta_v1.ListOptions) (*v1.TestTypeList, error)
|
||||
Watch(opts meta_v1.ListOptions) (watch.Interface, error)
|
||||
Delete(name string, options *metav1.DeleteOptions) error
|
||||
DeleteCollection(options *metav1.DeleteOptions, listOptions metav1.ListOptions) error
|
||||
Get(name string, options metav1.GetOptions) (*v1.TestType, error)
|
||||
List(opts metav1.ListOptions) (*v1.TestTypeList, error)
|
||||
Watch(opts metav1.ListOptions) (watch.Interface, error)
|
||||
Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.TestType, err error)
|
||||
TestTypeExpansion
|
||||
}
|
||||
@@ -62,7 +62,7 @@ func newTestTypes(c *SecondExampleV1Client, namespace string) *testTypes {
|
||||
}
|
||||
|
||||
// Get takes name of the testType, and returns the corresponding testType object, and an error if there is any.
|
||||
func (c *testTypes) Get(name string, options meta_v1.GetOptions) (result *v1.TestType, err error) {
|
||||
func (c *testTypes) Get(name string, options metav1.GetOptions) (result *v1.TestType, err error) {
|
||||
result = &v1.TestType{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -75,7 +75,7 @@ func (c *testTypes) Get(name string, options meta_v1.GetOptions) (result *v1.Tes
|
||||
}
|
||||
|
||||
// List takes label and field selectors, and returns the list of TestTypes that match those selectors.
|
||||
func (c *testTypes) List(opts meta_v1.ListOptions) (result *v1.TestTypeList, err error) {
|
||||
func (c *testTypes) List(opts metav1.ListOptions) (result *v1.TestTypeList, err error) {
|
||||
result = &v1.TestTypeList{}
|
||||
err = c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -87,7 +87,7 @@ func (c *testTypes) List(opts meta_v1.ListOptions) (result *v1.TestTypeList, err
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested testTypes.
|
||||
func (c *testTypes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) {
|
||||
func (c *testTypes) Watch(opts metav1.ListOptions) (watch.Interface, error) {
|
||||
opts.Watch = true
|
||||
return c.client.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -138,7 +138,7 @@ func (c *testTypes) UpdateStatus(testType *v1.TestType) (result *v1.TestType, er
|
||||
}
|
||||
|
||||
// Delete takes name of the testType and deletes it. Returns an error if one occurs.
|
||||
func (c *testTypes) Delete(name string, options *meta_v1.DeleteOptions) error {
|
||||
func (c *testTypes) Delete(name string, options *metav1.DeleteOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("testtypes").
|
||||
@@ -149,7 +149,7 @@ func (c *testTypes) Delete(name string, options *meta_v1.DeleteOptions) error {
|
||||
}
|
||||
|
||||
// DeleteCollection deletes a collection of objects.
|
||||
func (c *testTypes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error {
|
||||
func (c *testTypes) DeleteCollection(options *metav1.DeleteOptions, listOptions metav1.ListOptions) error {
|
||||
return c.client.Delete().
|
||||
Namespace(c.ns).
|
||||
Resource("testtypes").
|
||||
|
||||
Reference in New Issue
Block a user