/
appliedclusterresourcequota.go
62 lines (54 loc) · 2.31 KB
/
appliedclusterresourcequota.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// Code generated by client-gen. DO NOT EDIT.
package internalversion
import (
quota "github.com/openshift/origin/pkg/quota/apis/quota"
scheme "github.com/openshift/origin/pkg/quota/generated/internalclientset/scheme"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
rest "k8s.io/client-go/rest"
)
// AppliedClusterResourceQuotasGetter has a method to return a AppliedClusterResourceQuotaInterface.
// A group's client should implement this interface.
type AppliedClusterResourceQuotasGetter interface {
AppliedClusterResourceQuotas(namespace string) AppliedClusterResourceQuotaInterface
}
// AppliedClusterResourceQuotaInterface has methods to work with AppliedClusterResourceQuota resources.
type AppliedClusterResourceQuotaInterface interface {
Get(name string, options v1.GetOptions) (*quota.AppliedClusterResourceQuota, error)
List(opts v1.ListOptions) (*quota.AppliedClusterResourceQuotaList, error)
AppliedClusterResourceQuotaExpansion
}
// appliedClusterResourceQuotas implements AppliedClusterResourceQuotaInterface
type appliedClusterResourceQuotas struct {
client rest.Interface
ns string
}
// newAppliedClusterResourceQuotas returns a AppliedClusterResourceQuotas
func newAppliedClusterResourceQuotas(c *QuotaClient, namespace string) *appliedClusterResourceQuotas {
return &appliedClusterResourceQuotas{
client: c.RESTClient(),
ns: namespace,
}
}
// Get takes name of the appliedClusterResourceQuota, and returns the corresponding appliedClusterResourceQuota object, and an error if there is any.
func (c *appliedClusterResourceQuotas) Get(name string, options v1.GetOptions) (result *quota.AppliedClusterResourceQuota, err error) {
result = "a.AppliedClusterResourceQuota{}
err = c.client.Get().
Namespace(c.ns).
Resource("appliedclusterresourcequotas").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do().
Into(result)
return
}
// List takes label and field selectors, and returns the list of AppliedClusterResourceQuotas that match those selectors.
func (c *appliedClusterResourceQuotas) List(opts v1.ListOptions) (result *quota.AppliedClusterResourceQuotaList, err error) {
result = "a.AppliedClusterResourceQuotaList{}
err = c.client.Get().
Namespace(c.ns).
Resource("appliedclusterresourcequotas").
VersionedParams(&opts, scheme.ParameterCodec).
Do().
Into(result)
return
}