mirror of
https://github.com/kubernetes/client-go.git
synced 2025-06-23 13:47:19 +00:00
Run make update
Kubernetes-commit: e761be47a45b97574499069ea198d879e7050e51
This commit is contained in:
parent
e359642e7c
commit
dba34c781e
@ -12628,7 +12628,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
map:
|
map:
|
||||||
elementType:
|
elementType:
|
||||||
namedType: io.k8s.apimachinery.pkg.api.resource.Quantity
|
namedType: io.k8s.apimachinery.pkg.api.resource.Quantity
|
||||||
- name: consumesCounter
|
- name: consumesCounters
|
||||||
type:
|
type:
|
||||||
list:
|
list:
|
||||||
elementType:
|
elementType:
|
||||||
@ -12813,15 +12813,15 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
- name: io.k8s.api.resource.v1alpha3.DeviceCounterConsumption
|
- name: io.k8s.api.resource.v1alpha3.DeviceCounterConsumption
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
|
- name: counterSet
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
- name: counters
|
- name: counters
|
||||||
type:
|
type:
|
||||||
map:
|
map:
|
||||||
elementType:
|
elementType:
|
||||||
namedType: io.k8s.api.resource.v1alpha3.Counter
|
namedType: io.k8s.api.resource.v1alpha3.Counter
|
||||||
- name: sharedCounter
|
|
||||||
type:
|
|
||||||
scalar: string
|
|
||||||
default: ""
|
|
||||||
- name: io.k8s.api.resource.v1alpha3.DeviceRequest
|
- name: io.k8s.api.resource.v1alpha3.DeviceRequest
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
@ -13252,7 +13252,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
map:
|
map:
|
||||||
elementType:
|
elementType:
|
||||||
namedType: io.k8s.api.resource.v1beta1.DeviceCapacity
|
namedType: io.k8s.api.resource.v1beta1.DeviceCapacity
|
||||||
- name: consumesCounter
|
- name: consumesCounters
|
||||||
type:
|
type:
|
||||||
list:
|
list:
|
||||||
elementType:
|
elementType:
|
||||||
@ -13443,15 +13443,15 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
- name: io.k8s.api.resource.v1beta1.DeviceCounterConsumption
|
- name: io.k8s.api.resource.v1beta1.DeviceCounterConsumption
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
|
- name: counterSet
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
- name: counters
|
- name: counters
|
||||||
type:
|
type:
|
||||||
map:
|
map:
|
||||||
elementType:
|
elementType:
|
||||||
namedType: io.k8s.api.resource.v1beta1.Counter
|
namedType: io.k8s.api.resource.v1beta1.Counter
|
||||||
- name: sharedCounter
|
|
||||||
type:
|
|
||||||
scalar: string
|
|
||||||
default: ""
|
|
||||||
- name: io.k8s.api.resource.v1beta1.DeviceRequest
|
- name: io.k8s.api.resource.v1beta1.DeviceRequest
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
@ -13779,6 +13779,588 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
elementType:
|
elementType:
|
||||||
namedType: io.k8s.api.resource.v1beta1.CounterSet
|
namedType: io.k8s.api.resource.v1beta1.CounterSet
|
||||||
elementRelationship: atomic
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.AllocatedDeviceStatus
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: conditions
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
|
||||||
|
elementRelationship: associative
|
||||||
|
keys:
|
||||||
|
- type
|
||||||
|
- name: data
|
||||||
|
type:
|
||||||
|
namedType: __untyped_atomic_
|
||||||
|
- name: device
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: driver
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: networkData
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.NetworkDeviceData
|
||||||
|
- name: pool
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.AllocationResult
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: devices
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceAllocationResult
|
||||||
|
default: {}
|
||||||
|
- name: nodeSelector
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.core.v1.NodeSelector
|
||||||
|
- name: io.k8s.api.resource.v1beta2.CELDeviceSelector
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: expression
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.Counter
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: value
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.api.resource.Quantity
|
||||||
|
- name: io.k8s.api.resource.v1beta2.CounterSet
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: counters
|
||||||
|
type:
|
||||||
|
map:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.Counter
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.Device
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: allNodes
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: attributes
|
||||||
|
type:
|
||||||
|
map:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceAttribute
|
||||||
|
- name: capacity
|
||||||
|
type:
|
||||||
|
map:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceCapacity
|
||||||
|
- name: consumesCounters
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceCounterConsumption
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: nodeName
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: nodeSelector
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.core.v1.NodeSelector
|
||||||
|
- name: taints
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceTaint
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceAllocationConfiguration
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: opaque
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.OpaqueDeviceConfiguration
|
||||||
|
- name: requests
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
scalar: string
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: source
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceAllocationResult
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: config
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceAllocationConfiguration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: results
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceRequestAllocationResult
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceAttribute
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: bool
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: int
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
- name: string
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: version
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceCapacity
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: value
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.api.resource.Quantity
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceClaim
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: config
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceClaimConfiguration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: constraints
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceConstraint
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: requests
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceRequest
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceClaimConfiguration
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: opaque
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.OpaqueDeviceConfiguration
|
||||||
|
- name: requests
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
scalar: string
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceClass
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: apiVersion
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: kind
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: metadata
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||||
|
default: {}
|
||||||
|
- name: spec
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceClassSpec
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceClassConfiguration
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: opaque
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.OpaqueDeviceConfiguration
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceClassSpec
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: config
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceClassConfiguration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: selectors
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceSelector
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceConstraint
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: matchAttribute
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: requests
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
scalar: string
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceCounterConsumption
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: counterSet
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: counters
|
||||||
|
type:
|
||||||
|
map:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.Counter
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceRequest
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: exactly
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ExactDeviceRequest
|
||||||
|
- name: firstAvailable
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceSubRequest
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceRequestAllocationResult
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: adminAccess
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: device
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: driver
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: pool
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: request
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: tolerations
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceToleration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceSelector
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: cel
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.CELDeviceSelector
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceSubRequest
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: allocationMode
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: count
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
- name: deviceClassName
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: selectors
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceSelector
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: tolerations
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceToleration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceTaint
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: effect
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: key
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: timeAdded
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Time
|
||||||
|
- name: value
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: io.k8s.api.resource.v1beta2.DeviceToleration
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: effect
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: key
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: operator
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: Equal
|
||||||
|
- name: tolerationSeconds
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
- name: value
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ExactDeviceRequest
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: adminAccess
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: allocationMode
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: count
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
- name: deviceClassName
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: selectors
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceSelector
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: tolerations
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceToleration
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.NetworkDeviceData
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: hardwareAddress
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: interfaceName
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: ips
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
scalar: string
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: io.k8s.api.resource.v1beta2.OpaqueDeviceConfiguration
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: driver
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: parameters
|
||||||
|
type:
|
||||||
|
namedType: __untyped_atomic_
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaim
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: apiVersion
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: kind
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: metadata
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||||
|
default: {}
|
||||||
|
- name: spec
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceClaimSpec
|
||||||
|
default: {}
|
||||||
|
- name: status
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceClaimStatus
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaimConsumerReference
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: apiGroup
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: resource
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: uid
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaimSpec
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: devices
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.DeviceClaim
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaimStatus
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: allocation
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.AllocationResult
|
||||||
|
- name: devices
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.AllocatedDeviceStatus
|
||||||
|
elementRelationship: associative
|
||||||
|
keys:
|
||||||
|
- driver
|
||||||
|
- device
|
||||||
|
- pool
|
||||||
|
- name: reservedFor
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceClaimConsumerReference
|
||||||
|
elementRelationship: associative
|
||||||
|
keys:
|
||||||
|
- uid
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaimTemplate
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: apiVersion
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: kind
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: metadata
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||||
|
default: {}
|
||||||
|
- name: spec
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceClaimTemplateSpec
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceClaimTemplateSpec
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: metadata
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||||
|
default: {}
|
||||||
|
- name: spec
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceClaimSpec
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourcePool
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: generation
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
default: 0
|
||||||
|
- name: name
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: resourceSliceCount
|
||||||
|
type:
|
||||||
|
scalar: numeric
|
||||||
|
default: 0
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceSlice
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: apiVersion
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: kind
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: metadata
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||||
|
default: {}
|
||||||
|
- name: spec
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourceSliceSpec
|
||||||
|
default: {}
|
||||||
|
- name: io.k8s.api.resource.v1beta2.ResourceSliceSpec
|
||||||
|
map:
|
||||||
|
fields:
|
||||||
|
- name: allNodes
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: devices
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.Device
|
||||||
|
elementRelationship: atomic
|
||||||
|
- name: driver
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
default: ""
|
||||||
|
- name: nodeName
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
|
- name: nodeSelector
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.core.v1.NodeSelector
|
||||||
|
- name: perDeviceNodeSelection
|
||||||
|
type:
|
||||||
|
scalar: boolean
|
||||||
|
- name: pool
|
||||||
|
type:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.ResourcePool
|
||||||
|
default: {}
|
||||||
|
- name: sharedCounters
|
||||||
|
type:
|
||||||
|
list:
|
||||||
|
elementType:
|
||||||
|
namedType: io.k8s.api.resource.v1beta2.CounterSet
|
||||||
|
elementRelationship: atomic
|
||||||
- name: io.k8s.api.scheduling.v1.PriorityClass
|
- name: io.k8s.api.scheduling.v1.PriorityClass
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
|
@ -27,13 +27,13 @@ import (
|
|||||||
// BasicDeviceApplyConfiguration represents a declarative configuration of the BasicDevice type for use
|
// BasicDeviceApplyConfiguration represents a declarative configuration of the BasicDevice type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type BasicDeviceApplyConfiguration struct {
|
type BasicDeviceApplyConfiguration struct {
|
||||||
Attributes map[resourcev1alpha3.QualifiedName]DeviceAttributeApplyConfiguration `json:"attributes,omitempty"`
|
Attributes map[resourcev1alpha3.QualifiedName]DeviceAttributeApplyConfiguration `json:"attributes,omitempty"`
|
||||||
Capacity map[resourcev1alpha3.QualifiedName]resource.Quantity `json:"capacity,omitempty"`
|
Capacity map[resourcev1alpha3.QualifiedName]resource.Quantity `json:"capacity,omitempty"`
|
||||||
ConsumesCounter []DeviceCounterConsumptionApplyConfiguration `json:"consumesCounter,omitempty"`
|
ConsumesCounters []DeviceCounterConsumptionApplyConfiguration `json:"consumesCounters,omitempty"`
|
||||||
NodeName *string `json:"nodeName,omitempty"`
|
NodeName *string `json:"nodeName,omitempty"`
|
||||||
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
||||||
AllNodes *bool `json:"allNodes,omitempty"`
|
AllNodes *bool `json:"allNodes,omitempty"`
|
||||||
Taints []DeviceTaintApplyConfiguration `json:"taints,omitempty"`
|
Taints []DeviceTaintApplyConfiguration `json:"taints,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// BasicDeviceApplyConfiguration constructs a declarative configuration of the BasicDevice type for use with
|
// BasicDeviceApplyConfiguration constructs a declarative configuration of the BasicDevice type for use with
|
||||||
@ -70,15 +70,15 @@ func (b *BasicDeviceApplyConfiguration) WithCapacity(entries map[resourcev1alpha
|
|||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithConsumesCounter adds the given value to the ConsumesCounter field in the declarative configuration
|
// WithConsumesCounters adds the given value to the ConsumesCounters field in the declarative configuration
|
||||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
// If called multiple times, values provided by each call will be appended to the ConsumesCounter field.
|
// If called multiple times, values provided by each call will be appended to the ConsumesCounters field.
|
||||||
func (b *BasicDeviceApplyConfiguration) WithConsumesCounter(values ...*DeviceCounterConsumptionApplyConfiguration) *BasicDeviceApplyConfiguration {
|
func (b *BasicDeviceApplyConfiguration) WithConsumesCounters(values ...*DeviceCounterConsumptionApplyConfiguration) *BasicDeviceApplyConfiguration {
|
||||||
for i := range values {
|
for i := range values {
|
||||||
if values[i] == nil {
|
if values[i] == nil {
|
||||||
panic("nil value passed to WithConsumesCounter")
|
panic("nil value passed to WithConsumesCounters")
|
||||||
}
|
}
|
||||||
b.ConsumesCounter = append(b.ConsumesCounter, *values[i])
|
b.ConsumesCounters = append(b.ConsumesCounters, *values[i])
|
||||||
}
|
}
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
@ -21,8 +21,8 @@ package v1alpha3
|
|||||||
// DeviceCounterConsumptionApplyConfiguration represents a declarative configuration of the DeviceCounterConsumption type for use
|
// DeviceCounterConsumptionApplyConfiguration represents a declarative configuration of the DeviceCounterConsumption type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type DeviceCounterConsumptionApplyConfiguration struct {
|
type DeviceCounterConsumptionApplyConfiguration struct {
|
||||||
SharedCounter *string `json:"sharedCounter,omitempty"`
|
CounterSet *string `json:"counterSet,omitempty"`
|
||||||
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeviceCounterConsumptionApplyConfiguration constructs a declarative configuration of the DeviceCounterConsumption type for use with
|
// DeviceCounterConsumptionApplyConfiguration constructs a declarative configuration of the DeviceCounterConsumption type for use with
|
||||||
@ -31,11 +31,11 @@ func DeviceCounterConsumption() *DeviceCounterConsumptionApplyConfiguration {
|
|||||||
return &DeviceCounterConsumptionApplyConfiguration{}
|
return &DeviceCounterConsumptionApplyConfiguration{}
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithSharedCounter sets the SharedCounter field in the declarative configuration to the given value
|
// WithCounterSet sets the CounterSet field in the declarative configuration to the given value
|
||||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
// If called multiple times, the SharedCounter field is set to the value of the last call.
|
// If called multiple times, the CounterSet field is set to the value of the last call.
|
||||||
func (b *DeviceCounterConsumptionApplyConfiguration) WithSharedCounter(value string) *DeviceCounterConsumptionApplyConfiguration {
|
func (b *DeviceCounterConsumptionApplyConfiguration) WithCounterSet(value string) *DeviceCounterConsumptionApplyConfiguration {
|
||||||
b.SharedCounter = &value
|
b.CounterSet = &value
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -26,13 +26,13 @@ import (
|
|||||||
// BasicDeviceApplyConfiguration represents a declarative configuration of the BasicDevice type for use
|
// BasicDeviceApplyConfiguration represents a declarative configuration of the BasicDevice type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type BasicDeviceApplyConfiguration struct {
|
type BasicDeviceApplyConfiguration struct {
|
||||||
Attributes map[resourcev1beta1.QualifiedName]DeviceAttributeApplyConfiguration `json:"attributes,omitempty"`
|
Attributes map[resourcev1beta1.QualifiedName]DeviceAttributeApplyConfiguration `json:"attributes,omitempty"`
|
||||||
Capacity map[resourcev1beta1.QualifiedName]DeviceCapacityApplyConfiguration `json:"capacity,omitempty"`
|
Capacity map[resourcev1beta1.QualifiedName]DeviceCapacityApplyConfiguration `json:"capacity,omitempty"`
|
||||||
ConsumesCounter []DeviceCounterConsumptionApplyConfiguration `json:"consumesCounter,omitempty"`
|
ConsumesCounters []DeviceCounterConsumptionApplyConfiguration `json:"consumesCounters,omitempty"`
|
||||||
NodeName *string `json:"nodeName,omitempty"`
|
NodeName *string `json:"nodeName,omitempty"`
|
||||||
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
||||||
AllNodes *bool `json:"allNodes,omitempty"`
|
AllNodes *bool `json:"allNodes,omitempty"`
|
||||||
Taints []DeviceTaintApplyConfiguration `json:"taints,omitempty"`
|
Taints []DeviceTaintApplyConfiguration `json:"taints,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// BasicDeviceApplyConfiguration constructs a declarative configuration of the BasicDevice type for use with
|
// BasicDeviceApplyConfiguration constructs a declarative configuration of the BasicDevice type for use with
|
||||||
@ -69,15 +69,15 @@ func (b *BasicDeviceApplyConfiguration) WithCapacity(entries map[resourcev1beta1
|
|||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithConsumesCounter adds the given value to the ConsumesCounter field in the declarative configuration
|
// WithConsumesCounters adds the given value to the ConsumesCounters field in the declarative configuration
|
||||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
// If called multiple times, values provided by each call will be appended to the ConsumesCounter field.
|
// If called multiple times, values provided by each call will be appended to the ConsumesCounters field.
|
||||||
func (b *BasicDeviceApplyConfiguration) WithConsumesCounter(values ...*DeviceCounterConsumptionApplyConfiguration) *BasicDeviceApplyConfiguration {
|
func (b *BasicDeviceApplyConfiguration) WithConsumesCounters(values ...*DeviceCounterConsumptionApplyConfiguration) *BasicDeviceApplyConfiguration {
|
||||||
for i := range values {
|
for i := range values {
|
||||||
if values[i] == nil {
|
if values[i] == nil {
|
||||||
panic("nil value passed to WithConsumesCounter")
|
panic("nil value passed to WithConsumesCounters")
|
||||||
}
|
}
|
||||||
b.ConsumesCounter = append(b.ConsumesCounter, *values[i])
|
b.ConsumesCounters = append(b.ConsumesCounters, *values[i])
|
||||||
}
|
}
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
@ -21,8 +21,8 @@ package v1beta1
|
|||||||
// DeviceCounterConsumptionApplyConfiguration represents a declarative configuration of the DeviceCounterConsumption type for use
|
// DeviceCounterConsumptionApplyConfiguration represents a declarative configuration of the DeviceCounterConsumption type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type DeviceCounterConsumptionApplyConfiguration struct {
|
type DeviceCounterConsumptionApplyConfiguration struct {
|
||||||
SharedCounter *string `json:"sharedCounter,omitempty"`
|
CounterSet *string `json:"counterSet,omitempty"`
|
||||||
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeviceCounterConsumptionApplyConfiguration constructs a declarative configuration of the DeviceCounterConsumption type for use with
|
// DeviceCounterConsumptionApplyConfiguration constructs a declarative configuration of the DeviceCounterConsumption type for use with
|
||||||
@ -31,11 +31,11 @@ func DeviceCounterConsumption() *DeviceCounterConsumptionApplyConfiguration {
|
|||||||
return &DeviceCounterConsumptionApplyConfiguration{}
|
return &DeviceCounterConsumptionApplyConfiguration{}
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithSharedCounter sets the SharedCounter field in the declarative configuration to the given value
|
// WithCounterSet sets the CounterSet field in the declarative configuration to the given value
|
||||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
// If called multiple times, the SharedCounter field is set to the value of the last call.
|
// If called multiple times, the CounterSet field is set to the value of the last call.
|
||||||
func (b *DeviceCounterConsumptionApplyConfiguration) WithSharedCounter(value string) *DeviceCounterConsumptionApplyConfiguration {
|
func (b *DeviceCounterConsumptionApplyConfiguration) WithCounterSet(value string) *DeviceCounterConsumptionApplyConfiguration {
|
||||||
b.SharedCounter = &value
|
b.CounterSet = &value
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -0,0 +1,94 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// AllocatedDeviceStatusApplyConfiguration represents a declarative configuration of the AllocatedDeviceStatus type for use
|
||||||
|
// with apply.
|
||||||
|
type AllocatedDeviceStatusApplyConfiguration struct {
|
||||||
|
Driver *string `json:"driver,omitempty"`
|
||||||
|
Pool *string `json:"pool,omitempty"`
|
||||||
|
Device *string `json:"device,omitempty"`
|
||||||
|
Conditions []v1.ConditionApplyConfiguration `json:"conditions,omitempty"`
|
||||||
|
Data *runtime.RawExtension `json:"data,omitempty"`
|
||||||
|
NetworkData *NetworkDeviceDataApplyConfiguration `json:"networkData,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllocatedDeviceStatusApplyConfiguration constructs a declarative configuration of the AllocatedDeviceStatus type for use with
|
||||||
|
// apply.
|
||||||
|
func AllocatedDeviceStatus() *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
return &AllocatedDeviceStatusApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDriver sets the Driver field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Driver field is set to the value of the last call.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithDriver(value string) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
b.Driver = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithPool sets the Pool field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Pool field is set to the value of the last call.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithPool(value string) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
b.Pool = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevice sets the Device field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Device field is set to the value of the last call.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithDevice(value string) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
b.Device = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConditions adds the given value to the Conditions field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Conditions field.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithConditions(values ...*v1.ConditionApplyConfiguration) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConditions")
|
||||||
|
}
|
||||||
|
b.Conditions = append(b.Conditions, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithData sets the Data field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Data field is set to the value of the last call.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithData(value runtime.RawExtension) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
b.Data = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNetworkData sets the NetworkData field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NetworkData field is set to the value of the last call.
|
||||||
|
func (b *AllocatedDeviceStatusApplyConfiguration) WithNetworkData(value *NetworkDeviceDataApplyConfiguration) *AllocatedDeviceStatusApplyConfiguration {
|
||||||
|
b.NetworkData = value
|
||||||
|
return b
|
||||||
|
}
|
52
applyconfigurations/resource/v1beta2/allocationresult.go
Normal file
52
applyconfigurations/resource/v1beta2/allocationresult.go
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// AllocationResultApplyConfiguration represents a declarative configuration of the AllocationResult type for use
|
||||||
|
// with apply.
|
||||||
|
type AllocationResultApplyConfiguration struct {
|
||||||
|
Devices *DeviceAllocationResultApplyConfiguration `json:"devices,omitempty"`
|
||||||
|
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllocationResultApplyConfiguration constructs a declarative configuration of the AllocationResult type for use with
|
||||||
|
// apply.
|
||||||
|
func AllocationResult() *AllocationResultApplyConfiguration {
|
||||||
|
return &AllocationResultApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevices sets the Devices field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Devices field is set to the value of the last call.
|
||||||
|
func (b *AllocationResultApplyConfiguration) WithDevices(value *DeviceAllocationResultApplyConfiguration) *AllocationResultApplyConfiguration {
|
||||||
|
b.Devices = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNodeSelector sets the NodeSelector field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NodeSelector field is set to the value of the last call.
|
||||||
|
func (b *AllocationResultApplyConfiguration) WithNodeSelector(value *v1.NodeSelectorApplyConfiguration) *AllocationResultApplyConfiguration {
|
||||||
|
b.NodeSelector = value
|
||||||
|
return b
|
||||||
|
}
|
39
applyconfigurations/resource/v1beta2/celdeviceselector.go
Normal file
39
applyconfigurations/resource/v1beta2/celdeviceselector.go
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// CELDeviceSelectorApplyConfiguration represents a declarative configuration of the CELDeviceSelector type for use
|
||||||
|
// with apply.
|
||||||
|
type CELDeviceSelectorApplyConfiguration struct {
|
||||||
|
Expression *string `json:"expression,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// CELDeviceSelectorApplyConfiguration constructs a declarative configuration of the CELDeviceSelector type for use with
|
||||||
|
// apply.
|
||||||
|
func CELDeviceSelector() *CELDeviceSelectorApplyConfiguration {
|
||||||
|
return &CELDeviceSelectorApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithExpression sets the Expression field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Expression field is set to the value of the last call.
|
||||||
|
func (b *CELDeviceSelectorApplyConfiguration) WithExpression(value string) *CELDeviceSelectorApplyConfiguration {
|
||||||
|
b.Expression = &value
|
||||||
|
return b
|
||||||
|
}
|
43
applyconfigurations/resource/v1beta2/counter.go
Normal file
43
applyconfigurations/resource/v1beta2/counter.go
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resource "k8s.io/apimachinery/pkg/api/resource"
|
||||||
|
)
|
||||||
|
|
||||||
|
// CounterApplyConfiguration represents a declarative configuration of the Counter type for use
|
||||||
|
// with apply.
|
||||||
|
type CounterApplyConfiguration struct {
|
||||||
|
Value *resource.Quantity `json:"value,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// CounterApplyConfiguration constructs a declarative configuration of the Counter type for use with
|
||||||
|
// apply.
|
||||||
|
func Counter() *CounterApplyConfiguration {
|
||||||
|
return &CounterApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithValue sets the Value field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Value field is set to the value of the last call.
|
||||||
|
func (b *CounterApplyConfiguration) WithValue(value resource.Quantity) *CounterApplyConfiguration {
|
||||||
|
b.Value = &value
|
||||||
|
return b
|
||||||
|
}
|
54
applyconfigurations/resource/v1beta2/counterset.go
Normal file
54
applyconfigurations/resource/v1beta2/counterset.go
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// CounterSetApplyConfiguration represents a declarative configuration of the CounterSet type for use
|
||||||
|
// with apply.
|
||||||
|
type CounterSetApplyConfiguration struct {
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// CounterSetApplyConfiguration constructs a declarative configuration of the CounterSet type for use with
|
||||||
|
// apply.
|
||||||
|
func CounterSet() *CounterSetApplyConfiguration {
|
||||||
|
return &CounterSetApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *CounterSetApplyConfiguration) WithName(value string) *CounterSetApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCounters puts the entries into the Counters field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Counters field,
|
||||||
|
// overwriting an existing map entries in Counters field with the same key.
|
||||||
|
func (b *CounterSetApplyConfiguration) WithCounters(entries map[string]CounterApplyConfiguration) *CounterSetApplyConfiguration {
|
||||||
|
if b.Counters == nil && len(entries) > 0 {
|
||||||
|
b.Counters = make(map[string]CounterApplyConfiguration, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.Counters[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
129
applyconfigurations/resource/v1beta2/device.go
Normal file
129
applyconfigurations/resource/v1beta2/device.go
Normal file
@ -0,0 +1,129 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceApplyConfiguration represents a declarative configuration of the Device type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceApplyConfiguration struct {
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
Attributes map[resourcev1beta2.QualifiedName]DeviceAttributeApplyConfiguration `json:"attributes,omitempty"`
|
||||||
|
Capacity map[resourcev1beta2.QualifiedName]DeviceCapacityApplyConfiguration `json:"capacity,omitempty"`
|
||||||
|
ConsumesCounters []DeviceCounterConsumptionApplyConfiguration `json:"consumesCounters,omitempty"`
|
||||||
|
NodeName *string `json:"nodeName,omitempty"`
|
||||||
|
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
||||||
|
AllNodes *bool `json:"allNodes,omitempty"`
|
||||||
|
Taints []DeviceTaintApplyConfiguration `json:"taints,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceApplyConfiguration constructs a declarative configuration of the Device type for use with
|
||||||
|
// apply.
|
||||||
|
func Device() *DeviceApplyConfiguration {
|
||||||
|
return &DeviceApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *DeviceApplyConfiguration) WithName(value string) *DeviceApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAttributes puts the entries into the Attributes field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Attributes field,
|
||||||
|
// overwriting an existing map entries in Attributes field with the same key.
|
||||||
|
func (b *DeviceApplyConfiguration) WithAttributes(entries map[resourcev1beta2.QualifiedName]DeviceAttributeApplyConfiguration) *DeviceApplyConfiguration {
|
||||||
|
if b.Attributes == nil && len(entries) > 0 {
|
||||||
|
b.Attributes = make(map[resourcev1beta2.QualifiedName]DeviceAttributeApplyConfiguration, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.Attributes[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCapacity puts the entries into the Capacity field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Capacity field,
|
||||||
|
// overwriting an existing map entries in Capacity field with the same key.
|
||||||
|
func (b *DeviceApplyConfiguration) WithCapacity(entries map[resourcev1beta2.QualifiedName]DeviceCapacityApplyConfiguration) *DeviceApplyConfiguration {
|
||||||
|
if b.Capacity == nil && len(entries) > 0 {
|
||||||
|
b.Capacity = make(map[resourcev1beta2.QualifiedName]DeviceCapacityApplyConfiguration, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.Capacity[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConsumesCounters adds the given value to the ConsumesCounters field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the ConsumesCounters field.
|
||||||
|
func (b *DeviceApplyConfiguration) WithConsumesCounters(values ...*DeviceCounterConsumptionApplyConfiguration) *DeviceApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConsumesCounters")
|
||||||
|
}
|
||||||
|
b.ConsumesCounters = append(b.ConsumesCounters, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNodeName sets the NodeName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NodeName field is set to the value of the last call.
|
||||||
|
func (b *DeviceApplyConfiguration) WithNodeName(value string) *DeviceApplyConfiguration {
|
||||||
|
b.NodeName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNodeSelector sets the NodeSelector field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NodeSelector field is set to the value of the last call.
|
||||||
|
func (b *DeviceApplyConfiguration) WithNodeSelector(value *v1.NodeSelectorApplyConfiguration) *DeviceApplyConfiguration {
|
||||||
|
b.NodeSelector = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAllNodes sets the AllNodes field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AllNodes field is set to the value of the last call.
|
||||||
|
func (b *DeviceApplyConfiguration) WithAllNodes(value bool) *DeviceApplyConfiguration {
|
||||||
|
b.AllNodes = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTaints adds the given value to the Taints field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Taints field.
|
||||||
|
func (b *DeviceApplyConfiguration) WithTaints(values ...*DeviceTaintApplyConfiguration) *DeviceApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithTaints")
|
||||||
|
}
|
||||||
|
b.Taints = append(b.Taints, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,63 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceAllocationConfigurationApplyConfiguration represents a declarative configuration of the DeviceAllocationConfiguration type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceAllocationConfigurationApplyConfiguration struct {
|
||||||
|
Source *resourcev1beta2.AllocationConfigSource `json:"source,omitempty"`
|
||||||
|
Requests []string `json:"requests,omitempty"`
|
||||||
|
DeviceConfigurationApplyConfiguration `json:",inline"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceAllocationConfigurationApplyConfiguration constructs a declarative configuration of the DeviceAllocationConfiguration type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceAllocationConfiguration() *DeviceAllocationConfigurationApplyConfiguration {
|
||||||
|
return &DeviceAllocationConfigurationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSource sets the Source field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Source field is set to the value of the last call.
|
||||||
|
func (b *DeviceAllocationConfigurationApplyConfiguration) WithSource(value resourcev1beta2.AllocationConfigSource) *DeviceAllocationConfigurationApplyConfiguration {
|
||||||
|
b.Source = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithRequests adds the given value to the Requests field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Requests field.
|
||||||
|
func (b *DeviceAllocationConfigurationApplyConfiguration) WithRequests(values ...string) *DeviceAllocationConfigurationApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
b.Requests = append(b.Requests, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOpaque sets the Opaque field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Opaque field is set to the value of the last call.
|
||||||
|
func (b *DeviceAllocationConfigurationApplyConfiguration) WithOpaque(value *OpaqueDeviceConfigurationApplyConfiguration) *DeviceAllocationConfigurationApplyConfiguration {
|
||||||
|
b.DeviceConfigurationApplyConfiguration.Opaque = value
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,58 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceAllocationResultApplyConfiguration represents a declarative configuration of the DeviceAllocationResult type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceAllocationResultApplyConfiguration struct {
|
||||||
|
Results []DeviceRequestAllocationResultApplyConfiguration `json:"results,omitempty"`
|
||||||
|
Config []DeviceAllocationConfigurationApplyConfiguration `json:"config,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceAllocationResultApplyConfiguration constructs a declarative configuration of the DeviceAllocationResult type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceAllocationResult() *DeviceAllocationResultApplyConfiguration {
|
||||||
|
return &DeviceAllocationResultApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResults adds the given value to the Results field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Results field.
|
||||||
|
func (b *DeviceAllocationResultApplyConfiguration) WithResults(values ...*DeviceRequestAllocationResultApplyConfiguration) *DeviceAllocationResultApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithResults")
|
||||||
|
}
|
||||||
|
b.Results = append(b.Results, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConfig adds the given value to the Config field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Config field.
|
||||||
|
func (b *DeviceAllocationResultApplyConfiguration) WithConfig(values ...*DeviceAllocationConfigurationApplyConfiguration) *DeviceAllocationResultApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConfig")
|
||||||
|
}
|
||||||
|
b.Config = append(b.Config, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
66
applyconfigurations/resource/v1beta2/deviceattribute.go
Normal file
66
applyconfigurations/resource/v1beta2/deviceattribute.go
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceAttributeApplyConfiguration represents a declarative configuration of the DeviceAttribute type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceAttributeApplyConfiguration struct {
|
||||||
|
IntValue *int64 `json:"int,omitempty"`
|
||||||
|
BoolValue *bool `json:"bool,omitempty"`
|
||||||
|
StringValue *string `json:"string,omitempty"`
|
||||||
|
VersionValue *string `json:"version,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceAttributeApplyConfiguration constructs a declarative configuration of the DeviceAttribute type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceAttribute() *DeviceAttributeApplyConfiguration {
|
||||||
|
return &DeviceAttributeApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithIntValue sets the IntValue field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the IntValue field is set to the value of the last call.
|
||||||
|
func (b *DeviceAttributeApplyConfiguration) WithIntValue(value int64) *DeviceAttributeApplyConfiguration {
|
||||||
|
b.IntValue = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithBoolValue sets the BoolValue field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the BoolValue field is set to the value of the last call.
|
||||||
|
func (b *DeviceAttributeApplyConfiguration) WithBoolValue(value bool) *DeviceAttributeApplyConfiguration {
|
||||||
|
b.BoolValue = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithStringValue sets the StringValue field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the StringValue field is set to the value of the last call.
|
||||||
|
func (b *DeviceAttributeApplyConfiguration) WithStringValue(value string) *DeviceAttributeApplyConfiguration {
|
||||||
|
b.StringValue = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithVersionValue sets the VersionValue field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the VersionValue field is set to the value of the last call.
|
||||||
|
func (b *DeviceAttributeApplyConfiguration) WithVersionValue(value string) *DeviceAttributeApplyConfiguration {
|
||||||
|
b.VersionValue = &value
|
||||||
|
return b
|
||||||
|
}
|
43
applyconfigurations/resource/v1beta2/devicecapacity.go
Normal file
43
applyconfigurations/resource/v1beta2/devicecapacity.go
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resource "k8s.io/apimachinery/pkg/api/resource"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceCapacityApplyConfiguration represents a declarative configuration of the DeviceCapacity type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceCapacityApplyConfiguration struct {
|
||||||
|
Value *resource.Quantity `json:"value,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceCapacityApplyConfiguration constructs a declarative configuration of the DeviceCapacity type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceCapacity() *DeviceCapacityApplyConfiguration {
|
||||||
|
return &DeviceCapacityApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithValue sets the Value field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Value field is set to the value of the last call.
|
||||||
|
func (b *DeviceCapacityApplyConfiguration) WithValue(value resource.Quantity) *DeviceCapacityApplyConfiguration {
|
||||||
|
b.Value = &value
|
||||||
|
return b
|
||||||
|
}
|
72
applyconfigurations/resource/v1beta2/deviceclaim.go
Normal file
72
applyconfigurations/resource/v1beta2/deviceclaim.go
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceClaimApplyConfiguration represents a declarative configuration of the DeviceClaim type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceClaimApplyConfiguration struct {
|
||||||
|
Requests []DeviceRequestApplyConfiguration `json:"requests,omitempty"`
|
||||||
|
Constraints []DeviceConstraintApplyConfiguration `json:"constraints,omitempty"`
|
||||||
|
Config []DeviceClaimConfigurationApplyConfiguration `json:"config,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClaimApplyConfiguration constructs a declarative configuration of the DeviceClaim type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceClaim() *DeviceClaimApplyConfiguration {
|
||||||
|
return &DeviceClaimApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithRequests adds the given value to the Requests field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Requests field.
|
||||||
|
func (b *DeviceClaimApplyConfiguration) WithRequests(values ...*DeviceRequestApplyConfiguration) *DeviceClaimApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithRequests")
|
||||||
|
}
|
||||||
|
b.Requests = append(b.Requests, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConstraints adds the given value to the Constraints field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Constraints field.
|
||||||
|
func (b *DeviceClaimApplyConfiguration) WithConstraints(values ...*DeviceConstraintApplyConfiguration) *DeviceClaimApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConstraints")
|
||||||
|
}
|
||||||
|
b.Constraints = append(b.Constraints, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConfig adds the given value to the Config field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Config field.
|
||||||
|
func (b *DeviceClaimApplyConfiguration) WithConfig(values ...*DeviceClaimConfigurationApplyConfiguration) *DeviceClaimApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConfig")
|
||||||
|
}
|
||||||
|
b.Config = append(b.Config, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,50 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceClaimConfigurationApplyConfiguration represents a declarative configuration of the DeviceClaimConfiguration type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceClaimConfigurationApplyConfiguration struct {
|
||||||
|
Requests []string `json:"requests,omitempty"`
|
||||||
|
DeviceConfigurationApplyConfiguration `json:",inline"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClaimConfigurationApplyConfiguration constructs a declarative configuration of the DeviceClaimConfiguration type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceClaimConfiguration() *DeviceClaimConfigurationApplyConfiguration {
|
||||||
|
return &DeviceClaimConfigurationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithRequests adds the given value to the Requests field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Requests field.
|
||||||
|
func (b *DeviceClaimConfigurationApplyConfiguration) WithRequests(values ...string) *DeviceClaimConfigurationApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
b.Requests = append(b.Requests, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOpaque sets the Opaque field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Opaque field is set to the value of the last call.
|
||||||
|
func (b *DeviceClaimConfigurationApplyConfiguration) WithOpaque(value *OpaqueDeviceConfigurationApplyConfiguration) *DeviceClaimConfigurationApplyConfiguration {
|
||||||
|
b.DeviceConfigurationApplyConfiguration.Opaque = value
|
||||||
|
return b
|
||||||
|
}
|
253
applyconfigurations/resource/v1beta2/deviceclass.go
Normal file
253
applyconfigurations/resource/v1beta2/deviceclass.go
Normal file
@ -0,0 +1,253 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||||
|
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceClassApplyConfiguration represents a declarative configuration of the DeviceClass type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceClassApplyConfiguration struct {
|
||||||
|
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||||
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
|
Spec *DeviceClassSpecApplyConfiguration `json:"spec,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClass constructs a declarative configuration of the DeviceClass type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceClass(name string) *DeviceClassApplyConfiguration {
|
||||||
|
b := &DeviceClassApplyConfiguration{}
|
||||||
|
b.WithName(name)
|
||||||
|
b.WithKind("DeviceClass")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractDeviceClass extracts the applied configuration owned by fieldManager from
|
||||||
|
// deviceClass. If no managedFields are found in deviceClass for fieldManager, a
|
||||||
|
// DeviceClassApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||||
|
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||||
|
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||||
|
// the fieldManager never owned fields any fields.
|
||||||
|
// deviceClass must be a unmodified DeviceClass API object that was retrieved from the Kubernetes API.
|
||||||
|
// ExtractDeviceClass provides a way to perform a extract/modify-in-place/apply workflow.
|
||||||
|
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||||
|
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractDeviceClass(deviceClass *resourcev1beta2.DeviceClass, fieldManager string) (*DeviceClassApplyConfiguration, error) {
|
||||||
|
return extractDeviceClass(deviceClass, fieldManager, "")
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractDeviceClassStatus is the same as ExtractDeviceClass except
|
||||||
|
// that it extracts the status subresource applied configuration.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractDeviceClassStatus(deviceClass *resourcev1beta2.DeviceClass, fieldManager string) (*DeviceClassApplyConfiguration, error) {
|
||||||
|
return extractDeviceClass(deviceClass, fieldManager, "status")
|
||||||
|
}
|
||||||
|
|
||||||
|
func extractDeviceClass(deviceClass *resourcev1beta2.DeviceClass, fieldManager string, subresource string) (*DeviceClassApplyConfiguration, error) {
|
||||||
|
b := &DeviceClassApplyConfiguration{}
|
||||||
|
err := managedfields.ExtractInto(deviceClass, internal.Parser().Type("io.k8s.api.resource.v1beta2.DeviceClass"), fieldManager, b, subresource)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
b.WithName(deviceClass.Name)
|
||||||
|
|
||||||
|
b.WithKind("DeviceClass")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKind sets the Kind field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Kind field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithKind(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.Kind = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the APIVersion field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithAPIVersion(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithName(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithGenerateName(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithNamespace(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithUID(value types.UID) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithResourceVersion(value string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithGeneration(value int64) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithCreationTimestamp(value metav1.Time) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||||
|
// overwriting an existing map entries in Labels field with the same key.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithLabels(entries map[string]string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||||
|
// overwriting an existing map entries in Annotations field with the same key.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithAnnotations(entries map[string]string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithOwnerReferences")
|
||||||
|
}
|
||||||
|
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithFinalizers(values ...string) *DeviceClassApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
func (b *DeviceClassApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||||
|
if b.ObjectMetaApplyConfiguration == nil {
|
||||||
|
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Spec field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassApplyConfiguration) WithSpec(value *DeviceClassSpecApplyConfiguration) *DeviceClassApplyConfiguration {
|
||||||
|
b.Spec = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||||
|
func (b *DeviceClassApplyConfiguration) GetName() *string {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
return b.ObjectMetaApplyConfiguration.Name
|
||||||
|
}
|
@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceClassConfigurationApplyConfiguration represents a declarative configuration of the DeviceClassConfiguration type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceClassConfigurationApplyConfiguration struct {
|
||||||
|
DeviceConfigurationApplyConfiguration `json:",inline"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClassConfigurationApplyConfiguration constructs a declarative configuration of the DeviceClassConfiguration type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceClassConfiguration() *DeviceClassConfigurationApplyConfiguration {
|
||||||
|
return &DeviceClassConfigurationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOpaque sets the Opaque field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Opaque field is set to the value of the last call.
|
||||||
|
func (b *DeviceClassConfigurationApplyConfiguration) WithOpaque(value *OpaqueDeviceConfigurationApplyConfiguration) *DeviceClassConfigurationApplyConfiguration {
|
||||||
|
b.DeviceConfigurationApplyConfiguration.Opaque = value
|
||||||
|
return b
|
||||||
|
}
|
58
applyconfigurations/resource/v1beta2/deviceclassspec.go
Normal file
58
applyconfigurations/resource/v1beta2/deviceclassspec.go
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceClassSpecApplyConfiguration represents a declarative configuration of the DeviceClassSpec type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceClassSpecApplyConfiguration struct {
|
||||||
|
Selectors []DeviceSelectorApplyConfiguration `json:"selectors,omitempty"`
|
||||||
|
Config []DeviceClassConfigurationApplyConfiguration `json:"config,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClassSpecApplyConfiguration constructs a declarative configuration of the DeviceClassSpec type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceClassSpec() *DeviceClassSpecApplyConfiguration {
|
||||||
|
return &DeviceClassSpecApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSelectors adds the given value to the Selectors field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Selectors field.
|
||||||
|
func (b *DeviceClassSpecApplyConfiguration) WithSelectors(values ...*DeviceSelectorApplyConfiguration) *DeviceClassSpecApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithSelectors")
|
||||||
|
}
|
||||||
|
b.Selectors = append(b.Selectors, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithConfig adds the given value to the Config field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Config field.
|
||||||
|
func (b *DeviceClassSpecApplyConfiguration) WithConfig(values ...*DeviceClassConfigurationApplyConfiguration) *DeviceClassSpecApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithConfig")
|
||||||
|
}
|
||||||
|
b.Config = append(b.Config, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
39
applyconfigurations/resource/v1beta2/deviceconfiguration.go
Normal file
39
applyconfigurations/resource/v1beta2/deviceconfiguration.go
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceConfigurationApplyConfiguration represents a declarative configuration of the DeviceConfiguration type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceConfigurationApplyConfiguration struct {
|
||||||
|
Opaque *OpaqueDeviceConfigurationApplyConfiguration `json:"opaque,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceConfigurationApplyConfiguration constructs a declarative configuration of the DeviceConfiguration type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceConfiguration() *DeviceConfigurationApplyConfiguration {
|
||||||
|
return &DeviceConfigurationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOpaque sets the Opaque field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Opaque field is set to the value of the last call.
|
||||||
|
func (b *DeviceConfigurationApplyConfiguration) WithOpaque(value *OpaqueDeviceConfigurationApplyConfiguration) *DeviceConfigurationApplyConfiguration {
|
||||||
|
b.Opaque = value
|
||||||
|
return b
|
||||||
|
}
|
54
applyconfigurations/resource/v1beta2/deviceconstraint.go
Normal file
54
applyconfigurations/resource/v1beta2/deviceconstraint.go
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceConstraintApplyConfiguration represents a declarative configuration of the DeviceConstraint type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceConstraintApplyConfiguration struct {
|
||||||
|
Requests []string `json:"requests,omitempty"`
|
||||||
|
MatchAttribute *resourcev1beta2.FullyQualifiedName `json:"matchAttribute,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceConstraintApplyConfiguration constructs a declarative configuration of the DeviceConstraint type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceConstraint() *DeviceConstraintApplyConfiguration {
|
||||||
|
return &DeviceConstraintApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithRequests adds the given value to the Requests field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Requests field.
|
||||||
|
func (b *DeviceConstraintApplyConfiguration) WithRequests(values ...string) *DeviceConstraintApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
b.Requests = append(b.Requests, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithMatchAttribute sets the MatchAttribute field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the MatchAttribute field is set to the value of the last call.
|
||||||
|
func (b *DeviceConstraintApplyConfiguration) WithMatchAttribute(value resourcev1beta2.FullyQualifiedName) *DeviceConstraintApplyConfiguration {
|
||||||
|
b.MatchAttribute = &value
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,54 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceCounterConsumptionApplyConfiguration represents a declarative configuration of the DeviceCounterConsumption type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceCounterConsumptionApplyConfiguration struct {
|
||||||
|
CounterSet *string `json:"counterSet,omitempty"`
|
||||||
|
Counters map[string]CounterApplyConfiguration `json:"counters,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceCounterConsumptionApplyConfiguration constructs a declarative configuration of the DeviceCounterConsumption type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceCounterConsumption() *DeviceCounterConsumptionApplyConfiguration {
|
||||||
|
return &DeviceCounterConsumptionApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCounterSet sets the CounterSet field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CounterSet field is set to the value of the last call.
|
||||||
|
func (b *DeviceCounterConsumptionApplyConfiguration) WithCounterSet(value string) *DeviceCounterConsumptionApplyConfiguration {
|
||||||
|
b.CounterSet = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCounters puts the entries into the Counters field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Counters field,
|
||||||
|
// overwriting an existing map entries in Counters field with the same key.
|
||||||
|
func (b *DeviceCounterConsumptionApplyConfiguration) WithCounters(entries map[string]CounterApplyConfiguration) *DeviceCounterConsumptionApplyConfiguration {
|
||||||
|
if b.Counters == nil && len(entries) > 0 {
|
||||||
|
b.Counters = make(map[string]CounterApplyConfiguration, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.Counters[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
62
applyconfigurations/resource/v1beta2/devicerequest.go
Normal file
62
applyconfigurations/resource/v1beta2/devicerequest.go
Normal file
@ -0,0 +1,62 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceRequestApplyConfiguration represents a declarative configuration of the DeviceRequest type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceRequestApplyConfiguration struct {
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
Exactly *ExactDeviceRequestApplyConfiguration `json:"exactly,omitempty"`
|
||||||
|
FirstAvailable []DeviceSubRequestApplyConfiguration `json:"firstAvailable,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceRequestApplyConfiguration constructs a declarative configuration of the DeviceRequest type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceRequest() *DeviceRequestApplyConfiguration {
|
||||||
|
return &DeviceRequestApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestApplyConfiguration) WithName(value string) *DeviceRequestApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithExactly sets the Exactly field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Exactly field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestApplyConfiguration) WithExactly(value *ExactDeviceRequestApplyConfiguration) *DeviceRequestApplyConfiguration {
|
||||||
|
b.Exactly = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFirstAvailable adds the given value to the FirstAvailable field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the FirstAvailable field.
|
||||||
|
func (b *DeviceRequestApplyConfiguration) WithFirstAvailable(values ...*DeviceSubRequestApplyConfiguration) *DeviceRequestApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithFirstAvailable")
|
||||||
|
}
|
||||||
|
b.FirstAvailable = append(b.FirstAvailable, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,89 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceRequestAllocationResultApplyConfiguration represents a declarative configuration of the DeviceRequestAllocationResult type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceRequestAllocationResultApplyConfiguration struct {
|
||||||
|
Request *string `json:"request,omitempty"`
|
||||||
|
Driver *string `json:"driver,omitempty"`
|
||||||
|
Pool *string `json:"pool,omitempty"`
|
||||||
|
Device *string `json:"device,omitempty"`
|
||||||
|
AdminAccess *bool `json:"adminAccess,omitempty"`
|
||||||
|
Tolerations []DeviceTolerationApplyConfiguration `json:"tolerations,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceRequestAllocationResultApplyConfiguration constructs a declarative configuration of the DeviceRequestAllocationResult type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceRequestAllocationResult() *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
return &DeviceRequestAllocationResultApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithRequest sets the Request field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Request field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithRequest(value string) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
b.Request = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDriver sets the Driver field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Driver field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithDriver(value string) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
b.Driver = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithPool sets the Pool field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Pool field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithPool(value string) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
b.Pool = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevice sets the Device field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Device field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithDevice(value string) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
b.Device = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAdminAccess sets the AdminAccess field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AdminAccess field is set to the value of the last call.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithAdminAccess(value bool) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
b.AdminAccess = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTolerations adds the given value to the Tolerations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Tolerations field.
|
||||||
|
func (b *DeviceRequestAllocationResultApplyConfiguration) WithTolerations(values ...*DeviceTolerationApplyConfiguration) *DeviceRequestAllocationResultApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithTolerations")
|
||||||
|
}
|
||||||
|
b.Tolerations = append(b.Tolerations, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
39
applyconfigurations/resource/v1beta2/deviceselector.go
Normal file
39
applyconfigurations/resource/v1beta2/deviceselector.go
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceSelectorApplyConfiguration represents a declarative configuration of the DeviceSelector type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceSelectorApplyConfiguration struct {
|
||||||
|
CEL *CELDeviceSelectorApplyConfiguration `json:"cel,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceSelectorApplyConfiguration constructs a declarative configuration of the DeviceSelector type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceSelector() *DeviceSelectorApplyConfiguration {
|
||||||
|
return &DeviceSelectorApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCEL sets the CEL field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CEL field is set to the value of the last call.
|
||||||
|
func (b *DeviceSelectorApplyConfiguration) WithCEL(value *CELDeviceSelectorApplyConfiguration) *DeviceSelectorApplyConfiguration {
|
||||||
|
b.CEL = value
|
||||||
|
return b
|
||||||
|
}
|
98
applyconfigurations/resource/v1beta2/devicesubrequest.go
Normal file
98
applyconfigurations/resource/v1beta2/devicesubrequest.go
Normal file
@ -0,0 +1,98 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceSubRequestApplyConfiguration represents a declarative configuration of the DeviceSubRequest type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceSubRequestApplyConfiguration struct {
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
DeviceClassName *string `json:"deviceClassName,omitempty"`
|
||||||
|
Selectors []DeviceSelectorApplyConfiguration `json:"selectors,omitempty"`
|
||||||
|
AllocationMode *resourcev1beta2.DeviceAllocationMode `json:"allocationMode,omitempty"`
|
||||||
|
Count *int64 `json:"count,omitempty"`
|
||||||
|
Tolerations []DeviceTolerationApplyConfiguration `json:"tolerations,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceSubRequestApplyConfiguration constructs a declarative configuration of the DeviceSubRequest type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceSubRequest() *DeviceSubRequestApplyConfiguration {
|
||||||
|
return &DeviceSubRequestApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithName(value string) *DeviceSubRequestApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeviceClassName sets the DeviceClassName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeviceClassName field is set to the value of the last call.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithDeviceClassName(value string) *DeviceSubRequestApplyConfiguration {
|
||||||
|
b.DeviceClassName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSelectors adds the given value to the Selectors field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Selectors field.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithSelectors(values ...*DeviceSelectorApplyConfiguration) *DeviceSubRequestApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithSelectors")
|
||||||
|
}
|
||||||
|
b.Selectors = append(b.Selectors, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAllocationMode sets the AllocationMode field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AllocationMode field is set to the value of the last call.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithAllocationMode(value resourcev1beta2.DeviceAllocationMode) *DeviceSubRequestApplyConfiguration {
|
||||||
|
b.AllocationMode = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCount sets the Count field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Count field is set to the value of the last call.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithCount(value int64) *DeviceSubRequestApplyConfiguration {
|
||||||
|
b.Count = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTolerations adds the given value to the Tolerations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Tolerations field.
|
||||||
|
func (b *DeviceSubRequestApplyConfiguration) WithTolerations(values ...*DeviceTolerationApplyConfiguration) *DeviceSubRequestApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithTolerations")
|
||||||
|
}
|
||||||
|
b.Tolerations = append(b.Tolerations, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
71
applyconfigurations/resource/v1beta2/devicetaint.go
Normal file
71
applyconfigurations/resource/v1beta2/devicetaint.go
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceTaintApplyConfiguration represents a declarative configuration of the DeviceTaint type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceTaintApplyConfiguration struct {
|
||||||
|
Key *string `json:"key,omitempty"`
|
||||||
|
Value *string `json:"value,omitempty"`
|
||||||
|
Effect *resourcev1beta2.DeviceTaintEffect `json:"effect,omitempty"`
|
||||||
|
TimeAdded *v1.Time `json:"timeAdded,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceTaintApplyConfiguration constructs a declarative configuration of the DeviceTaint type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceTaint() *DeviceTaintApplyConfiguration {
|
||||||
|
return &DeviceTaintApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKey sets the Key field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Key field is set to the value of the last call.
|
||||||
|
func (b *DeviceTaintApplyConfiguration) WithKey(value string) *DeviceTaintApplyConfiguration {
|
||||||
|
b.Key = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithValue sets the Value field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Value field is set to the value of the last call.
|
||||||
|
func (b *DeviceTaintApplyConfiguration) WithValue(value string) *DeviceTaintApplyConfiguration {
|
||||||
|
b.Value = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithEffect sets the Effect field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Effect field is set to the value of the last call.
|
||||||
|
func (b *DeviceTaintApplyConfiguration) WithEffect(value resourcev1beta2.DeviceTaintEffect) *DeviceTaintApplyConfiguration {
|
||||||
|
b.Effect = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTimeAdded sets the TimeAdded field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the TimeAdded field is set to the value of the last call.
|
||||||
|
func (b *DeviceTaintApplyConfiguration) WithTimeAdded(value v1.Time) *DeviceTaintApplyConfiguration {
|
||||||
|
b.TimeAdded = &value
|
||||||
|
return b
|
||||||
|
}
|
79
applyconfigurations/resource/v1beta2/devicetoleration.go
Normal file
79
applyconfigurations/resource/v1beta2/devicetoleration.go
Normal file
@ -0,0 +1,79 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceTolerationApplyConfiguration represents a declarative configuration of the DeviceToleration type for use
|
||||||
|
// with apply.
|
||||||
|
type DeviceTolerationApplyConfiguration struct {
|
||||||
|
Key *string `json:"key,omitempty"`
|
||||||
|
Operator *resourcev1beta2.DeviceTolerationOperator `json:"operator,omitempty"`
|
||||||
|
Value *string `json:"value,omitempty"`
|
||||||
|
Effect *resourcev1beta2.DeviceTaintEffect `json:"effect,omitempty"`
|
||||||
|
TolerationSeconds *int64 `json:"tolerationSeconds,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceTolerationApplyConfiguration constructs a declarative configuration of the DeviceToleration type for use with
|
||||||
|
// apply.
|
||||||
|
func DeviceToleration() *DeviceTolerationApplyConfiguration {
|
||||||
|
return &DeviceTolerationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKey sets the Key field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Key field is set to the value of the last call.
|
||||||
|
func (b *DeviceTolerationApplyConfiguration) WithKey(value string) *DeviceTolerationApplyConfiguration {
|
||||||
|
b.Key = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOperator sets the Operator field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Operator field is set to the value of the last call.
|
||||||
|
func (b *DeviceTolerationApplyConfiguration) WithOperator(value resourcev1beta2.DeviceTolerationOperator) *DeviceTolerationApplyConfiguration {
|
||||||
|
b.Operator = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithValue sets the Value field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Value field is set to the value of the last call.
|
||||||
|
func (b *DeviceTolerationApplyConfiguration) WithValue(value string) *DeviceTolerationApplyConfiguration {
|
||||||
|
b.Value = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithEffect sets the Effect field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Effect field is set to the value of the last call.
|
||||||
|
func (b *DeviceTolerationApplyConfiguration) WithEffect(value resourcev1beta2.DeviceTaintEffect) *DeviceTolerationApplyConfiguration {
|
||||||
|
b.Effect = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTolerationSeconds sets the TolerationSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the TolerationSeconds field is set to the value of the last call.
|
||||||
|
func (b *DeviceTolerationApplyConfiguration) WithTolerationSeconds(value int64) *DeviceTolerationApplyConfiguration {
|
||||||
|
b.TolerationSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
98
applyconfigurations/resource/v1beta2/exactdevicerequest.go
Normal file
98
applyconfigurations/resource/v1beta2/exactdevicerequest.go
Normal file
@ -0,0 +1,98 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ExactDeviceRequestApplyConfiguration represents a declarative configuration of the ExactDeviceRequest type for use
|
||||||
|
// with apply.
|
||||||
|
type ExactDeviceRequestApplyConfiguration struct {
|
||||||
|
DeviceClassName *string `json:"deviceClassName,omitempty"`
|
||||||
|
Selectors []DeviceSelectorApplyConfiguration `json:"selectors,omitempty"`
|
||||||
|
AllocationMode *resourcev1beta2.DeviceAllocationMode `json:"allocationMode,omitempty"`
|
||||||
|
Count *int64 `json:"count,omitempty"`
|
||||||
|
AdminAccess *bool `json:"adminAccess,omitempty"`
|
||||||
|
Tolerations []DeviceTolerationApplyConfiguration `json:"tolerations,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExactDeviceRequestApplyConfiguration constructs a declarative configuration of the ExactDeviceRequest type for use with
|
||||||
|
// apply.
|
||||||
|
func ExactDeviceRequest() *ExactDeviceRequestApplyConfiguration {
|
||||||
|
return &ExactDeviceRequestApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeviceClassName sets the DeviceClassName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeviceClassName field is set to the value of the last call.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithDeviceClassName(value string) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
b.DeviceClassName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSelectors adds the given value to the Selectors field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Selectors field.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithSelectors(values ...*DeviceSelectorApplyConfiguration) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithSelectors")
|
||||||
|
}
|
||||||
|
b.Selectors = append(b.Selectors, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAllocationMode sets the AllocationMode field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AllocationMode field is set to the value of the last call.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithAllocationMode(value resourcev1beta2.DeviceAllocationMode) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
b.AllocationMode = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCount sets the Count field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Count field is set to the value of the last call.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithCount(value int64) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
b.Count = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAdminAccess sets the AdminAccess field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AdminAccess field is set to the value of the last call.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithAdminAccess(value bool) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
b.AdminAccess = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithTolerations adds the given value to the Tolerations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Tolerations field.
|
||||||
|
func (b *ExactDeviceRequestApplyConfiguration) WithTolerations(values ...*DeviceTolerationApplyConfiguration) *ExactDeviceRequestApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithTolerations")
|
||||||
|
}
|
||||||
|
b.Tolerations = append(b.Tolerations, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
59
applyconfigurations/resource/v1beta2/networkdevicedata.go
Normal file
59
applyconfigurations/resource/v1beta2/networkdevicedata.go
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// NetworkDeviceDataApplyConfiguration represents a declarative configuration of the NetworkDeviceData type for use
|
||||||
|
// with apply.
|
||||||
|
type NetworkDeviceDataApplyConfiguration struct {
|
||||||
|
InterfaceName *string `json:"interfaceName,omitempty"`
|
||||||
|
IPs []string `json:"ips,omitempty"`
|
||||||
|
HardwareAddress *string `json:"hardwareAddress,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// NetworkDeviceDataApplyConfiguration constructs a declarative configuration of the NetworkDeviceData type for use with
|
||||||
|
// apply.
|
||||||
|
func NetworkDeviceData() *NetworkDeviceDataApplyConfiguration {
|
||||||
|
return &NetworkDeviceDataApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithInterfaceName sets the InterfaceName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the InterfaceName field is set to the value of the last call.
|
||||||
|
func (b *NetworkDeviceDataApplyConfiguration) WithInterfaceName(value string) *NetworkDeviceDataApplyConfiguration {
|
||||||
|
b.InterfaceName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithIPs adds the given value to the IPs field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the IPs field.
|
||||||
|
func (b *NetworkDeviceDataApplyConfiguration) WithIPs(values ...string) *NetworkDeviceDataApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
b.IPs = append(b.IPs, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithHardwareAddress sets the HardwareAddress field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the HardwareAddress field is set to the value of the last call.
|
||||||
|
func (b *NetworkDeviceDataApplyConfiguration) WithHardwareAddress(value string) *NetworkDeviceDataApplyConfiguration {
|
||||||
|
b.HardwareAddress = &value
|
||||||
|
return b
|
||||||
|
}
|
@ -0,0 +1,52 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
)
|
||||||
|
|
||||||
|
// OpaqueDeviceConfigurationApplyConfiguration represents a declarative configuration of the OpaqueDeviceConfiguration type for use
|
||||||
|
// with apply.
|
||||||
|
type OpaqueDeviceConfigurationApplyConfiguration struct {
|
||||||
|
Driver *string `json:"driver,omitempty"`
|
||||||
|
Parameters *runtime.RawExtension `json:"parameters,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// OpaqueDeviceConfigurationApplyConfiguration constructs a declarative configuration of the OpaqueDeviceConfiguration type for use with
|
||||||
|
// apply.
|
||||||
|
func OpaqueDeviceConfiguration() *OpaqueDeviceConfigurationApplyConfiguration {
|
||||||
|
return &OpaqueDeviceConfigurationApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDriver sets the Driver field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Driver field is set to the value of the last call.
|
||||||
|
func (b *OpaqueDeviceConfigurationApplyConfiguration) WithDriver(value string) *OpaqueDeviceConfigurationApplyConfiguration {
|
||||||
|
b.Driver = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithParameters sets the Parameters field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Parameters field is set to the value of the last call.
|
||||||
|
func (b *OpaqueDeviceConfigurationApplyConfiguration) WithParameters(value runtime.RawExtension) *OpaqueDeviceConfigurationApplyConfiguration {
|
||||||
|
b.Parameters = &value
|
||||||
|
return b
|
||||||
|
}
|
264
applyconfigurations/resource/v1beta2/resourceclaim.go
Normal file
264
applyconfigurations/resource/v1beta2/resourceclaim.go
Normal file
@ -0,0 +1,264 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||||
|
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimApplyConfiguration represents a declarative configuration of the ResourceClaim type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimApplyConfiguration struct {
|
||||||
|
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||||
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
|
Spec *ResourceClaimSpecApplyConfiguration `json:"spec,omitempty"`
|
||||||
|
Status *ResourceClaimStatusApplyConfiguration `json:"status,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaim constructs a declarative configuration of the ResourceClaim type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaim(name, namespace string) *ResourceClaimApplyConfiguration {
|
||||||
|
b := &ResourceClaimApplyConfiguration{}
|
||||||
|
b.WithName(name)
|
||||||
|
b.WithNamespace(namespace)
|
||||||
|
b.WithKind("ResourceClaim")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceClaim extracts the applied configuration owned by fieldManager from
|
||||||
|
// resourceClaim. If no managedFields are found in resourceClaim for fieldManager, a
|
||||||
|
// ResourceClaimApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||||
|
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||||
|
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||||
|
// the fieldManager never owned fields any fields.
|
||||||
|
// resourceClaim must be a unmodified ResourceClaim API object that was retrieved from the Kubernetes API.
|
||||||
|
// ExtractResourceClaim provides a way to perform a extract/modify-in-place/apply workflow.
|
||||||
|
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||||
|
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceClaim(resourceClaim *resourcev1beta2.ResourceClaim, fieldManager string) (*ResourceClaimApplyConfiguration, error) {
|
||||||
|
return extractResourceClaim(resourceClaim, fieldManager, "")
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceClaimStatus is the same as ExtractResourceClaim except
|
||||||
|
// that it extracts the status subresource applied configuration.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceClaimStatus(resourceClaim *resourcev1beta2.ResourceClaim, fieldManager string) (*ResourceClaimApplyConfiguration, error) {
|
||||||
|
return extractResourceClaim(resourceClaim, fieldManager, "status")
|
||||||
|
}
|
||||||
|
|
||||||
|
func extractResourceClaim(resourceClaim *resourcev1beta2.ResourceClaim, fieldManager string, subresource string) (*ResourceClaimApplyConfiguration, error) {
|
||||||
|
b := &ResourceClaimApplyConfiguration{}
|
||||||
|
err := managedfields.ExtractInto(resourceClaim, internal.Parser().Type("io.k8s.api.resource.v1beta2.ResourceClaim"), fieldManager, b, subresource)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
b.WithName(resourceClaim.Name)
|
||||||
|
b.WithNamespace(resourceClaim.Namespace)
|
||||||
|
|
||||||
|
b.WithKind("ResourceClaim")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKind sets the Kind field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Kind field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithKind(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.Kind = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the APIVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithAPIVersion(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithName(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithGenerateName(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithNamespace(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithUID(value types.UID) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithResourceVersion(value string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithGeneration(value int64) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||||
|
// overwriting an existing map entries in Labels field with the same key.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithLabels(entries map[string]string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||||
|
// overwriting an existing map entries in Annotations field with the same key.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithAnnotations(entries map[string]string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithOwnerReferences")
|
||||||
|
}
|
||||||
|
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithFinalizers(values ...string) *ResourceClaimApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
func (b *ResourceClaimApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||||
|
if b.ObjectMetaApplyConfiguration == nil {
|
||||||
|
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Spec field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithSpec(value *ResourceClaimSpecApplyConfiguration) *ResourceClaimApplyConfiguration {
|
||||||
|
b.Spec = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithStatus sets the Status field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Status field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) WithStatus(value *ResourceClaimStatusApplyConfiguration) *ResourceClaimApplyConfiguration {
|
||||||
|
b.Status = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||||
|
func (b *ResourceClaimApplyConfiguration) GetName() *string {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
return b.ObjectMetaApplyConfiguration.Name
|
||||||
|
}
|
@ -0,0 +1,70 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimConsumerReferenceApplyConfiguration represents a declarative configuration of the ResourceClaimConsumerReference type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimConsumerReferenceApplyConfiguration struct {
|
||||||
|
APIGroup *string `json:"apiGroup,omitempty"`
|
||||||
|
Resource *string `json:"resource,omitempty"`
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
UID *types.UID `json:"uid,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimConsumerReferenceApplyConfiguration constructs a declarative configuration of the ResourceClaimConsumerReference type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaimConsumerReference() *ResourceClaimConsumerReferenceApplyConfiguration {
|
||||||
|
return &ResourceClaimConsumerReferenceApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAPIGroup sets the APIGroup field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the APIGroup field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimConsumerReferenceApplyConfiguration) WithAPIGroup(value string) *ResourceClaimConsumerReferenceApplyConfiguration {
|
||||||
|
b.APIGroup = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResource sets the Resource field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Resource field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimConsumerReferenceApplyConfiguration) WithResource(value string) *ResourceClaimConsumerReferenceApplyConfiguration {
|
||||||
|
b.Resource = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimConsumerReferenceApplyConfiguration) WithName(value string) *ResourceClaimConsumerReferenceApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimConsumerReferenceApplyConfiguration) WithUID(value types.UID) *ResourceClaimConsumerReferenceApplyConfiguration {
|
||||||
|
b.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
39
applyconfigurations/resource/v1beta2/resourceclaimspec.go
Normal file
39
applyconfigurations/resource/v1beta2/resourceclaimspec.go
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// ResourceClaimSpecApplyConfiguration represents a declarative configuration of the ResourceClaimSpec type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimSpecApplyConfiguration struct {
|
||||||
|
Devices *DeviceClaimApplyConfiguration `json:"devices,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimSpecApplyConfiguration constructs a declarative configuration of the ResourceClaimSpec type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaimSpec() *ResourceClaimSpecApplyConfiguration {
|
||||||
|
return &ResourceClaimSpecApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevices sets the Devices field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Devices field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimSpecApplyConfiguration) WithDevices(value *DeviceClaimApplyConfiguration) *ResourceClaimSpecApplyConfiguration {
|
||||||
|
b.Devices = value
|
||||||
|
return b
|
||||||
|
}
|
67
applyconfigurations/resource/v1beta2/resourceclaimstatus.go
Normal file
67
applyconfigurations/resource/v1beta2/resourceclaimstatus.go
Normal file
@ -0,0 +1,67 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// ResourceClaimStatusApplyConfiguration represents a declarative configuration of the ResourceClaimStatus type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimStatusApplyConfiguration struct {
|
||||||
|
Allocation *AllocationResultApplyConfiguration `json:"allocation,omitempty"`
|
||||||
|
ReservedFor []ResourceClaimConsumerReferenceApplyConfiguration `json:"reservedFor,omitempty"`
|
||||||
|
Devices []AllocatedDeviceStatusApplyConfiguration `json:"devices,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimStatusApplyConfiguration constructs a declarative configuration of the ResourceClaimStatus type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaimStatus() *ResourceClaimStatusApplyConfiguration {
|
||||||
|
return &ResourceClaimStatusApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAllocation sets the Allocation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Allocation field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimStatusApplyConfiguration) WithAllocation(value *AllocationResultApplyConfiguration) *ResourceClaimStatusApplyConfiguration {
|
||||||
|
b.Allocation = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithReservedFor adds the given value to the ReservedFor field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the ReservedFor field.
|
||||||
|
func (b *ResourceClaimStatusApplyConfiguration) WithReservedFor(values ...*ResourceClaimConsumerReferenceApplyConfiguration) *ResourceClaimStatusApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithReservedFor")
|
||||||
|
}
|
||||||
|
b.ReservedFor = append(b.ReservedFor, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevices adds the given value to the Devices field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Devices field.
|
||||||
|
func (b *ResourceClaimStatusApplyConfiguration) WithDevices(values ...*AllocatedDeviceStatusApplyConfiguration) *ResourceClaimStatusApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithDevices")
|
||||||
|
}
|
||||||
|
b.Devices = append(b.Devices, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
255
applyconfigurations/resource/v1beta2/resourceclaimtemplate.go
Normal file
255
applyconfigurations/resource/v1beta2/resourceclaimtemplate.go
Normal file
@ -0,0 +1,255 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||||
|
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimTemplateApplyConfiguration represents a declarative configuration of the ResourceClaimTemplate type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimTemplateApplyConfiguration struct {
|
||||||
|
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||||
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
|
Spec *ResourceClaimTemplateSpecApplyConfiguration `json:"spec,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplate constructs a declarative configuration of the ResourceClaimTemplate type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaimTemplate(name, namespace string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b := &ResourceClaimTemplateApplyConfiguration{}
|
||||||
|
b.WithName(name)
|
||||||
|
b.WithNamespace(namespace)
|
||||||
|
b.WithKind("ResourceClaimTemplate")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceClaimTemplate extracts the applied configuration owned by fieldManager from
|
||||||
|
// resourceClaimTemplate. If no managedFields are found in resourceClaimTemplate for fieldManager, a
|
||||||
|
// ResourceClaimTemplateApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||||
|
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||||
|
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||||
|
// the fieldManager never owned fields any fields.
|
||||||
|
// resourceClaimTemplate must be a unmodified ResourceClaimTemplate API object that was retrieved from the Kubernetes API.
|
||||||
|
// ExtractResourceClaimTemplate provides a way to perform a extract/modify-in-place/apply workflow.
|
||||||
|
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||||
|
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceClaimTemplate(resourceClaimTemplate *resourcev1beta2.ResourceClaimTemplate, fieldManager string) (*ResourceClaimTemplateApplyConfiguration, error) {
|
||||||
|
return extractResourceClaimTemplate(resourceClaimTemplate, fieldManager, "")
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceClaimTemplateStatus is the same as ExtractResourceClaimTemplate except
|
||||||
|
// that it extracts the status subresource applied configuration.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceClaimTemplateStatus(resourceClaimTemplate *resourcev1beta2.ResourceClaimTemplate, fieldManager string) (*ResourceClaimTemplateApplyConfiguration, error) {
|
||||||
|
return extractResourceClaimTemplate(resourceClaimTemplate, fieldManager, "status")
|
||||||
|
}
|
||||||
|
|
||||||
|
func extractResourceClaimTemplate(resourceClaimTemplate *resourcev1beta2.ResourceClaimTemplate, fieldManager string, subresource string) (*ResourceClaimTemplateApplyConfiguration, error) {
|
||||||
|
b := &ResourceClaimTemplateApplyConfiguration{}
|
||||||
|
err := managedfields.ExtractInto(resourceClaimTemplate, internal.Parser().Type("io.k8s.api.resource.v1beta2.ResourceClaimTemplate"), fieldManager, b, subresource)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
b.WithName(resourceClaimTemplate.Name)
|
||||||
|
b.WithNamespace(resourceClaimTemplate.Namespace)
|
||||||
|
|
||||||
|
b.WithKind("ResourceClaimTemplate")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKind sets the Kind field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Kind field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithKind(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.Kind = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the APIVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithAPIVersion(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithName(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithGenerateName(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithNamespace(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithUID(value types.UID) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithResourceVersion(value string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithGeneration(value int64) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||||
|
// overwriting an existing map entries in Labels field with the same key.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithLabels(entries map[string]string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||||
|
// overwriting an existing map entries in Annotations field with the same key.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithAnnotations(entries map[string]string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithOwnerReferences")
|
||||||
|
}
|
||||||
|
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithFinalizers(values ...string) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||||
|
if b.ObjectMetaApplyConfiguration == nil {
|
||||||
|
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Spec field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) WithSpec(value *ResourceClaimTemplateSpecApplyConfiguration) *ResourceClaimTemplateApplyConfiguration {
|
||||||
|
b.Spec = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||||
|
func (b *ResourceClaimTemplateApplyConfiguration) GetName() *string {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
return b.ObjectMetaApplyConfiguration.Name
|
||||||
|
}
|
@ -0,0 +1,194 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimTemplateSpecApplyConfiguration represents a declarative configuration of the ResourceClaimTemplateSpec type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceClaimTemplateSpecApplyConfiguration struct {
|
||||||
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
|
Spec *ResourceClaimSpecApplyConfiguration `json:"spec,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplateSpecApplyConfiguration constructs a declarative configuration of the ResourceClaimTemplateSpec type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceClaimTemplateSpec() *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
return &ResourceClaimTemplateSpecApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithName(value string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithGenerateName(value string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithNamespace(value string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithUID(value types.UID) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithResourceVersion(value string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithGeneration(value int64) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||||
|
// overwriting an existing map entries in Labels field with the same key.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithLabels(entries map[string]string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||||
|
// overwriting an existing map entries in Annotations field with the same key.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithAnnotations(entries map[string]string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithOwnerReferences")
|
||||||
|
}
|
||||||
|
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithFinalizers(values ...string) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||||
|
if b.ObjectMetaApplyConfiguration == nil {
|
||||||
|
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Spec field is set to the value of the last call.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) WithSpec(value *ResourceClaimSpecApplyConfiguration) *ResourceClaimTemplateSpecApplyConfiguration {
|
||||||
|
b.Spec = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||||
|
func (b *ResourceClaimTemplateSpecApplyConfiguration) GetName() *string {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
return b.ObjectMetaApplyConfiguration.Name
|
||||||
|
}
|
57
applyconfigurations/resource/v1beta2/resourcepool.go
Normal file
57
applyconfigurations/resource/v1beta2/resourcepool.go
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// ResourcePoolApplyConfiguration represents a declarative configuration of the ResourcePool type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourcePoolApplyConfiguration struct {
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
Generation *int64 `json:"generation,omitempty"`
|
||||||
|
ResourceSliceCount *int64 `json:"resourceSliceCount,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourcePoolApplyConfiguration constructs a declarative configuration of the ResourcePool type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourcePool() *ResourcePoolApplyConfiguration {
|
||||||
|
return &ResourcePoolApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourcePoolApplyConfiguration) WithName(value string) *ResourcePoolApplyConfiguration {
|
||||||
|
b.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *ResourcePoolApplyConfiguration) WithGeneration(value int64) *ResourcePoolApplyConfiguration {
|
||||||
|
b.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceSliceCount sets the ResourceSliceCount field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceSliceCount field is set to the value of the last call.
|
||||||
|
func (b *ResourcePoolApplyConfiguration) WithResourceSliceCount(value int64) *ResourcePoolApplyConfiguration {
|
||||||
|
b.ResourceSliceCount = &value
|
||||||
|
return b
|
||||||
|
}
|
253
applyconfigurations/resource/v1beta2/resourceslice.go
Normal file
253
applyconfigurations/resource/v1beta2/resourceslice.go
Normal file
@ -0,0 +1,253 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||||
|
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceSliceApplyConfiguration represents a declarative configuration of the ResourceSlice type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceSliceApplyConfiguration struct {
|
||||||
|
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||||
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
|
Spec *ResourceSliceSpecApplyConfiguration `json:"spec,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceSlice constructs a declarative configuration of the ResourceSlice type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceSlice(name string) *ResourceSliceApplyConfiguration {
|
||||||
|
b := &ResourceSliceApplyConfiguration{}
|
||||||
|
b.WithName(name)
|
||||||
|
b.WithKind("ResourceSlice")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceSlice extracts the applied configuration owned by fieldManager from
|
||||||
|
// resourceSlice. If no managedFields are found in resourceSlice for fieldManager, a
|
||||||
|
// ResourceSliceApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||||
|
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||||
|
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||||
|
// the fieldManager never owned fields any fields.
|
||||||
|
// resourceSlice must be a unmodified ResourceSlice API object that was retrieved from the Kubernetes API.
|
||||||
|
// ExtractResourceSlice provides a way to perform a extract/modify-in-place/apply workflow.
|
||||||
|
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||||
|
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceSlice(resourceSlice *resourcev1beta2.ResourceSlice, fieldManager string) (*ResourceSliceApplyConfiguration, error) {
|
||||||
|
return extractResourceSlice(resourceSlice, fieldManager, "")
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExtractResourceSliceStatus is the same as ExtractResourceSlice except
|
||||||
|
// that it extracts the status subresource applied configuration.
|
||||||
|
// Experimental!
|
||||||
|
func ExtractResourceSliceStatus(resourceSlice *resourcev1beta2.ResourceSlice, fieldManager string) (*ResourceSliceApplyConfiguration, error) {
|
||||||
|
return extractResourceSlice(resourceSlice, fieldManager, "status")
|
||||||
|
}
|
||||||
|
|
||||||
|
func extractResourceSlice(resourceSlice *resourcev1beta2.ResourceSlice, fieldManager string, subresource string) (*ResourceSliceApplyConfiguration, error) {
|
||||||
|
b := &ResourceSliceApplyConfiguration{}
|
||||||
|
err := managedfields.ExtractInto(resourceSlice, internal.Parser().Type("io.k8s.api.resource.v1beta2.ResourceSlice"), fieldManager, b, subresource)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
b.WithName(resourceSlice.Name)
|
||||||
|
|
||||||
|
b.WithKind("ResourceSlice")
|
||||||
|
b.WithAPIVersion("resource.k8s.io/v1beta2")
|
||||||
|
return b, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithKind sets the Kind field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Kind field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithKind(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.Kind = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the APIVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithAPIVersion(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithName sets the Name field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Name field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithName(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Name = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithGenerateName(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithNamespace(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithUID sets the UID field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the UID field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithUID(value types.UID) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.UID = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithResourceVersion(value string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Generation field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithGeneration(value int64) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||||
|
// overwriting an existing map entries in Labels field with the same key.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithLabels(entries map[string]string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||||
|
// overwriting an existing map entries in Annotations field with the same key.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithAnnotations(entries map[string]string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||||
|
}
|
||||||
|
for k, v := range entries {
|
||||||
|
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithOwnerReferences")
|
||||||
|
}
|
||||||
|
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithFinalizers(values ...string) *ResourceSliceApplyConfiguration {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
for i := range values {
|
||||||
|
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
func (b *ResourceSliceApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||||
|
if b.ObjectMetaApplyConfiguration == nil {
|
||||||
|
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Spec field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) WithSpec(value *ResourceSliceSpecApplyConfiguration) *ResourceSliceApplyConfiguration {
|
||||||
|
b.Spec = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||||
|
func (b *ResourceSliceApplyConfiguration) GetName() *string {
|
||||||
|
b.ensureObjectMetaApplyConfigurationExists()
|
||||||
|
return b.ObjectMetaApplyConfiguration.Name
|
||||||
|
}
|
116
applyconfigurations/resource/v1beta2/resourceslicespec.go
Normal file
116
applyconfigurations/resource/v1beta2/resourceslicespec.go
Normal file
@ -0,0 +1,116 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceSliceSpecApplyConfiguration represents a declarative configuration of the ResourceSliceSpec type for use
|
||||||
|
// with apply.
|
||||||
|
type ResourceSliceSpecApplyConfiguration struct {
|
||||||
|
Driver *string `json:"driver,omitempty"`
|
||||||
|
Pool *ResourcePoolApplyConfiguration `json:"pool,omitempty"`
|
||||||
|
NodeName *string `json:"nodeName,omitempty"`
|
||||||
|
NodeSelector *v1.NodeSelectorApplyConfiguration `json:"nodeSelector,omitempty"`
|
||||||
|
AllNodes *bool `json:"allNodes,omitempty"`
|
||||||
|
Devices []DeviceApplyConfiguration `json:"devices,omitempty"`
|
||||||
|
PerDeviceNodeSelection *bool `json:"perDeviceNodeSelection,omitempty"`
|
||||||
|
SharedCounters []CounterSetApplyConfiguration `json:"sharedCounters,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceSliceSpecApplyConfiguration constructs a declarative configuration of the ResourceSliceSpec type for use with
|
||||||
|
// apply.
|
||||||
|
func ResourceSliceSpec() *ResourceSliceSpecApplyConfiguration {
|
||||||
|
return &ResourceSliceSpecApplyConfiguration{}
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDriver sets the Driver field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Driver field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithDriver(value string) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.Driver = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithPool sets the Pool field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Pool field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithPool(value *ResourcePoolApplyConfiguration) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.Pool = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNodeName sets the NodeName field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NodeName field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithNodeName(value string) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.NodeName = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithNodeSelector sets the NodeSelector field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the NodeSelector field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithNodeSelector(value *v1.NodeSelectorApplyConfiguration) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.NodeSelector = value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithAllNodes sets the AllNodes field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the AllNodes field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithAllNodes(value bool) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.AllNodes = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithDevices adds the given value to the Devices field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the Devices field.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithDevices(values ...*DeviceApplyConfiguration) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithDevices")
|
||||||
|
}
|
||||||
|
b.Devices = append(b.Devices, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithPerDeviceNodeSelection sets the PerDeviceNodeSelection field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the PerDeviceNodeSelection field is set to the value of the last call.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithPerDeviceNodeSelection(value bool) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
b.PerDeviceNodeSelection = &value
|
||||||
|
return b
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithSharedCounters adds the given value to the SharedCounters field in the declarative configuration
|
||||||
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
|
// If called multiple times, values provided by each call will be appended to the SharedCounters field.
|
||||||
|
func (b *ResourceSliceSpecApplyConfiguration) WithSharedCounters(values ...*CounterSetApplyConfiguration) *ResourceSliceSpecApplyConfiguration {
|
||||||
|
for i := range values {
|
||||||
|
if values[i] == nil {
|
||||||
|
panic("nil value passed to WithSharedCounters")
|
||||||
|
}
|
||||||
|
b.SharedCounters = append(b.SharedCounters, *values[i])
|
||||||
|
}
|
||||||
|
return b
|
||||||
|
}
|
@ -62,6 +62,7 @@ import (
|
|||||||
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
||||||
v1alpha3 "k8s.io/api/resource/v1alpha3"
|
v1alpha3 "k8s.io/api/resource/v1alpha3"
|
||||||
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
schedulingv1 "k8s.io/api/scheduling/v1"
|
schedulingv1 "k8s.io/api/scheduling/v1"
|
||||||
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
||||||
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
||||||
@ -117,6 +118,7 @@ import (
|
|||||||
applyconfigurationsrbacv1beta1 "k8s.io/client-go/applyconfigurations/rbac/v1beta1"
|
applyconfigurationsrbacv1beta1 "k8s.io/client-go/applyconfigurations/rbac/v1beta1"
|
||||||
resourcev1alpha3 "k8s.io/client-go/applyconfigurations/resource/v1alpha3"
|
resourcev1alpha3 "k8s.io/client-go/applyconfigurations/resource/v1alpha3"
|
||||||
applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1"
|
applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1"
|
||||||
|
applyconfigurationsresourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
applyconfigurationsschedulingv1 "k8s.io/client-go/applyconfigurations/scheduling/v1"
|
applyconfigurationsschedulingv1 "k8s.io/client-go/applyconfigurations/scheduling/v1"
|
||||||
applyconfigurationsschedulingv1alpha1 "k8s.io/client-go/applyconfigurations/scheduling/v1alpha1"
|
applyconfigurationsschedulingv1alpha1 "k8s.io/client-go/applyconfigurations/scheduling/v1alpha1"
|
||||||
applyconfigurationsschedulingv1beta1 "k8s.io/client-go/applyconfigurations/scheduling/v1beta1"
|
applyconfigurationsschedulingv1beta1 "k8s.io/client-go/applyconfigurations/scheduling/v1beta1"
|
||||||
@ -1759,6 +1761,80 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
|
|||||||
case resourcev1beta1.SchemeGroupVersion.WithKind("ResourceSliceSpec"):
|
case resourcev1beta1.SchemeGroupVersion.WithKind("ResourceSliceSpec"):
|
||||||
return &applyconfigurationsresourcev1beta1.ResourceSliceSpecApplyConfiguration{}
|
return &applyconfigurationsresourcev1beta1.ResourceSliceSpecApplyConfiguration{}
|
||||||
|
|
||||||
|
// Group=resource.k8s.io, Version=v1beta2
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("AllocatedDeviceStatus"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.AllocatedDeviceStatusApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("AllocationResult"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.AllocationResultApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("CELDeviceSelector"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.CELDeviceSelectorApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("Counter"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.CounterApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("CounterSet"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.CounterSetApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("Device"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceAllocationConfiguration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceAllocationConfigurationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceAllocationResult"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceAllocationResultApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceAttribute"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceAttributeApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceCapacity"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceCapacityApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceClaim"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceClaimApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceClaimConfiguration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceClaimConfigurationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceClass"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceClassApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceClassConfiguration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceClassConfigurationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceClassSpec"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceClassSpecApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceConfiguration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceConfigurationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceConstraint"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceConstraintApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceCounterConsumption"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceCounterConsumptionApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceRequest"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceRequestApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceRequestAllocationResult"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceRequestAllocationResultApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceSelector"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceSelectorApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceSubRequest"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceSubRequestApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceTaint"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceTaintApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("DeviceToleration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.DeviceTolerationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ExactDeviceRequest"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ExactDeviceRequestApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("NetworkDeviceData"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.NetworkDeviceDataApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("OpaqueDeviceConfiguration"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.OpaqueDeviceConfigurationApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaim"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaimConsumerReference"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimConsumerReferenceApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaimSpec"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimSpecApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaimStatus"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimStatusApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaimTemplate"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimTemplateApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceClaimTemplateSpec"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceClaimTemplateSpecApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourcePool"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourcePoolApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceSlice"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceSliceApplyConfiguration{}
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithKind("ResourceSliceSpec"):
|
||||||
|
return &applyconfigurationsresourcev1beta2.ResourceSliceSpecApplyConfiguration{}
|
||||||
|
|
||||||
// Group=scheduling.k8s.io, Version=v1
|
// Group=scheduling.k8s.io, Version=v1
|
||||||
case schedulingv1.SchemeGroupVersion.WithKind("PriorityClass"):
|
case schedulingv1.SchemeGroupVersion.WithKind("PriorityClass"):
|
||||||
return &applyconfigurationsschedulingv1.PriorityClassApplyConfiguration{}
|
return &applyconfigurationsschedulingv1.PriorityClassApplyConfiguration{}
|
||||||
|
@ -63,6 +63,7 @@ import (
|
|||||||
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
||||||
v1alpha3 "k8s.io/api/resource/v1alpha3"
|
v1alpha3 "k8s.io/api/resource/v1alpha3"
|
||||||
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
schedulingv1 "k8s.io/api/scheduling/v1"
|
schedulingv1 "k8s.io/api/scheduling/v1"
|
||||||
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
||||||
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
||||||
@ -406,6 +407,16 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
|
|||||||
case resourcev1beta1.SchemeGroupVersion.WithResource("resourceslices"):
|
case resourcev1beta1.SchemeGroupVersion.WithResource("resourceslices"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().ResourceSlices().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().ResourceSlices().Informer()}, nil
|
||||||
|
|
||||||
|
// Group=resource.k8s.io, Version=v1beta2
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithResource("deviceclasses"):
|
||||||
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta2().DeviceClasses().Informer()}, nil
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithResource("resourceclaims"):
|
||||||
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta2().ResourceClaims().Informer()}, nil
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithResource("resourceclaimtemplates"):
|
||||||
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta2().ResourceClaimTemplates().Informer()}, nil
|
||||||
|
case resourcev1beta2.SchemeGroupVersion.WithResource("resourceslices"):
|
||||||
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta2().ResourceSlices().Informer()}, nil
|
||||||
|
|
||||||
// Group=scheduling.k8s.io, Version=v1
|
// Group=scheduling.k8s.io, Version=v1
|
||||||
case schedulingv1.SchemeGroupVersion.WithResource("priorityclasses"):
|
case schedulingv1.SchemeGroupVersion.WithResource("priorityclasses"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Scheduling().V1().PriorityClasses().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Scheduling().V1().PriorityClasses().Informer()}, nil
|
||||||
|
@ -22,6 +22,7 @@ import (
|
|||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
v1alpha3 "k8s.io/client-go/informers/resource/v1alpha3"
|
v1alpha3 "k8s.io/client-go/informers/resource/v1alpha3"
|
||||||
v1beta1 "k8s.io/client-go/informers/resource/v1beta1"
|
v1beta1 "k8s.io/client-go/informers/resource/v1beta1"
|
||||||
|
v1beta2 "k8s.io/client-go/informers/resource/v1beta2"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Interface provides access to each of this group's versions.
|
// Interface provides access to each of this group's versions.
|
||||||
@ -30,6 +31,8 @@ type Interface interface {
|
|||||||
V1alpha3() v1alpha3.Interface
|
V1alpha3() v1alpha3.Interface
|
||||||
// V1beta1 provides access to shared informers for resources in V1beta1.
|
// V1beta1 provides access to shared informers for resources in V1beta1.
|
||||||
V1beta1() v1beta1.Interface
|
V1beta1() v1beta1.Interface
|
||||||
|
// V1beta2 provides access to shared informers for resources in V1beta2.
|
||||||
|
V1beta2() v1beta2.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
type group struct {
|
type group struct {
|
||||||
@ -52,3 +55,8 @@ func (g *group) V1alpha3() v1alpha3.Interface {
|
|||||||
func (g *group) V1beta1() v1beta1.Interface {
|
func (g *group) V1beta1() v1beta1.Interface {
|
||||||
return v1beta1.New(g.factory, g.namespace, g.tweakListOptions)
|
return v1beta1.New(g.factory, g.namespace, g.tweakListOptions)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// V1beta2 returns a new v1beta2.Interface.
|
||||||
|
func (g *group) V1beta2() v1beta2.Interface {
|
||||||
|
return v1beta2.New(g.factory, g.namespace, g.tweakListOptions)
|
||||||
|
}
|
||||||
|
101
informers/resource/v1beta2/deviceclass.go
Normal file
101
informers/resource/v1beta2/deviceclass.go
Normal file
@ -0,0 +1,101 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
time "time"
|
||||||
|
|
||||||
|
apiresourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
|
kubernetes "k8s.io/client-go/kubernetes"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/listers/resource/v1beta2"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceClassInformer provides access to a shared informer and lister for
|
||||||
|
// DeviceClasses.
|
||||||
|
type DeviceClassInformer interface {
|
||||||
|
Informer() cache.SharedIndexInformer
|
||||||
|
Lister() resourcev1beta2.DeviceClassLister
|
||||||
|
}
|
||||||
|
|
||||||
|
type deviceClassInformer struct {
|
||||||
|
factory internalinterfaces.SharedInformerFactory
|
||||||
|
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewDeviceClassInformer constructs a new informer for DeviceClass type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewDeviceClassInformer(client kubernetes.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredDeviceClassInformer(client, resyncPeriod, indexers, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewFilteredDeviceClassInformer constructs a new informer for DeviceClass type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewFilteredDeviceClassInformer(client kubernetes.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||||
|
return cache.NewSharedIndexInformer(
|
||||||
|
&cache.ListWatch{
|
||||||
|
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().DeviceClasses().List(context.Background(), options)
|
||||||
|
},
|
||||||
|
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().DeviceClasses().Watch(context.Background(), options)
|
||||||
|
},
|
||||||
|
ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().DeviceClasses().List(ctx, options)
|
||||||
|
},
|
||||||
|
WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().DeviceClasses().Watch(ctx, options)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
&apiresourcev1beta2.DeviceClass{},
|
||||||
|
resyncPeriod,
|
||||||
|
indexers,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *deviceClassInformer) defaultInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredDeviceClassInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *deviceClassInformer) Informer() cache.SharedIndexInformer {
|
||||||
|
return f.factory.InformerFor(&apiresourcev1beta2.DeviceClass{}, f.defaultInformer)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *deviceClassInformer) Lister() resourcev1beta2.DeviceClassLister {
|
||||||
|
return resourcev1beta2.NewDeviceClassLister(f.Informer().GetIndexer())
|
||||||
|
}
|
66
informers/resource/v1beta2/interface.go
Normal file
66
informers/resource/v1beta2/interface.go
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
|
)
|
||||||
|
|
||||||
|
// Interface provides access to all the informers in this group version.
|
||||||
|
type Interface interface {
|
||||||
|
// DeviceClasses returns a DeviceClassInformer.
|
||||||
|
DeviceClasses() DeviceClassInformer
|
||||||
|
// ResourceClaims returns a ResourceClaimInformer.
|
||||||
|
ResourceClaims() ResourceClaimInformer
|
||||||
|
// ResourceClaimTemplates returns a ResourceClaimTemplateInformer.
|
||||||
|
ResourceClaimTemplates() ResourceClaimTemplateInformer
|
||||||
|
// ResourceSlices returns a ResourceSliceInformer.
|
||||||
|
ResourceSlices() ResourceSliceInformer
|
||||||
|
}
|
||||||
|
|
||||||
|
type version struct {
|
||||||
|
factory internalinterfaces.SharedInformerFactory
|
||||||
|
namespace string
|
||||||
|
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||||
|
}
|
||||||
|
|
||||||
|
// New returns a new Interface.
|
||||||
|
func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakListOptions internalinterfaces.TweakListOptionsFunc) Interface {
|
||||||
|
return &version{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClasses returns a DeviceClassInformer.
|
||||||
|
func (v *version) DeviceClasses() DeviceClassInformer {
|
||||||
|
return &deviceClassInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaims returns a ResourceClaimInformer.
|
||||||
|
func (v *version) ResourceClaims() ResourceClaimInformer {
|
||||||
|
return &resourceClaimInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplates returns a ResourceClaimTemplateInformer.
|
||||||
|
func (v *version) ResourceClaimTemplates() ResourceClaimTemplateInformer {
|
||||||
|
return &resourceClaimTemplateInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceSlices returns a ResourceSliceInformer.
|
||||||
|
func (v *version) ResourceSlices() ResourceSliceInformer {
|
||||||
|
return &resourceSliceInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
|
||||||
|
}
|
102
informers/resource/v1beta2/resourceclaim.go
Normal file
102
informers/resource/v1beta2/resourceclaim.go
Normal file
@ -0,0 +1,102 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
time "time"
|
||||||
|
|
||||||
|
apiresourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
|
kubernetes "k8s.io/client-go/kubernetes"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/listers/resource/v1beta2"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimInformer provides access to a shared informer and lister for
|
||||||
|
// ResourceClaims.
|
||||||
|
type ResourceClaimInformer interface {
|
||||||
|
Informer() cache.SharedIndexInformer
|
||||||
|
Lister() resourcev1beta2.ResourceClaimLister
|
||||||
|
}
|
||||||
|
|
||||||
|
type resourceClaimInformer struct {
|
||||||
|
factory internalinterfaces.SharedInformerFactory
|
||||||
|
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||||
|
namespace string
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceClaimInformer constructs a new informer for ResourceClaim type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewResourceClaimInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceClaimInformer(client, namespace, resyncPeriod, indexers, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewFilteredResourceClaimInformer constructs a new informer for ResourceClaim type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewFilteredResourceClaimInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||||
|
return cache.NewSharedIndexInformer(
|
||||||
|
&cache.ListWatch{
|
||||||
|
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaims(namespace).List(context.Background(), options)
|
||||||
|
},
|
||||||
|
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaims(namespace).Watch(context.Background(), options)
|
||||||
|
},
|
||||||
|
ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaims(namespace).List(ctx, options)
|
||||||
|
},
|
||||||
|
WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaims(namespace).Watch(ctx, options)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
&apiresourcev1beta2.ResourceClaim{},
|
||||||
|
resyncPeriod,
|
||||||
|
indexers,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimInformer) defaultInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceClaimInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimInformer) Informer() cache.SharedIndexInformer {
|
||||||
|
return f.factory.InformerFor(&apiresourcev1beta2.ResourceClaim{}, f.defaultInformer)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimInformer) Lister() resourcev1beta2.ResourceClaimLister {
|
||||||
|
return resourcev1beta2.NewResourceClaimLister(f.Informer().GetIndexer())
|
||||||
|
}
|
102
informers/resource/v1beta2/resourceclaimtemplate.go
Normal file
102
informers/resource/v1beta2/resourceclaimtemplate.go
Normal file
@ -0,0 +1,102 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
time "time"
|
||||||
|
|
||||||
|
apiresourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
|
kubernetes "k8s.io/client-go/kubernetes"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/listers/resource/v1beta2"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimTemplateInformer provides access to a shared informer and lister for
|
||||||
|
// ResourceClaimTemplates.
|
||||||
|
type ResourceClaimTemplateInformer interface {
|
||||||
|
Informer() cache.SharedIndexInformer
|
||||||
|
Lister() resourcev1beta2.ResourceClaimTemplateLister
|
||||||
|
}
|
||||||
|
|
||||||
|
type resourceClaimTemplateInformer struct {
|
||||||
|
factory internalinterfaces.SharedInformerFactory
|
||||||
|
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||||
|
namespace string
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceClaimTemplateInformer constructs a new informer for ResourceClaimTemplate type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewResourceClaimTemplateInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceClaimTemplateInformer(client, namespace, resyncPeriod, indexers, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewFilteredResourceClaimTemplateInformer constructs a new informer for ResourceClaimTemplate type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewFilteredResourceClaimTemplateInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||||
|
return cache.NewSharedIndexInformer(
|
||||||
|
&cache.ListWatch{
|
||||||
|
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaimTemplates(namespace).List(context.Background(), options)
|
||||||
|
},
|
||||||
|
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaimTemplates(namespace).Watch(context.Background(), options)
|
||||||
|
},
|
||||||
|
ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaimTemplates(namespace).List(ctx, options)
|
||||||
|
},
|
||||||
|
WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceClaimTemplates(namespace).Watch(ctx, options)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
&apiresourcev1beta2.ResourceClaimTemplate{},
|
||||||
|
resyncPeriod,
|
||||||
|
indexers,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimTemplateInformer) defaultInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceClaimTemplateInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimTemplateInformer) Informer() cache.SharedIndexInformer {
|
||||||
|
return f.factory.InformerFor(&apiresourcev1beta2.ResourceClaimTemplate{}, f.defaultInformer)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceClaimTemplateInformer) Lister() resourcev1beta2.ResourceClaimTemplateLister {
|
||||||
|
return resourcev1beta2.NewResourceClaimTemplateLister(f.Informer().GetIndexer())
|
||||||
|
}
|
101
informers/resource/v1beta2/resourceslice.go
Normal file
101
informers/resource/v1beta2/resourceslice.go
Normal file
@ -0,0 +1,101 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
time "time"
|
||||||
|
|
||||||
|
apiresourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
|
kubernetes "k8s.io/client-go/kubernetes"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/listers/resource/v1beta2"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceSliceInformer provides access to a shared informer and lister for
|
||||||
|
// ResourceSlices.
|
||||||
|
type ResourceSliceInformer interface {
|
||||||
|
Informer() cache.SharedIndexInformer
|
||||||
|
Lister() resourcev1beta2.ResourceSliceLister
|
||||||
|
}
|
||||||
|
|
||||||
|
type resourceSliceInformer struct {
|
||||||
|
factory internalinterfaces.SharedInformerFactory
|
||||||
|
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceSliceInformer constructs a new informer for ResourceSlice type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewResourceSliceInformer(client kubernetes.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceSliceInformer(client, resyncPeriod, indexers, nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewFilteredResourceSliceInformer constructs a new informer for ResourceSlice type.
|
||||||
|
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||||
|
// one. This reduces memory footprint and number of connections to the server.
|
||||||
|
func NewFilteredResourceSliceInformer(client kubernetes.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||||
|
return cache.NewSharedIndexInformer(
|
||||||
|
&cache.ListWatch{
|
||||||
|
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceSlices().List(context.Background(), options)
|
||||||
|
},
|
||||||
|
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceSlices().Watch(context.Background(), options)
|
||||||
|
},
|
||||||
|
ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceSlices().List(ctx, options)
|
||||||
|
},
|
||||||
|
WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
|
||||||
|
if tweakListOptions != nil {
|
||||||
|
tweakListOptions(&options)
|
||||||
|
}
|
||||||
|
return client.ResourceV1beta2().ResourceSlices().Watch(ctx, options)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
&apiresourcev1beta2.ResourceSlice{},
|
||||||
|
resyncPeriod,
|
||||||
|
indexers,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceSliceInformer) defaultInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
|
||||||
|
return NewFilteredResourceSliceInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceSliceInformer) Informer() cache.SharedIndexInformer {
|
||||||
|
return f.factory.InformerFor(&apiresourcev1beta2.ResourceSlice{}, f.defaultInformer)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (f *resourceSliceInformer) Lister() resourcev1beta2.ResourceSliceLister {
|
||||||
|
return resourcev1beta2.NewResourceSliceLister(f.Informer().GetIndexer())
|
||||||
|
}
|
@ -70,6 +70,7 @@ import (
|
|||||||
rbacv1beta1 "k8s.io/client-go/kubernetes/typed/rbac/v1beta1"
|
rbacv1beta1 "k8s.io/client-go/kubernetes/typed/rbac/v1beta1"
|
||||||
resourcev1alpha3 "k8s.io/client-go/kubernetes/typed/resource/v1alpha3"
|
resourcev1alpha3 "k8s.io/client-go/kubernetes/typed/resource/v1alpha3"
|
||||||
resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1"
|
resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
schedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1"
|
schedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1"
|
||||||
schedulingv1alpha1 "k8s.io/client-go/kubernetes/typed/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/client-go/kubernetes/typed/scheduling/v1alpha1"
|
||||||
schedulingv1beta1 "k8s.io/client-go/kubernetes/typed/scheduling/v1beta1"
|
schedulingv1beta1 "k8s.io/client-go/kubernetes/typed/scheduling/v1beta1"
|
||||||
@ -128,6 +129,7 @@ type Interface interface {
|
|||||||
RbacV1() rbacv1.RbacV1Interface
|
RbacV1() rbacv1.RbacV1Interface
|
||||||
RbacV1beta1() rbacv1beta1.RbacV1beta1Interface
|
RbacV1beta1() rbacv1beta1.RbacV1beta1Interface
|
||||||
RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface
|
RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface
|
||||||
|
ResourceV1beta2() resourcev1beta2.ResourceV1beta2Interface
|
||||||
ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface
|
ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface
|
||||||
ResourceV1alpha3() resourcev1alpha3.ResourceV1alpha3Interface
|
ResourceV1alpha3() resourcev1alpha3.ResourceV1alpha3Interface
|
||||||
SchedulingV1alpha1() schedulingv1alpha1.SchedulingV1alpha1Interface
|
SchedulingV1alpha1() schedulingv1alpha1.SchedulingV1alpha1Interface
|
||||||
@ -187,6 +189,7 @@ type Clientset struct {
|
|||||||
rbacV1 *rbacv1.RbacV1Client
|
rbacV1 *rbacv1.RbacV1Client
|
||||||
rbacV1beta1 *rbacv1beta1.RbacV1beta1Client
|
rbacV1beta1 *rbacv1beta1.RbacV1beta1Client
|
||||||
rbacV1alpha1 *rbacv1alpha1.RbacV1alpha1Client
|
rbacV1alpha1 *rbacv1alpha1.RbacV1alpha1Client
|
||||||
|
resourceV1beta2 *resourcev1beta2.ResourceV1beta2Client
|
||||||
resourceV1beta1 *resourcev1beta1.ResourceV1beta1Client
|
resourceV1beta1 *resourcev1beta1.ResourceV1beta1Client
|
||||||
resourceV1alpha3 *resourcev1alpha3.ResourceV1alpha3Client
|
resourceV1alpha3 *resourcev1alpha3.ResourceV1alpha3Client
|
||||||
schedulingV1alpha1 *schedulingv1alpha1.SchedulingV1alpha1Client
|
schedulingV1alpha1 *schedulingv1alpha1.SchedulingV1alpha1Client
|
||||||
@ -423,6 +426,11 @@ func (c *Clientset) RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface {
|
|||||||
return c.rbacV1alpha1
|
return c.rbacV1alpha1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ResourceV1beta2 retrieves the ResourceV1beta2Client
|
||||||
|
func (c *Clientset) ResourceV1beta2() resourcev1beta2.ResourceV1beta2Interface {
|
||||||
|
return c.resourceV1beta2
|
||||||
|
}
|
||||||
|
|
||||||
// ResourceV1beta1 retrieves the ResourceV1beta1Client
|
// ResourceV1beta1 retrieves the ResourceV1beta1Client
|
||||||
func (c *Clientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface {
|
func (c *Clientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface {
|
||||||
return c.resourceV1beta1
|
return c.resourceV1beta1
|
||||||
@ -692,6 +700,10 @@ func NewForConfigAndClient(c *rest.Config, httpClient *http.Client) (*Clientset,
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
cs.resourceV1beta2, err = resourcev1beta2.NewForConfigAndClient(&configShallowCopy, httpClient)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
cs.resourceV1beta1, err = resourcev1beta1.NewForConfigAndClient(&configShallowCopy, httpClient)
|
cs.resourceV1beta1, err = resourcev1beta1.NewForConfigAndClient(&configShallowCopy, httpClient)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -794,6 +806,7 @@ func New(c rest.Interface) *Clientset {
|
|||||||
cs.rbacV1 = rbacv1.New(c)
|
cs.rbacV1 = rbacv1.New(c)
|
||||||
cs.rbacV1beta1 = rbacv1beta1.New(c)
|
cs.rbacV1beta1 = rbacv1beta1.New(c)
|
||||||
cs.rbacV1alpha1 = rbacv1alpha1.New(c)
|
cs.rbacV1alpha1 = rbacv1alpha1.New(c)
|
||||||
|
cs.resourceV1beta2 = resourcev1beta2.New(c)
|
||||||
cs.resourceV1beta1 = resourcev1beta1.New(c)
|
cs.resourceV1beta1 = resourcev1beta1.New(c)
|
||||||
cs.resourceV1alpha3 = resourcev1alpha3.New(c)
|
cs.resourceV1alpha3 = resourcev1alpha3.New(c)
|
||||||
cs.schedulingV1alpha1 = schedulingv1alpha1.New(c)
|
cs.schedulingV1alpha1 = schedulingv1alpha1.New(c)
|
||||||
|
@ -120,6 +120,8 @@ import (
|
|||||||
fakeresourcev1alpha3 "k8s.io/client-go/kubernetes/typed/resource/v1alpha3/fake"
|
fakeresourcev1alpha3 "k8s.io/client-go/kubernetes/typed/resource/v1alpha3/fake"
|
||||||
resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1"
|
resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1"
|
||||||
fakeresourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1/fake"
|
fakeresourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1/fake"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
fakeresourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2/fake"
|
||||||
schedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1"
|
schedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1"
|
||||||
fakeschedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1/fake"
|
fakeschedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1/fake"
|
||||||
schedulingv1alpha1 "k8s.io/client-go/kubernetes/typed/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/client-go/kubernetes/typed/scheduling/v1alpha1"
|
||||||
@ -456,6 +458,11 @@ func (c *Clientset) RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface {
|
|||||||
return &fakerbacv1alpha1.FakeRbacV1alpha1{Fake: &c.Fake}
|
return &fakerbacv1alpha1.FakeRbacV1alpha1{Fake: &c.Fake}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ResourceV1beta2 retrieves the ResourceV1beta2Client
|
||||||
|
func (c *Clientset) ResourceV1beta2() resourcev1beta2.ResourceV1beta2Interface {
|
||||||
|
return &fakeresourcev1beta2.FakeResourceV1beta2{Fake: &c.Fake}
|
||||||
|
}
|
||||||
|
|
||||||
// ResourceV1beta1 retrieves the ResourceV1beta1Client
|
// ResourceV1beta1 retrieves the ResourceV1beta1Client
|
||||||
func (c *Clientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface {
|
func (c *Clientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface {
|
||||||
return &fakeresourcev1beta1.FakeResourceV1beta1{Fake: &c.Fake}
|
return &fakeresourcev1beta1.FakeResourceV1beta1{Fake: &c.Fake}
|
||||||
|
@ -66,6 +66,7 @@ import (
|
|||||||
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
||||||
resourcev1alpha3 "k8s.io/api/resource/v1alpha3"
|
resourcev1alpha3 "k8s.io/api/resource/v1alpha3"
|
||||||
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
schedulingv1 "k8s.io/api/scheduling/v1"
|
schedulingv1 "k8s.io/api/scheduling/v1"
|
||||||
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
||||||
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
||||||
@ -129,6 +130,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
rbacv1.AddToScheme,
|
rbacv1.AddToScheme,
|
||||||
rbacv1beta1.AddToScheme,
|
rbacv1beta1.AddToScheme,
|
||||||
rbacv1alpha1.AddToScheme,
|
rbacv1alpha1.AddToScheme,
|
||||||
|
resourcev1beta2.AddToScheme,
|
||||||
resourcev1beta1.AddToScheme,
|
resourcev1beta1.AddToScheme,
|
||||||
resourcev1alpha3.AddToScheme,
|
resourcev1alpha3.AddToScheme,
|
||||||
schedulingv1alpha1.AddToScheme,
|
schedulingv1alpha1.AddToScheme,
|
||||||
|
@ -66,6 +66,7 @@ import (
|
|||||||
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
rbacv1beta1 "k8s.io/api/rbac/v1beta1"
|
||||||
resourcev1alpha3 "k8s.io/api/resource/v1alpha3"
|
resourcev1alpha3 "k8s.io/api/resource/v1alpha3"
|
||||||
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
resourcev1beta1 "k8s.io/api/resource/v1beta1"
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
schedulingv1 "k8s.io/api/scheduling/v1"
|
schedulingv1 "k8s.io/api/scheduling/v1"
|
||||||
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1"
|
||||||
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
schedulingv1beta1 "k8s.io/api/scheduling/v1beta1"
|
||||||
@ -129,6 +130,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
rbacv1.AddToScheme,
|
rbacv1.AddToScheme,
|
||||||
rbacv1beta1.AddToScheme,
|
rbacv1beta1.AddToScheme,
|
||||||
rbacv1alpha1.AddToScheme,
|
rbacv1alpha1.AddToScheme,
|
||||||
|
resourcev1beta2.AddToScheme,
|
||||||
resourcev1beta1.AddToScheme,
|
resourcev1beta1.AddToScheme,
|
||||||
resourcev1alpha3.AddToScheme,
|
resourcev1alpha3.AddToScheme,
|
||||||
schedulingv1alpha1.AddToScheme,
|
schedulingv1alpha1.AddToScheme,
|
||||||
|
71
kubernetes/typed/resource/v1beta2/deviceclass.go
Normal file
71
kubernetes/typed/resource/v1beta2/deviceclass.go
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
applyconfigurationsresourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceClassesGetter has a method to return a DeviceClassInterface.
|
||||||
|
// A group's client should implement this interface.
|
||||||
|
type DeviceClassesGetter interface {
|
||||||
|
DeviceClasses() DeviceClassInterface
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeviceClassInterface has methods to work with DeviceClass resources.
|
||||||
|
type DeviceClassInterface interface {
|
||||||
|
Create(ctx context.Context, deviceClass *resourcev1beta2.DeviceClass, opts v1.CreateOptions) (*resourcev1beta2.DeviceClass, error)
|
||||||
|
Update(ctx context.Context, deviceClass *resourcev1beta2.DeviceClass, opts v1.UpdateOptions) (*resourcev1beta2.DeviceClass, error)
|
||||||
|
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||||
|
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||||
|
Get(ctx context.Context, name string, opts v1.GetOptions) (*resourcev1beta2.DeviceClass, error)
|
||||||
|
List(ctx context.Context, opts v1.ListOptions) (*resourcev1beta2.DeviceClassList, error)
|
||||||
|
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||||
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *resourcev1beta2.DeviceClass, err error)
|
||||||
|
Apply(ctx context.Context, deviceClass *applyconfigurationsresourcev1beta2.DeviceClassApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1beta2.DeviceClass, err error)
|
||||||
|
DeviceClassExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// deviceClasses implements DeviceClassInterface
|
||||||
|
type deviceClasses struct {
|
||||||
|
*gentype.ClientWithListAndApply[*resourcev1beta2.DeviceClass, *resourcev1beta2.DeviceClassList, *applyconfigurationsresourcev1beta2.DeviceClassApplyConfiguration]
|
||||||
|
}
|
||||||
|
|
||||||
|
// newDeviceClasses returns a DeviceClasses
|
||||||
|
func newDeviceClasses(c *ResourceV1beta2Client) *deviceClasses {
|
||||||
|
return &deviceClasses{
|
||||||
|
gentype.NewClientWithListAndApply[*resourcev1beta2.DeviceClass, *resourcev1beta2.DeviceClassList, *applyconfigurationsresourcev1beta2.DeviceClassApplyConfiguration](
|
||||||
|
"deviceclasses",
|
||||||
|
c.RESTClient(),
|
||||||
|
scheme.ParameterCodec,
|
||||||
|
"",
|
||||||
|
func() *resourcev1beta2.DeviceClass { return &resourcev1beta2.DeviceClass{} },
|
||||||
|
func() *resourcev1beta2.DeviceClassList { return &resourcev1beta2.DeviceClassList{} },
|
||||||
|
gentype.PrefersProtobuf[*resourcev1beta2.DeviceClass](),
|
||||||
|
),
|
||||||
|
}
|
||||||
|
}
|
20
kubernetes/typed/resource/v1beta2/doc.go
Normal file
20
kubernetes/typed/resource/v1beta2/doc.go
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
// This package has the automatically generated typed clients.
|
||||||
|
package v1beta2
|
20
kubernetes/typed/resource/v1beta2/fake/doc.go
Normal file
20
kubernetes/typed/resource/v1beta2/fake/doc.go
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
// Package fake has the automatically generated clients.
|
||||||
|
package fake
|
51
kubernetes/typed/resource/v1beta2/fake/fake_deviceclass.go
Normal file
51
kubernetes/typed/resource/v1beta2/fake/fake_deviceclass.go
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package fake
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
typedresourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// fakeDeviceClasses implements DeviceClassInterface
|
||||||
|
type fakeDeviceClasses struct {
|
||||||
|
*gentype.FakeClientWithListAndApply[*v1beta2.DeviceClass, *v1beta2.DeviceClassList, *resourcev1beta2.DeviceClassApplyConfiguration]
|
||||||
|
Fake *FakeResourceV1beta2
|
||||||
|
}
|
||||||
|
|
||||||
|
func newFakeDeviceClasses(fake *FakeResourceV1beta2) typedresourcev1beta2.DeviceClassInterface {
|
||||||
|
return &fakeDeviceClasses{
|
||||||
|
gentype.NewFakeClientWithListAndApply[*v1beta2.DeviceClass, *v1beta2.DeviceClassList, *resourcev1beta2.DeviceClassApplyConfiguration](
|
||||||
|
fake.Fake,
|
||||||
|
"",
|
||||||
|
v1beta2.SchemeGroupVersion.WithResource("deviceclasses"),
|
||||||
|
v1beta2.SchemeGroupVersion.WithKind("DeviceClass"),
|
||||||
|
func() *v1beta2.DeviceClass { return &v1beta2.DeviceClass{} },
|
||||||
|
func() *v1beta2.DeviceClassList { return &v1beta2.DeviceClassList{} },
|
||||||
|
func(dst, src *v1beta2.DeviceClassList) { dst.ListMeta = src.ListMeta },
|
||||||
|
func(list *v1beta2.DeviceClassList) []*v1beta2.DeviceClass { return gentype.ToPointerSlice(list.Items) },
|
||||||
|
func(list *v1beta2.DeviceClassList, items []*v1beta2.DeviceClass) {
|
||||||
|
list.Items = gentype.FromPointerSlice(items)
|
||||||
|
},
|
||||||
|
),
|
||||||
|
fake,
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,52 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package fake
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
rest "k8s.io/client-go/rest"
|
||||||
|
testing "k8s.io/client-go/testing"
|
||||||
|
)
|
||||||
|
|
||||||
|
type FakeResourceV1beta2 struct {
|
||||||
|
*testing.Fake
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *FakeResourceV1beta2) DeviceClasses() v1beta2.DeviceClassInterface {
|
||||||
|
return newFakeDeviceClasses(c)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *FakeResourceV1beta2) ResourceClaims(namespace string) v1beta2.ResourceClaimInterface {
|
||||||
|
return newFakeResourceClaims(c, namespace)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *FakeResourceV1beta2) ResourceClaimTemplates(namespace string) v1beta2.ResourceClaimTemplateInterface {
|
||||||
|
return newFakeResourceClaimTemplates(c, namespace)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *FakeResourceV1beta2) ResourceSlices() v1beta2.ResourceSliceInterface {
|
||||||
|
return newFakeResourceSlices(c)
|
||||||
|
}
|
||||||
|
|
||||||
|
// RESTClient returns a RESTClient that is used to communicate
|
||||||
|
// with API server by this client implementation.
|
||||||
|
func (c *FakeResourceV1beta2) RESTClient() rest.Interface {
|
||||||
|
var ret *rest.RESTClient
|
||||||
|
return ret
|
||||||
|
}
|
53
kubernetes/typed/resource/v1beta2/fake/fake_resourceclaim.go
Normal file
53
kubernetes/typed/resource/v1beta2/fake/fake_resourceclaim.go
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package fake
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
typedresourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// fakeResourceClaims implements ResourceClaimInterface
|
||||||
|
type fakeResourceClaims struct {
|
||||||
|
*gentype.FakeClientWithListAndApply[*v1beta2.ResourceClaim, *v1beta2.ResourceClaimList, *resourcev1beta2.ResourceClaimApplyConfiguration]
|
||||||
|
Fake *FakeResourceV1beta2
|
||||||
|
}
|
||||||
|
|
||||||
|
func newFakeResourceClaims(fake *FakeResourceV1beta2, namespace string) typedresourcev1beta2.ResourceClaimInterface {
|
||||||
|
return &fakeResourceClaims{
|
||||||
|
gentype.NewFakeClientWithListAndApply[*v1beta2.ResourceClaim, *v1beta2.ResourceClaimList, *resourcev1beta2.ResourceClaimApplyConfiguration](
|
||||||
|
fake.Fake,
|
||||||
|
namespace,
|
||||||
|
v1beta2.SchemeGroupVersion.WithResource("resourceclaims"),
|
||||||
|
v1beta2.SchemeGroupVersion.WithKind("ResourceClaim"),
|
||||||
|
func() *v1beta2.ResourceClaim { return &v1beta2.ResourceClaim{} },
|
||||||
|
func() *v1beta2.ResourceClaimList { return &v1beta2.ResourceClaimList{} },
|
||||||
|
func(dst, src *v1beta2.ResourceClaimList) { dst.ListMeta = src.ListMeta },
|
||||||
|
func(list *v1beta2.ResourceClaimList) []*v1beta2.ResourceClaim {
|
||||||
|
return gentype.ToPointerSlice(list.Items)
|
||||||
|
},
|
||||||
|
func(list *v1beta2.ResourceClaimList, items []*v1beta2.ResourceClaim) {
|
||||||
|
list.Items = gentype.FromPointerSlice(items)
|
||||||
|
},
|
||||||
|
),
|
||||||
|
fake,
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,53 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package fake
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
typedresourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// fakeResourceClaimTemplates implements ResourceClaimTemplateInterface
|
||||||
|
type fakeResourceClaimTemplates struct {
|
||||||
|
*gentype.FakeClientWithListAndApply[*v1beta2.ResourceClaimTemplate, *v1beta2.ResourceClaimTemplateList, *resourcev1beta2.ResourceClaimTemplateApplyConfiguration]
|
||||||
|
Fake *FakeResourceV1beta2
|
||||||
|
}
|
||||||
|
|
||||||
|
func newFakeResourceClaimTemplates(fake *FakeResourceV1beta2, namespace string) typedresourcev1beta2.ResourceClaimTemplateInterface {
|
||||||
|
return &fakeResourceClaimTemplates{
|
||||||
|
gentype.NewFakeClientWithListAndApply[*v1beta2.ResourceClaimTemplate, *v1beta2.ResourceClaimTemplateList, *resourcev1beta2.ResourceClaimTemplateApplyConfiguration](
|
||||||
|
fake.Fake,
|
||||||
|
namespace,
|
||||||
|
v1beta2.SchemeGroupVersion.WithResource("resourceclaimtemplates"),
|
||||||
|
v1beta2.SchemeGroupVersion.WithKind("ResourceClaimTemplate"),
|
||||||
|
func() *v1beta2.ResourceClaimTemplate { return &v1beta2.ResourceClaimTemplate{} },
|
||||||
|
func() *v1beta2.ResourceClaimTemplateList { return &v1beta2.ResourceClaimTemplateList{} },
|
||||||
|
func(dst, src *v1beta2.ResourceClaimTemplateList) { dst.ListMeta = src.ListMeta },
|
||||||
|
func(list *v1beta2.ResourceClaimTemplateList) []*v1beta2.ResourceClaimTemplate {
|
||||||
|
return gentype.ToPointerSlice(list.Items)
|
||||||
|
},
|
||||||
|
func(list *v1beta2.ResourceClaimTemplateList, items []*v1beta2.ResourceClaimTemplate) {
|
||||||
|
list.Items = gentype.FromPointerSlice(items)
|
||||||
|
},
|
||||||
|
),
|
||||||
|
fake,
|
||||||
|
}
|
||||||
|
}
|
53
kubernetes/typed/resource/v1beta2/fake/fake_resourceslice.go
Normal file
53
kubernetes/typed/resource/v1beta2/fake/fake_resourceslice.go
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package fake
|
||||||
|
|
||||||
|
import (
|
||||||
|
v1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
resourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
typedresourcev1beta2 "k8s.io/client-go/kubernetes/typed/resource/v1beta2"
|
||||||
|
)
|
||||||
|
|
||||||
|
// fakeResourceSlices implements ResourceSliceInterface
|
||||||
|
type fakeResourceSlices struct {
|
||||||
|
*gentype.FakeClientWithListAndApply[*v1beta2.ResourceSlice, *v1beta2.ResourceSliceList, *resourcev1beta2.ResourceSliceApplyConfiguration]
|
||||||
|
Fake *FakeResourceV1beta2
|
||||||
|
}
|
||||||
|
|
||||||
|
func newFakeResourceSlices(fake *FakeResourceV1beta2) typedresourcev1beta2.ResourceSliceInterface {
|
||||||
|
return &fakeResourceSlices{
|
||||||
|
gentype.NewFakeClientWithListAndApply[*v1beta2.ResourceSlice, *v1beta2.ResourceSliceList, *resourcev1beta2.ResourceSliceApplyConfiguration](
|
||||||
|
fake.Fake,
|
||||||
|
"",
|
||||||
|
v1beta2.SchemeGroupVersion.WithResource("resourceslices"),
|
||||||
|
v1beta2.SchemeGroupVersion.WithKind("ResourceSlice"),
|
||||||
|
func() *v1beta2.ResourceSlice { return &v1beta2.ResourceSlice{} },
|
||||||
|
func() *v1beta2.ResourceSliceList { return &v1beta2.ResourceSliceList{} },
|
||||||
|
func(dst, src *v1beta2.ResourceSliceList) { dst.ListMeta = src.ListMeta },
|
||||||
|
func(list *v1beta2.ResourceSliceList) []*v1beta2.ResourceSlice {
|
||||||
|
return gentype.ToPointerSlice(list.Items)
|
||||||
|
},
|
||||||
|
func(list *v1beta2.ResourceSliceList, items []*v1beta2.ResourceSlice) {
|
||||||
|
list.Items = gentype.FromPointerSlice(items)
|
||||||
|
},
|
||||||
|
),
|
||||||
|
fake,
|
||||||
|
}
|
||||||
|
}
|
27
kubernetes/typed/resource/v1beta2/generated_expansion.go
Normal file
27
kubernetes/typed/resource/v1beta2/generated_expansion.go
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
type DeviceClassExpansion interface{}
|
||||||
|
|
||||||
|
type ResourceClaimExpansion interface{}
|
||||||
|
|
||||||
|
type ResourceClaimTemplateExpansion interface{}
|
||||||
|
|
||||||
|
type ResourceSliceExpansion interface{}
|
116
kubernetes/typed/resource/v1beta2/resource_client.go
Normal file
116
kubernetes/typed/resource/v1beta2/resource_client.go
Normal file
@ -0,0 +1,116 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
http "net/http"
|
||||||
|
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
|
rest "k8s.io/client-go/rest"
|
||||||
|
)
|
||||||
|
|
||||||
|
type ResourceV1beta2Interface interface {
|
||||||
|
RESTClient() rest.Interface
|
||||||
|
DeviceClassesGetter
|
||||||
|
ResourceClaimsGetter
|
||||||
|
ResourceClaimTemplatesGetter
|
||||||
|
ResourceSlicesGetter
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceV1beta2Client is used to interact with features provided by the resource.k8s.io group.
|
||||||
|
type ResourceV1beta2Client struct {
|
||||||
|
restClient rest.Interface
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *ResourceV1beta2Client) DeviceClasses() DeviceClassInterface {
|
||||||
|
return newDeviceClasses(c)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *ResourceV1beta2Client) ResourceClaims(namespace string) ResourceClaimInterface {
|
||||||
|
return newResourceClaims(c, namespace)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *ResourceV1beta2Client) ResourceClaimTemplates(namespace string) ResourceClaimTemplateInterface {
|
||||||
|
return newResourceClaimTemplates(c, namespace)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *ResourceV1beta2Client) ResourceSlices() ResourceSliceInterface {
|
||||||
|
return newResourceSlices(c)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewForConfig creates a new ResourceV1beta2Client for the given config.
|
||||||
|
// NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
|
||||||
|
// where httpClient was generated with rest.HTTPClientFor(c).
|
||||||
|
func NewForConfig(c *rest.Config) (*ResourceV1beta2Client, error) {
|
||||||
|
config := *c
|
||||||
|
setConfigDefaults(&config)
|
||||||
|
httpClient, err := rest.HTTPClientFor(&config)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return NewForConfigAndClient(&config, httpClient)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewForConfigAndClient creates a new ResourceV1beta2Client for the given config and http client.
|
||||||
|
// Note the http client provided takes precedence over the configured transport values.
|
||||||
|
func NewForConfigAndClient(c *rest.Config, h *http.Client) (*ResourceV1beta2Client, error) {
|
||||||
|
config := *c
|
||||||
|
setConfigDefaults(&config)
|
||||||
|
client, err := rest.RESTClientForConfigAndClient(&config, h)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return &ResourceV1beta2Client{client}, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewForConfigOrDie creates a new ResourceV1beta2Client for the given config and
|
||||||
|
// panics if there is an error in the config.
|
||||||
|
func NewForConfigOrDie(c *rest.Config) *ResourceV1beta2Client {
|
||||||
|
client, err := NewForConfig(c)
|
||||||
|
if err != nil {
|
||||||
|
panic(err)
|
||||||
|
}
|
||||||
|
return client
|
||||||
|
}
|
||||||
|
|
||||||
|
// New creates a new ResourceV1beta2Client for the given RESTClient.
|
||||||
|
func New(c rest.Interface) *ResourceV1beta2Client {
|
||||||
|
return &ResourceV1beta2Client{c}
|
||||||
|
}
|
||||||
|
|
||||||
|
func setConfigDefaults(config *rest.Config) {
|
||||||
|
gv := resourcev1beta2.SchemeGroupVersion
|
||||||
|
config.GroupVersion = &gv
|
||||||
|
config.APIPath = "/apis"
|
||||||
|
config.NegotiatedSerializer = rest.CodecFactoryForGeneratedClient(scheme.Scheme, scheme.Codecs).WithoutConversion()
|
||||||
|
|
||||||
|
if config.UserAgent == "" {
|
||||||
|
config.UserAgent = rest.DefaultKubernetesUserAgent()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// RESTClient returns a RESTClient that is used to communicate
|
||||||
|
// with API server by this client implementation.
|
||||||
|
func (c *ResourceV1beta2Client) RESTClient() rest.Interface {
|
||||||
|
if c == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
return c.restClient
|
||||||
|
}
|
75
kubernetes/typed/resource/v1beta2/resourceclaim.go
Normal file
75
kubernetes/typed/resource/v1beta2/resourceclaim.go
Normal file
@ -0,0 +1,75 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
applyconfigurationsresourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimsGetter has a method to return a ResourceClaimInterface.
|
||||||
|
// A group's client should implement this interface.
|
||||||
|
type ResourceClaimsGetter interface {
|
||||||
|
ResourceClaims(namespace string) ResourceClaimInterface
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimInterface has methods to work with ResourceClaim resources.
|
||||||
|
type ResourceClaimInterface interface {
|
||||||
|
Create(ctx context.Context, resourceClaim *resourcev1beta2.ResourceClaim, opts v1.CreateOptions) (*resourcev1beta2.ResourceClaim, error)
|
||||||
|
Update(ctx context.Context, resourceClaim *resourcev1beta2.ResourceClaim, opts v1.UpdateOptions) (*resourcev1beta2.ResourceClaim, error)
|
||||||
|
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
|
||||||
|
UpdateStatus(ctx context.Context, resourceClaim *resourcev1beta2.ResourceClaim, opts v1.UpdateOptions) (*resourcev1beta2.ResourceClaim, error)
|
||||||
|
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||||
|
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||||
|
Get(ctx context.Context, name string, opts v1.GetOptions) (*resourcev1beta2.ResourceClaim, error)
|
||||||
|
List(ctx context.Context, opts v1.ListOptions) (*resourcev1beta2.ResourceClaimList, error)
|
||||||
|
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||||
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *resourcev1beta2.ResourceClaim, err error)
|
||||||
|
Apply(ctx context.Context, resourceClaim *applyconfigurationsresourcev1beta2.ResourceClaimApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1beta2.ResourceClaim, err error)
|
||||||
|
// Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
|
||||||
|
ApplyStatus(ctx context.Context, resourceClaim *applyconfigurationsresourcev1beta2.ResourceClaimApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1beta2.ResourceClaim, err error)
|
||||||
|
ResourceClaimExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaims implements ResourceClaimInterface
|
||||||
|
type resourceClaims struct {
|
||||||
|
*gentype.ClientWithListAndApply[*resourcev1beta2.ResourceClaim, *resourcev1beta2.ResourceClaimList, *applyconfigurationsresourcev1beta2.ResourceClaimApplyConfiguration]
|
||||||
|
}
|
||||||
|
|
||||||
|
// newResourceClaims returns a ResourceClaims
|
||||||
|
func newResourceClaims(c *ResourceV1beta2Client, namespace string) *resourceClaims {
|
||||||
|
return &resourceClaims{
|
||||||
|
gentype.NewClientWithListAndApply[*resourcev1beta2.ResourceClaim, *resourcev1beta2.ResourceClaimList, *applyconfigurationsresourcev1beta2.ResourceClaimApplyConfiguration](
|
||||||
|
"resourceclaims",
|
||||||
|
c.RESTClient(),
|
||||||
|
scheme.ParameterCodec,
|
||||||
|
namespace,
|
||||||
|
func() *resourcev1beta2.ResourceClaim { return &resourcev1beta2.ResourceClaim{} },
|
||||||
|
func() *resourcev1beta2.ResourceClaimList { return &resourcev1beta2.ResourceClaimList{} },
|
||||||
|
gentype.PrefersProtobuf[*resourcev1beta2.ResourceClaim](),
|
||||||
|
),
|
||||||
|
}
|
||||||
|
}
|
71
kubernetes/typed/resource/v1beta2/resourceclaimtemplate.go
Normal file
71
kubernetes/typed/resource/v1beta2/resourceclaimtemplate.go
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
applyconfigurationsresourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimTemplatesGetter has a method to return a ResourceClaimTemplateInterface.
|
||||||
|
// A group's client should implement this interface.
|
||||||
|
type ResourceClaimTemplatesGetter interface {
|
||||||
|
ResourceClaimTemplates(namespace string) ResourceClaimTemplateInterface
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplateInterface has methods to work with ResourceClaimTemplate resources.
|
||||||
|
type ResourceClaimTemplateInterface interface {
|
||||||
|
Create(ctx context.Context, resourceClaimTemplate *resourcev1beta2.ResourceClaimTemplate, opts v1.CreateOptions) (*resourcev1beta2.ResourceClaimTemplate, error)
|
||||||
|
Update(ctx context.Context, resourceClaimTemplate *resourcev1beta2.ResourceClaimTemplate, opts v1.UpdateOptions) (*resourcev1beta2.ResourceClaimTemplate, error)
|
||||||
|
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||||
|
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||||
|
Get(ctx context.Context, name string, opts v1.GetOptions) (*resourcev1beta2.ResourceClaimTemplate, error)
|
||||||
|
List(ctx context.Context, opts v1.ListOptions) (*resourcev1beta2.ResourceClaimTemplateList, error)
|
||||||
|
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||||
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *resourcev1beta2.ResourceClaimTemplate, err error)
|
||||||
|
Apply(ctx context.Context, resourceClaimTemplate *applyconfigurationsresourcev1beta2.ResourceClaimTemplateApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1beta2.ResourceClaimTemplate, err error)
|
||||||
|
ResourceClaimTemplateExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaimTemplates implements ResourceClaimTemplateInterface
|
||||||
|
type resourceClaimTemplates struct {
|
||||||
|
*gentype.ClientWithListAndApply[*resourcev1beta2.ResourceClaimTemplate, *resourcev1beta2.ResourceClaimTemplateList, *applyconfigurationsresourcev1beta2.ResourceClaimTemplateApplyConfiguration]
|
||||||
|
}
|
||||||
|
|
||||||
|
// newResourceClaimTemplates returns a ResourceClaimTemplates
|
||||||
|
func newResourceClaimTemplates(c *ResourceV1beta2Client, namespace string) *resourceClaimTemplates {
|
||||||
|
return &resourceClaimTemplates{
|
||||||
|
gentype.NewClientWithListAndApply[*resourcev1beta2.ResourceClaimTemplate, *resourcev1beta2.ResourceClaimTemplateList, *applyconfigurationsresourcev1beta2.ResourceClaimTemplateApplyConfiguration](
|
||||||
|
"resourceclaimtemplates",
|
||||||
|
c.RESTClient(),
|
||||||
|
scheme.ParameterCodec,
|
||||||
|
namespace,
|
||||||
|
func() *resourcev1beta2.ResourceClaimTemplate { return &resourcev1beta2.ResourceClaimTemplate{} },
|
||||||
|
func() *resourcev1beta2.ResourceClaimTemplateList { return &resourcev1beta2.ResourceClaimTemplateList{} },
|
||||||
|
gentype.PrefersProtobuf[*resourcev1beta2.ResourceClaimTemplate](),
|
||||||
|
),
|
||||||
|
}
|
||||||
|
}
|
71
kubernetes/typed/resource/v1beta2/resourceslice.go
Normal file
71
kubernetes/typed/resource/v1beta2/resourceslice.go
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
context "context"
|
||||||
|
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
|
applyconfigurationsresourcev1beta2 "k8s.io/client-go/applyconfigurations/resource/v1beta2"
|
||||||
|
gentype "k8s.io/client-go/gentype"
|
||||||
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceSlicesGetter has a method to return a ResourceSliceInterface.
|
||||||
|
// A group's client should implement this interface.
|
||||||
|
type ResourceSlicesGetter interface {
|
||||||
|
ResourceSlices() ResourceSliceInterface
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceSliceInterface has methods to work with ResourceSlice resources.
|
||||||
|
type ResourceSliceInterface interface {
|
||||||
|
Create(ctx context.Context, resourceSlice *resourcev1beta2.ResourceSlice, opts v1.CreateOptions) (*resourcev1beta2.ResourceSlice, error)
|
||||||
|
Update(ctx context.Context, resourceSlice *resourcev1beta2.ResourceSlice, opts v1.UpdateOptions) (*resourcev1beta2.ResourceSlice, error)
|
||||||
|
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||||
|
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||||
|
Get(ctx context.Context, name string, opts v1.GetOptions) (*resourcev1beta2.ResourceSlice, error)
|
||||||
|
List(ctx context.Context, opts v1.ListOptions) (*resourcev1beta2.ResourceSliceList, error)
|
||||||
|
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||||
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *resourcev1beta2.ResourceSlice, err error)
|
||||||
|
Apply(ctx context.Context, resourceSlice *applyconfigurationsresourcev1beta2.ResourceSliceApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1beta2.ResourceSlice, err error)
|
||||||
|
ResourceSliceExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceSlices implements ResourceSliceInterface
|
||||||
|
type resourceSlices struct {
|
||||||
|
*gentype.ClientWithListAndApply[*resourcev1beta2.ResourceSlice, *resourcev1beta2.ResourceSliceList, *applyconfigurationsresourcev1beta2.ResourceSliceApplyConfiguration]
|
||||||
|
}
|
||||||
|
|
||||||
|
// newResourceSlices returns a ResourceSlices
|
||||||
|
func newResourceSlices(c *ResourceV1beta2Client) *resourceSlices {
|
||||||
|
return &resourceSlices{
|
||||||
|
gentype.NewClientWithListAndApply[*resourcev1beta2.ResourceSlice, *resourcev1beta2.ResourceSliceList, *applyconfigurationsresourcev1beta2.ResourceSliceApplyConfiguration](
|
||||||
|
"resourceslices",
|
||||||
|
c.RESTClient(),
|
||||||
|
scheme.ParameterCodec,
|
||||||
|
"",
|
||||||
|
func() *resourcev1beta2.ResourceSlice { return &resourcev1beta2.ResourceSlice{} },
|
||||||
|
func() *resourcev1beta2.ResourceSliceList { return &resourcev1beta2.ResourceSliceList{} },
|
||||||
|
gentype.PrefersProtobuf[*resourcev1beta2.ResourceSlice](),
|
||||||
|
),
|
||||||
|
}
|
||||||
|
}
|
48
listers/resource/v1beta2/deviceclass.go
Normal file
48
listers/resource/v1beta2/deviceclass.go
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
|
listers "k8s.io/client-go/listers"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// DeviceClassLister helps list DeviceClasses.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type DeviceClassLister interface {
|
||||||
|
// List lists all DeviceClasses in the indexer.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.DeviceClass, err error)
|
||||||
|
// Get retrieves the DeviceClass from the index for a given name.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
Get(name string) (*resourcev1beta2.DeviceClass, error)
|
||||||
|
DeviceClassListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// deviceClassLister implements the DeviceClassLister interface.
|
||||||
|
type deviceClassLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.DeviceClass]
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewDeviceClassLister returns a new DeviceClassLister.
|
||||||
|
func NewDeviceClassLister(indexer cache.Indexer) DeviceClassLister {
|
||||||
|
return &deviceClassLister{listers.New[*resourcev1beta2.DeviceClass](indexer, resourcev1beta2.Resource("deviceclass"))}
|
||||||
|
}
|
43
listers/resource/v1beta2/expansion_generated.go
Normal file
43
listers/resource/v1beta2/expansion_generated.go
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
// DeviceClassListerExpansion allows custom methods to be added to
|
||||||
|
// DeviceClassLister.
|
||||||
|
type DeviceClassListerExpansion interface{}
|
||||||
|
|
||||||
|
// ResourceClaimListerExpansion allows custom methods to be added to
|
||||||
|
// ResourceClaimLister.
|
||||||
|
type ResourceClaimListerExpansion interface{}
|
||||||
|
|
||||||
|
// ResourceClaimNamespaceListerExpansion allows custom methods to be added to
|
||||||
|
// ResourceClaimNamespaceLister.
|
||||||
|
type ResourceClaimNamespaceListerExpansion interface{}
|
||||||
|
|
||||||
|
// ResourceClaimTemplateListerExpansion allows custom methods to be added to
|
||||||
|
// ResourceClaimTemplateLister.
|
||||||
|
type ResourceClaimTemplateListerExpansion interface{}
|
||||||
|
|
||||||
|
// ResourceClaimTemplateNamespaceListerExpansion allows custom methods to be added to
|
||||||
|
// ResourceClaimTemplateNamespaceLister.
|
||||||
|
type ResourceClaimTemplateNamespaceListerExpansion interface{}
|
||||||
|
|
||||||
|
// ResourceSliceListerExpansion allows custom methods to be added to
|
||||||
|
// ResourceSliceLister.
|
||||||
|
type ResourceSliceListerExpansion interface{}
|
70
listers/resource/v1beta2/resourceclaim.go
Normal file
70
listers/resource/v1beta2/resourceclaim.go
Normal file
@ -0,0 +1,70 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
|
listers "k8s.io/client-go/listers"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimLister helps list ResourceClaims.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type ResourceClaimLister interface {
|
||||||
|
// List lists all ResourceClaims in the indexer.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.ResourceClaim, err error)
|
||||||
|
// ResourceClaims returns an object that can list and get ResourceClaims.
|
||||||
|
ResourceClaims(namespace string) ResourceClaimNamespaceLister
|
||||||
|
ResourceClaimListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaimLister implements the ResourceClaimLister interface.
|
||||||
|
type resourceClaimLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.ResourceClaim]
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceClaimLister returns a new ResourceClaimLister.
|
||||||
|
func NewResourceClaimLister(indexer cache.Indexer) ResourceClaimLister {
|
||||||
|
return &resourceClaimLister{listers.New[*resourcev1beta2.ResourceClaim](indexer, resourcev1beta2.Resource("resourceclaim"))}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaims returns an object that can list and get ResourceClaims.
|
||||||
|
func (s *resourceClaimLister) ResourceClaims(namespace string) ResourceClaimNamespaceLister {
|
||||||
|
return resourceClaimNamespaceLister{listers.NewNamespaced[*resourcev1beta2.ResourceClaim](s.ResourceIndexer, namespace)}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimNamespaceLister helps list and get ResourceClaims.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type ResourceClaimNamespaceLister interface {
|
||||||
|
// List lists all ResourceClaims in the indexer for a given namespace.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.ResourceClaim, err error)
|
||||||
|
// Get retrieves the ResourceClaim from the indexer for a given namespace and name.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
Get(name string) (*resourcev1beta2.ResourceClaim, error)
|
||||||
|
ResourceClaimNamespaceListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaimNamespaceLister implements the ResourceClaimNamespaceLister
|
||||||
|
// interface.
|
||||||
|
type resourceClaimNamespaceLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.ResourceClaim]
|
||||||
|
}
|
70
listers/resource/v1beta2/resourceclaimtemplate.go
Normal file
70
listers/resource/v1beta2/resourceclaimtemplate.go
Normal file
@ -0,0 +1,70 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
|
listers "k8s.io/client-go/listers"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceClaimTemplateLister helps list ResourceClaimTemplates.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type ResourceClaimTemplateLister interface {
|
||||||
|
// List lists all ResourceClaimTemplates in the indexer.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.ResourceClaimTemplate, err error)
|
||||||
|
// ResourceClaimTemplates returns an object that can list and get ResourceClaimTemplates.
|
||||||
|
ResourceClaimTemplates(namespace string) ResourceClaimTemplateNamespaceLister
|
||||||
|
ResourceClaimTemplateListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaimTemplateLister implements the ResourceClaimTemplateLister interface.
|
||||||
|
type resourceClaimTemplateLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.ResourceClaimTemplate]
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceClaimTemplateLister returns a new ResourceClaimTemplateLister.
|
||||||
|
func NewResourceClaimTemplateLister(indexer cache.Indexer) ResourceClaimTemplateLister {
|
||||||
|
return &resourceClaimTemplateLister{listers.New[*resourcev1beta2.ResourceClaimTemplate](indexer, resourcev1beta2.Resource("resourceclaimtemplate"))}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplates returns an object that can list and get ResourceClaimTemplates.
|
||||||
|
func (s *resourceClaimTemplateLister) ResourceClaimTemplates(namespace string) ResourceClaimTemplateNamespaceLister {
|
||||||
|
return resourceClaimTemplateNamespaceLister{listers.NewNamespaced[*resourcev1beta2.ResourceClaimTemplate](s.ResourceIndexer, namespace)}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ResourceClaimTemplateNamespaceLister helps list and get ResourceClaimTemplates.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type ResourceClaimTemplateNamespaceLister interface {
|
||||||
|
// List lists all ResourceClaimTemplates in the indexer for a given namespace.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.ResourceClaimTemplate, err error)
|
||||||
|
// Get retrieves the ResourceClaimTemplate from the indexer for a given namespace and name.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
Get(name string) (*resourcev1beta2.ResourceClaimTemplate, error)
|
||||||
|
ResourceClaimTemplateNamespaceListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceClaimTemplateNamespaceLister implements the ResourceClaimTemplateNamespaceLister
|
||||||
|
// interface.
|
||||||
|
type resourceClaimTemplateNamespaceLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.ResourceClaimTemplate]
|
||||||
|
}
|
48
listers/resource/v1beta2/resourceslice.go
Normal file
48
listers/resource/v1beta2/resourceslice.go
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
/*
|
||||||
|
Copyright The Kubernetes Authors.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
|
package v1beta2
|
||||||
|
|
||||||
|
import (
|
||||||
|
resourcev1beta2 "k8s.io/api/resource/v1beta2"
|
||||||
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
|
listers "k8s.io/client-go/listers"
|
||||||
|
cache "k8s.io/client-go/tools/cache"
|
||||||
|
)
|
||||||
|
|
||||||
|
// ResourceSliceLister helps list ResourceSlices.
|
||||||
|
// All objects returned here must be treated as read-only.
|
||||||
|
type ResourceSliceLister interface {
|
||||||
|
// List lists all ResourceSlices in the indexer.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
List(selector labels.Selector) (ret []*resourcev1beta2.ResourceSlice, err error)
|
||||||
|
// Get retrieves the ResourceSlice from the index for a given name.
|
||||||
|
// Objects returned here must be treated as read-only.
|
||||||
|
Get(name string) (*resourcev1beta2.ResourceSlice, error)
|
||||||
|
ResourceSliceListerExpansion
|
||||||
|
}
|
||||||
|
|
||||||
|
// resourceSliceLister implements the ResourceSliceLister interface.
|
||||||
|
type resourceSliceLister struct {
|
||||||
|
listers.ResourceIndexer[*resourcev1beta2.ResourceSlice]
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewResourceSliceLister returns a new ResourceSliceLister.
|
||||||
|
func NewResourceSliceLister(indexer cache.Indexer) ResourceSliceLister {
|
||||||
|
return &resourceSliceLister{listers.New[*resourcev1beta2.ResourceSlice](indexer, resourcev1beta2.Resource("resourceslice"))}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user