Remove BPA from Makefile
[icn.git] / cmd / bpa-operator / vendor / k8s.io / client-go / kubernetes / typed / admissionregistration / v1beta1 / admissionregistration_client.go
1 /*
2 Copyright The Kubernetes Authors.
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8     http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15 */
16
17 // Code generated by client-gen. DO NOT EDIT.
18
19 package v1beta1
20
21 import (
22         v1beta1 "k8s.io/api/admissionregistration/v1beta1"
23         serializer "k8s.io/apimachinery/pkg/runtime/serializer"
24         "k8s.io/client-go/kubernetes/scheme"
25         rest "k8s.io/client-go/rest"
26 )
27
28 type AdmissionregistrationV1beta1Interface interface {
29         RESTClient() rest.Interface
30         MutatingWebhookConfigurationsGetter
31         ValidatingWebhookConfigurationsGetter
32 }
33
34 // AdmissionregistrationV1beta1Client is used to interact with features provided by the admissionregistration.k8s.io group.
35 type AdmissionregistrationV1beta1Client struct {
36         restClient rest.Interface
37 }
38
39 func (c *AdmissionregistrationV1beta1Client) MutatingWebhookConfigurations() MutatingWebhookConfigurationInterface {
40         return newMutatingWebhookConfigurations(c)
41 }
42
43 func (c *AdmissionregistrationV1beta1Client) ValidatingWebhookConfigurations() ValidatingWebhookConfigurationInterface {
44         return newValidatingWebhookConfigurations(c)
45 }
46
47 // NewForConfig creates a new AdmissionregistrationV1beta1Client for the given config.
48 func NewForConfig(c *rest.Config) (*AdmissionregistrationV1beta1Client, error) {
49         config := *c
50         if err := setConfigDefaults(&config); err != nil {
51                 return nil, err
52         }
53         client, err := rest.RESTClientFor(&config)
54         if err != nil {
55                 return nil, err
56         }
57         return &AdmissionregistrationV1beta1Client{client}, nil
58 }
59
60 // NewForConfigOrDie creates a new AdmissionregistrationV1beta1Client for the given config and
61 // panics if there is an error in the config.
62 func NewForConfigOrDie(c *rest.Config) *AdmissionregistrationV1beta1Client {
63         client, err := NewForConfig(c)
64         if err != nil {
65                 panic(err)
66         }
67         return client
68 }
69
70 // New creates a new AdmissionregistrationV1beta1Client for the given RESTClient.
71 func New(c rest.Interface) *AdmissionregistrationV1beta1Client {
72         return &AdmissionregistrationV1beta1Client{c}
73 }
74
75 func setConfigDefaults(config *rest.Config) error {
76         gv := v1beta1.SchemeGroupVersion
77         config.GroupVersion = &gv
78         config.APIPath = "/apis"
79         config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs}
80
81         if config.UserAgent == "" {
82                 config.UserAgent = rest.DefaultKubernetesUserAgent()
83         }
84
85         return nil
86 }
87
88 // RESTClient returns a RESTClient that is used to communicate
89 // with API server by this client implementation.
90 func (c *AdmissionregistrationV1beta1Client) RESTClient() rest.Interface {
91         if c == nil {
92                 return nil
93         }
94         return c.restClient
95 }