Generate code

Kubernetes-commit: cb12a2bc5118fe34e2eb396dc1a3b8e7cc1de9f4
This commit is contained in:
Takafumi Takahashi 2022-11-09 21:21:52 +00:00 committed by Kubernetes Publisher
parent 0a1f6a8fd0
commit c7bdab2154
4 changed files with 88 additions and 3 deletions

View File

@ -33,7 +33,7 @@ type PersistentVolumeClaimSpecApplyConfiguration struct {
StorageClassName *string `json:"storageClassName,omitempty"`
VolumeMode *v1.PersistentVolumeMode `json:"volumeMode,omitempty"`
DataSource *TypedLocalObjectReferenceApplyConfiguration `json:"dataSource,omitempty"`
DataSourceRef *TypedLocalObjectReferenceApplyConfiguration `json:"dataSourceRef,omitempty"`
DataSourceRef *TypedObjectReferenceApplyConfiguration `json:"dataSourceRef,omitempty"`
}
// PersistentVolumeClaimSpecApplyConfiguration constructs an declarative configuration of the PersistentVolumeClaimSpec type for use with
@ -103,7 +103,7 @@ func (b *PersistentVolumeClaimSpecApplyConfiguration) WithDataSource(value *Type
// WithDataSourceRef sets the DataSourceRef 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 DataSourceRef field is set to the value of the last call.
func (b *PersistentVolumeClaimSpecApplyConfiguration) WithDataSourceRef(value *TypedLocalObjectReferenceApplyConfiguration) *PersistentVolumeClaimSpecApplyConfiguration {
func (b *PersistentVolumeClaimSpecApplyConfiguration) WithDataSourceRef(value *TypedObjectReferenceApplyConfiguration) *PersistentVolumeClaimSpecApplyConfiguration {
b.DataSourceRef = value
return b
}

View 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 v1
// TypedObjectReferenceApplyConfiguration represents an declarative configuration of the TypedObjectReference type for use
// with apply.
type TypedObjectReferenceApplyConfiguration struct {
APIGroup *string `json:"apiGroup,omitempty"`
Kind *string `json:"kind,omitempty"`
Name *string `json:"name,omitempty"`
Namespace *string `json:"namespace,omitempty"`
}
// TypedObjectReferenceApplyConfiguration constructs an declarative configuration of the TypedObjectReference type for use with
// apply.
func TypedObjectReference() *TypedObjectReferenceApplyConfiguration {
return &TypedObjectReferenceApplyConfiguration{}
}
// 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 *TypedObjectReferenceApplyConfiguration) WithAPIGroup(value string) *TypedObjectReferenceApplyConfiguration {
b.APIGroup = &value
return b
}
// 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 *TypedObjectReferenceApplyConfiguration) WithKind(value string) *TypedObjectReferenceApplyConfiguration {
b.Kind = &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 *TypedObjectReferenceApplyConfiguration) WithName(value string) *TypedObjectReferenceApplyConfiguration {
b.Name = &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 *TypedObjectReferenceApplyConfiguration) WithNamespace(value string) *TypedObjectReferenceApplyConfiguration {
b.Namespace = &value
return b
}

View File

@ -5544,7 +5544,7 @@ var schemaYAML = typed.YAMLObject(`types:
namedType: io.k8s.api.core.v1.TypedLocalObjectReference
- name: dataSourceRef
type:
namedType: io.k8s.api.core.v1.TypedLocalObjectReference
namedType: io.k8s.api.core.v1.TypedObjectReference
- name: resources
type:
namedType: io.k8s.api.core.v1.ResourceRequirements
@ -7133,6 +7133,23 @@ var schemaYAML = typed.YAMLObject(`types:
scalar: string
default: ""
elementRelationship: atomic
- name: io.k8s.api.core.v1.TypedObjectReference
map:
fields:
- name: apiGroup
type:
scalar: string
- name: kind
type:
scalar: string
default: ""
- name: name
type:
scalar: string
default: ""
- name: namespace
type:
scalar: string
- name: io.k8s.api.core.v1.Volume
map:
fields:

View File

@ -867,6 +867,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &applyconfigurationscorev1.TopologySpreadConstraintApplyConfiguration{}
case corev1.SchemeGroupVersion.WithKind("TypedLocalObjectReference"):
return &applyconfigurationscorev1.TypedLocalObjectReferenceApplyConfiguration{}
case corev1.SchemeGroupVersion.WithKind("TypedObjectReference"):
return &applyconfigurationscorev1.TypedObjectReferenceApplyConfiguration{}
case corev1.SchemeGroupVersion.WithKind("Volume"):
return &applyconfigurationscorev1.VolumeApplyConfiguration{}
case corev1.SchemeGroupVersion.WithKind("VolumeDevice"):