aboutsummaryrefslogtreecommitdiffstats
path: root/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1
diff options
context:
space:
mode:
authorHuabingZhao <zhao.huabing@zte.com.cn>2017-09-04 15:00:54 +0800
committerHuabingZhao <zhao.huabing@zte.com.cn>2017-09-04 15:06:21 +0800
commit43dac0bc4302fed79eaeb661723ca584a9c0496a (patch)
treea78f60300d73f0a69ed12e946d3fe4580455d8ba /kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1
parenta7837a0ac51704003c6aacba2dacb8e64f681622 (diff)
restructure the source directory
Issue-ID: OOM-61 Change-Id: Ib6f633d517ad197bfdbca59b374cdad2f1ed897e Signed-off-by: HuabingZhao <zhao.huabing@zte.com.cn>
Diffstat (limited to 'kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1')
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion.go579
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion_generated.go6820
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/deep_copy_generated.go2924
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/defaults.go301
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/doc.go21
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.pb.go34797
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.proto2935
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/meta.go85
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/register.go94
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.generated.go60001
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.go3329
-rw-r--r--kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types_swagger_doc_generated.go1742
12 files changed, 0 insertions, 113628 deletions
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion.go
deleted file mode 100644
index 642b1bc..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion.go
+++ /dev/null
@@ -1,579 +0,0 @@
-/*
-Copyright 2015 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.
-*/
-
-package v1
-
-import (
- "encoding/json"
- "fmt"
-
- "k8s.io/kubernetes/pkg/api"
- "k8s.io/kubernetes/pkg/conversion"
- "k8s.io/kubernetes/pkg/runtime"
-)
-
-const (
- // Annotation key used to identify mirror pods.
- mirrorAnnotationKey = "kubernetes.io/config.mirror"
-
- // Value used to identify mirror pods from pre-v1.1 kubelet.
- mirrorAnnotationValue_1_0 = "mirror"
-)
-
-func addConversionFuncs(scheme *runtime.Scheme) {
- // Add non-generated conversion functions
- err := scheme.AddConversionFuncs(
- Convert_api_Pod_To_v1_Pod,
- Convert_api_PodSpec_To_v1_PodSpec,
- Convert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec,
- Convert_api_ServiceSpec_To_v1_ServiceSpec,
- Convert_v1_Pod_To_api_Pod,
- Convert_v1_PodSpec_To_api_PodSpec,
- Convert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec,
- Convert_v1_Secret_To_api_Secret,
- Convert_v1_ServiceSpec_To_api_ServiceSpec,
- Convert_v1_ResourceList_To_api_ResourceList,
- )
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
-
- // Add field label conversions for kinds having selectable nothing but ObjectMeta fields.
- for _, kind := range []string{
- "Endpoints",
- "ResourceQuota",
- "PersistentVolumeClaim",
- "Service",
- "ServiceAccount",
- "ConfigMap",
- } {
- err = api.Scheme.AddFieldLabelConversionFunc("v1", kind,
- func(label, value string) (string, string, error) {
- switch label {
- case "metadata.namespace",
- "metadata.name":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label %q not supported for %q", label, kind)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- }
-
- // Add field conversion funcs.
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "Pod",
- func(label, value string) (string, string, error) {
- switch label {
- case "metadata.name",
- "metadata.namespace",
- "metadata.labels",
- "metadata.annotations",
- "status.phase",
- "status.podIP",
- "spec.nodeName",
- "spec.restartPolicy":
- return label, value, nil
- // This is for backwards compatibility with old v1 clients which send spec.host
- case "spec.host":
- return "spec.nodeName", value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "Node",
- func(label, value string) (string, string, error) {
- switch label {
- case "metadata.name":
- return label, value, nil
- case "spec.unschedulable":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "ReplicationController",
- func(label, value string) (string, string, error) {
- switch label {
- case "metadata.name",
- "metadata.namespace",
- "status.replicas":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "Event",
- func(label, value string) (string, string, error) {
- switch label {
- case "involvedObject.kind",
- "involvedObject.namespace",
- "involvedObject.name",
- "involvedObject.uid",
- "involvedObject.apiVersion",
- "involvedObject.resourceVersion",
- "involvedObject.fieldPath",
- "reason",
- "source",
- "type",
- "metadata.namespace",
- "metadata.name":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "Namespace",
- func(label, value string) (string, string, error) {
- switch label {
- case "status.phase",
- "metadata.name":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "PersistentVolume",
- func(label, value string) (string, string, error) {
- switch label {
- case "metadata.name":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
- err = api.Scheme.AddFieldLabelConversionFunc("v1", "Secret",
- func(label, value string) (string, string, error) {
- switch label {
- case "type",
- "metadata.namespace",
- "metadata.name":
- return label, value, nil
- default:
- return "", "", fmt.Errorf("field label not supported: %s", label)
- }
- })
- if err != nil {
- // If one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
-}
-
-func Convert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec(in *api.ReplicationControllerSpec, out *ReplicationControllerSpec, s conversion.Scope) error {
- out.Replicas = &in.Replicas
- out.Selector = in.Selector
- //if in.TemplateRef != nil {
- // out.TemplateRef = new(ObjectReference)
- // if err := Convert_api_ObjectReference_To_v1_ObjectReference(in.TemplateRef, out.TemplateRef, s); err != nil {
- // return err
- // }
- //} else {
- // out.TemplateRef = nil
- //}
- if in.Template != nil {
- out.Template = new(PodTemplateSpec)
- if err := Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(in.Template, out.Template, s); err != nil {
- return err
- }
- } else {
- out.Template = nil
- }
- return nil
-}
-
-func Convert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec(in *ReplicationControllerSpec, out *api.ReplicationControllerSpec, s conversion.Scope) error {
- out.Replicas = *in.Replicas
- out.Selector = in.Selector
-
- //if in.TemplateRef != nil {
- // out.TemplateRef = new(api.ObjectReference)
- // if err := Convert_v1_ObjectReference_To_api_ObjectReference(in.TemplateRef, out.TemplateRef, s); err != nil {
- // return err
- // }
- //} else {
- // out.TemplateRef = nil
- //}
- if in.Template != nil {
- out.Template = new(api.PodTemplateSpec)
- if err := Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in.Template, out.Template, s); err != nil {
- return err
- }
- } else {
- out.Template = nil
- }
- return nil
-}
-
-func Convert_api_PodStatusResult_To_v1_PodStatusResult(in *api.PodStatusResult, out *PodStatusResult, s conversion.Scope) error {
- if err := autoConvert_api_PodStatusResult_To_v1_PodStatusResult(in, out, s); err != nil {
- return err
- }
-
- if old := out.Annotations; old != nil {
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- }
- if len(out.Status.InitContainerStatuses) > 0 {
- if out.Annotations == nil {
- out.Annotations = make(map[string]string)
- }
- value, err := json.Marshal(out.Status.InitContainerStatuses)
- if err != nil {
- return err
- }
- out.Annotations[PodInitContainerStatusesAnnotationKey] = string(value)
- } else {
- delete(out.Annotations, PodInitContainerStatusesAnnotationKey)
- }
- return nil
-}
-
-func Convert_v1_PodStatusResult_To_api_PodStatusResult(in *PodStatusResult, out *api.PodStatusResult, s conversion.Scope) error {
- // TODO: when we move init container to beta, remove these conversions
- if value, ok := in.Annotations[PodInitContainerStatusesAnnotationKey]; ok {
- var values []ContainerStatus
- if err := json.Unmarshal([]byte(value), &values); err != nil {
- return err
- }
- // Conversion from external to internal version exists more to
- // satisfy the needs of the decoder than it does to be a general
- // purpose tool. And Decode always creates an intermediate object
- // to decode to. Thus the caller of UnsafeConvertToVersion is
- // taking responsibility to ensure mutation of in is not exposed
- // back to the caller.
- in.Status.InitContainerStatuses = values
- }
-
- if err := autoConvert_v1_PodStatusResult_To_api_PodStatusResult(in, out, s); err != nil {
- return err
- }
- if len(out.Annotations) > 0 {
- old := out.Annotations
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- delete(out.Annotations, PodInitContainerStatusesAnnotationKey)
- }
- return nil
-}
-
-func Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(in *api.PodTemplateSpec, out *PodTemplateSpec, s conversion.Scope) error {
- if err := autoConvert_api_PodTemplateSpec_To_v1_PodTemplateSpec(in, out, s); err != nil {
- return err
- }
-
- // TODO: when we move init container to beta, remove these conversions
- if old := out.Annotations; old != nil {
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- }
- if len(out.Spec.InitContainers) > 0 {
- if out.Annotations == nil {
- out.Annotations = make(map[string]string)
- }
- value, err := json.Marshal(out.Spec.InitContainers)
- if err != nil {
- return err
- }
- out.Annotations[PodInitContainersAnnotationKey] = string(value)
- } else {
- delete(out.Annotations, PodInitContainersAnnotationKey)
- }
- return nil
-}
-
-func Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in *PodTemplateSpec, out *api.PodTemplateSpec, s conversion.Scope) error {
- // TODO: when we move init container to beta, remove these conversions
- if value, ok := in.Annotations[PodInitContainersAnnotationKey]; ok {
- var values []Container
- if err := json.Unmarshal([]byte(value), &values); err != nil {
- return err
- }
- // Conversion from external to internal version exists more to
- // satisfy the needs of the decoder than it does to be a general
- // purpose tool. And Decode always creates an intermediate object
- // to decode to. Thus the caller of UnsafeConvertToVersion is
- // taking responsibility to ensure mutation of in is not exposed
- // back to the caller.
- in.Spec.InitContainers = values
- }
-
- if err := autoConvert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in, out, s); err != nil {
- return err
- }
- if len(out.Annotations) > 0 {
- old := out.Annotations
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- delete(out.Annotations, PodInitContainersAnnotationKey)
- }
- return nil
-}
-
-// The following two PodSpec conversions are done here to support ServiceAccount
-// as an alias for ServiceAccountName.
-func Convert_api_PodSpec_To_v1_PodSpec(in *api.PodSpec, out *PodSpec, s conversion.Scope) error {
- if err := autoConvert_api_PodSpec_To_v1_PodSpec(in, out, s); err != nil {
- return err
- }
-
- // DeprecatedServiceAccount is an alias for ServiceAccountName.
- out.DeprecatedServiceAccount = in.ServiceAccountName
-
- if in.SecurityContext != nil {
- // the host namespace fields have to be handled here for backward compatibility
- // with v1.0.0
- out.HostPID = in.SecurityContext.HostPID
- out.HostNetwork = in.SecurityContext.HostNetwork
- out.HostIPC = in.SecurityContext.HostIPC
- }
-
- return nil
-}
-
-func Convert_v1_PodSpec_To_api_PodSpec(in *PodSpec, out *api.PodSpec, s conversion.Scope) error {
- if err := autoConvert_v1_PodSpec_To_api_PodSpec(in, out, s); err != nil {
- return err
- }
-
- // We support DeprecatedServiceAccount as an alias for ServiceAccountName.
- // If both are specified, ServiceAccountName (the new field) wins.
- if in.ServiceAccountName == "" {
- out.ServiceAccountName = in.DeprecatedServiceAccount
- }
-
- // the host namespace fields have to be handled specially for backward compatibility
- // with v1.0.0
- if out.SecurityContext == nil {
- out.SecurityContext = new(api.PodSecurityContext)
- }
- out.SecurityContext.HostNetwork = in.HostNetwork
- out.SecurityContext.HostPID = in.HostPID
- out.SecurityContext.HostIPC = in.HostIPC
-
- return nil
-}
-
-func Convert_api_Pod_To_v1_Pod(in *api.Pod, out *Pod, s conversion.Scope) error {
- if err := autoConvert_api_Pod_To_v1_Pod(in, out, s); err != nil {
- return err
- }
-
- // TODO: when we move init container to beta, remove these conversions
- if len(out.Spec.InitContainers) > 0 || len(out.Status.InitContainerStatuses) > 0 {
- old := out.Annotations
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- delete(out.Annotations, PodInitContainersAnnotationKey)
- delete(out.Annotations, PodInitContainerStatusesAnnotationKey)
- }
- if len(out.Spec.InitContainers) > 0 {
- value, err := json.Marshal(out.Spec.InitContainers)
- if err != nil {
- return err
- }
- out.Annotations[PodInitContainersAnnotationKey] = string(value)
- }
- if len(out.Status.InitContainerStatuses) > 0 {
- value, err := json.Marshal(out.Status.InitContainerStatuses)
- if err != nil {
- return err
- }
- out.Annotations[PodInitContainerStatusesAnnotationKey] = string(value)
- }
-
- // We need to reset certain fields for mirror pods from pre-v1.1 kubelet
- // (#15960).
- // TODO: Remove this code after we drop support for v1.0 kubelets.
- if value, ok := in.Annotations[mirrorAnnotationKey]; ok && value == mirrorAnnotationValue_1_0 {
- // Reset the TerminationGracePeriodSeconds.
- out.Spec.TerminationGracePeriodSeconds = nil
- // Reset the resource requests.
- for i := range out.Spec.Containers {
- out.Spec.Containers[i].Resources.Requests = nil
- }
- }
- return nil
-}
-
-func Convert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) error {
- // TODO: when we move init container to beta, remove these conversions
- if value, ok := in.Annotations[PodInitContainersAnnotationKey]; ok {
- var values []Container
- if err := json.Unmarshal([]byte(value), &values); err != nil {
- return err
- }
- // Conversion from external to internal version exists more to
- // satisfy the needs of the decoder than it does to be a general
- // purpose tool. And Decode always creates an intermediate object
- // to decode to. Thus the caller of UnsafeConvertToVersion is
- // taking responsibility to ensure mutation of in is not exposed
- // back to the caller.
- in.Spec.InitContainers = values
- }
- if value, ok := in.Annotations[PodInitContainerStatusesAnnotationKey]; ok {
- var values []ContainerStatus
- if err := json.Unmarshal([]byte(value), &values); err != nil {
- return err
- }
- // Conversion from external to internal version exists more to
- // satisfy the needs of the decoder than it does to be a general
- // purpose tool. And Decode always creates an intermediate object
- // to decode to. Thus the caller of UnsafeConvertToVersion is
- // taking responsibility to ensure mutation of in is not exposed
- // back to the caller.
- in.Status.InitContainerStatuses = values
- }
-
- if err := autoConvert_v1_Pod_To_api_Pod(in, out, s); err != nil {
- return err
- }
- if len(out.Annotations) > 0 {
- old := out.Annotations
- out.Annotations = make(map[string]string, len(old))
- for k, v := range old {
- out.Annotations[k] = v
- }
- delete(out.Annotations, PodInitContainersAnnotationKey)
- delete(out.Annotations, PodInitContainerStatusesAnnotationKey)
- }
- return nil
-}
-
-func Convert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *ServiceSpec, s conversion.Scope) error {
- if err := autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in, out, s); err != nil {
- return err
- }
- // Publish both externalIPs and deprecatedPublicIPs fields in v1.
- out.DeprecatedPublicIPs = in.ExternalIPs
- return nil
-}
-
-func Convert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversion.Scope) error {
- if err := autoConvert_v1_Secret_To_api_Secret(in, out, s); err != nil {
- return err
- }
-
- // StringData overwrites Data
- if len(in.StringData) > 0 {
- if out.Data == nil {
- out.Data = map[string][]byte{}
- }
- for k, v := range in.StringData {
- out.Data[k] = []byte(v)
- }
- }
-
- return nil
-}
-
-func Convert_v1_ServiceSpec_To_api_ServiceSpec(in *ServiceSpec, out *api.ServiceSpec, s conversion.Scope) error {
- if err := autoConvert_v1_ServiceSpec_To_api_ServiceSpec(in, out, s); err != nil {
- return err
- }
- // Prefer the legacy deprecatedPublicIPs field, if provided.
- if len(in.DeprecatedPublicIPs) > 0 {
- out.ExternalIPs = in.DeprecatedPublicIPs
- }
- return nil
-}
-
-func Convert_api_PodSecurityContext_To_v1_PodSecurityContext(in *api.PodSecurityContext, out *PodSecurityContext, s conversion.Scope) error {
- out.SupplementalGroups = in.SupplementalGroups
- if in.SELinuxOptions != nil {
- out.SELinuxOptions = new(SELinuxOptions)
- if err := Convert_api_SELinuxOptions_To_v1_SELinuxOptions(in.SELinuxOptions, out.SELinuxOptions, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.FSGroup = in.FSGroup
- return nil
-}
-
-func Convert_v1_PodSecurityContext_To_api_PodSecurityContext(in *PodSecurityContext, out *api.PodSecurityContext, s conversion.Scope) error {
- out.SupplementalGroups = in.SupplementalGroups
- if in.SELinuxOptions != nil {
- out.SELinuxOptions = new(api.SELinuxOptions)
- if err := Convert_v1_SELinuxOptions_To_api_SELinuxOptions(in.SELinuxOptions, out.SELinuxOptions, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.FSGroup = in.FSGroup
- return nil
-}
-
-func Convert_v1_ResourceList_To_api_ResourceList(in *ResourceList, out *api.ResourceList, s conversion.Scope) error {
- if *in == nil {
- return nil
- }
-
- if *out == nil {
- *out = make(api.ResourceList, len(*in))
- }
- for key, val := range *in {
- // TODO(#18538): We round up resource values to milli scale to maintain API compatibility.
- // In the future, we should instead reject values that need rounding.
- const milliScale = -3
- val.RoundUp(milliScale)
-
- (*out)[api.ResourceName(key)] = val
- }
- return nil
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion_generated.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion_generated.go
deleted file mode 100644
index a9cb349..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/conversion_generated.go
+++ /dev/null
@@ -1,6820 +0,0 @@
-// +build !ignore_autogenerated
-
-/*
-Copyright 2016 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.
-*/
-
-// This file was autogenerated by conversion-gen. Do not edit it manually!
-
-package v1
-
-import (
- api "k8s.io/kubernetes/pkg/api"
- resource "k8s.io/kubernetes/pkg/api/resource"
- conversion "k8s.io/kubernetes/pkg/conversion"
- runtime "k8s.io/kubernetes/pkg/runtime"
- types "k8s.io/kubernetes/pkg/types"
-)
-
-func init() {
- if err := api.Scheme.AddGeneratedConversionFuncs(
- Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource,
- Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource,
- Convert_v1_Affinity_To_api_Affinity,
- Convert_api_Affinity_To_v1_Affinity,
- Convert_v1_AttachedVolume_To_api_AttachedVolume,
- Convert_api_AttachedVolume_To_v1_AttachedVolume,
- Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource,
- Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource,
- Convert_v1_Binding_To_api_Binding,
- Convert_api_Binding_To_v1_Binding,
- Convert_v1_Capabilities_To_api_Capabilities,
- Convert_api_Capabilities_To_v1_Capabilities,
- Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource,
- Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource,
- Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource,
- Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource,
- Convert_v1_ComponentCondition_To_api_ComponentCondition,
- Convert_api_ComponentCondition_To_v1_ComponentCondition,
- Convert_v1_ComponentStatus_To_api_ComponentStatus,
- Convert_api_ComponentStatus_To_v1_ComponentStatus,
- Convert_v1_ComponentStatusList_To_api_ComponentStatusList,
- Convert_api_ComponentStatusList_To_v1_ComponentStatusList,
- Convert_v1_ConfigMap_To_api_ConfigMap,
- Convert_api_ConfigMap_To_v1_ConfigMap,
- Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector,
- Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector,
- Convert_v1_ConfigMapList_To_api_ConfigMapList,
- Convert_api_ConfigMapList_To_v1_ConfigMapList,
- Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource,
- Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource,
- Convert_v1_Container_To_api_Container,
- Convert_api_Container_To_v1_Container,
- Convert_v1_ContainerImage_To_api_ContainerImage,
- Convert_api_ContainerImage_To_v1_ContainerImage,
- Convert_v1_ContainerPort_To_api_ContainerPort,
- Convert_api_ContainerPort_To_v1_ContainerPort,
- Convert_v1_ContainerState_To_api_ContainerState,
- Convert_api_ContainerState_To_v1_ContainerState,
- Convert_v1_ContainerStateRunning_To_api_ContainerStateRunning,
- Convert_api_ContainerStateRunning_To_v1_ContainerStateRunning,
- Convert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated,
- Convert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated,
- Convert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting,
- Convert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting,
- Convert_v1_ContainerStatus_To_api_ContainerStatus,
- Convert_api_ContainerStatus_To_v1_ContainerStatus,
- Convert_v1_DaemonEndpoint_To_api_DaemonEndpoint,
- Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint,
- Convert_v1_DeleteOptions_To_api_DeleteOptions,
- Convert_api_DeleteOptions_To_v1_DeleteOptions,
- Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile,
- Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile,
- Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource,
- Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource,
- Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource,
- Convert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource,
- Convert_v1_EndpointAddress_To_api_EndpointAddress,
- Convert_api_EndpointAddress_To_v1_EndpointAddress,
- Convert_v1_EndpointPort_To_api_EndpointPort,
- Convert_api_EndpointPort_To_v1_EndpointPort,
- Convert_v1_EndpointSubset_To_api_EndpointSubset,
- Convert_api_EndpointSubset_To_v1_EndpointSubset,
- Convert_v1_Endpoints_To_api_Endpoints,
- Convert_api_Endpoints_To_v1_Endpoints,
- Convert_v1_EndpointsList_To_api_EndpointsList,
- Convert_api_EndpointsList_To_v1_EndpointsList,
- Convert_v1_EnvVar_To_api_EnvVar,
- Convert_api_EnvVar_To_v1_EnvVar,
- Convert_v1_EnvVarSource_To_api_EnvVarSource,
- Convert_api_EnvVarSource_To_v1_EnvVarSource,
- Convert_v1_Event_To_api_Event,
- Convert_api_Event_To_v1_Event,
- Convert_v1_EventList_To_api_EventList,
- Convert_api_EventList_To_v1_EventList,
- Convert_v1_EventSource_To_api_EventSource,
- Convert_api_EventSource_To_v1_EventSource,
- Convert_v1_ExecAction_To_api_ExecAction,
- Convert_api_ExecAction_To_v1_ExecAction,
- Convert_v1_ExportOptions_To_api_ExportOptions,
- Convert_api_ExportOptions_To_v1_ExportOptions,
- Convert_v1_FCVolumeSource_To_api_FCVolumeSource,
- Convert_api_FCVolumeSource_To_v1_FCVolumeSource,
- Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource,
- Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource,
- Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource,
- Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource,
- Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource,
- Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource,
- Convert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource,
- Convert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource,
- Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource,
- Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource,
- Convert_v1_HTTPGetAction_To_api_HTTPGetAction,
- Convert_api_HTTPGetAction_To_v1_HTTPGetAction,
- Convert_v1_HTTPHeader_To_api_HTTPHeader,
- Convert_api_HTTPHeader_To_v1_HTTPHeader,
- Convert_v1_Handler_To_api_Handler,
- Convert_api_Handler_To_v1_Handler,
- Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource,
- Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource,
- Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource,
- Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource,
- Convert_v1_KeyToPath_To_api_KeyToPath,
- Convert_api_KeyToPath_To_v1_KeyToPath,
- Convert_v1_Lifecycle_To_api_Lifecycle,
- Convert_api_Lifecycle_To_v1_Lifecycle,
- Convert_v1_LimitRange_To_api_LimitRange,
- Convert_api_LimitRange_To_v1_LimitRange,
- Convert_v1_LimitRangeItem_To_api_LimitRangeItem,
- Convert_api_LimitRangeItem_To_v1_LimitRangeItem,
- Convert_v1_LimitRangeList_To_api_LimitRangeList,
- Convert_api_LimitRangeList_To_v1_LimitRangeList,
- Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec,
- Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec,
- Convert_v1_List_To_api_List,
- Convert_api_List_To_v1_List,
- Convert_v1_ListOptions_To_api_ListOptions,
- Convert_api_ListOptions_To_v1_ListOptions,
- Convert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress,
- Convert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress,
- Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus,
- Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus,
- Convert_v1_LocalObjectReference_To_api_LocalObjectReference,
- Convert_api_LocalObjectReference_To_v1_LocalObjectReference,
- Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource,
- Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource,
- Convert_v1_Namespace_To_api_Namespace,
- Convert_api_Namespace_To_v1_Namespace,
- Convert_v1_NamespaceList_To_api_NamespaceList,
- Convert_api_NamespaceList_To_v1_NamespaceList,
- Convert_v1_NamespaceSpec_To_api_NamespaceSpec,
- Convert_api_NamespaceSpec_To_v1_NamespaceSpec,
- Convert_v1_NamespaceStatus_To_api_NamespaceStatus,
- Convert_api_NamespaceStatus_To_v1_NamespaceStatus,
- Convert_v1_Node_To_api_Node,
- Convert_api_Node_To_v1_Node,
- Convert_v1_NodeAddress_To_api_NodeAddress,
- Convert_api_NodeAddress_To_v1_NodeAddress,
- Convert_v1_NodeAffinity_To_api_NodeAffinity,
- Convert_api_NodeAffinity_To_v1_NodeAffinity,
- Convert_v1_NodeCondition_To_api_NodeCondition,
- Convert_api_NodeCondition_To_v1_NodeCondition,
- Convert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints,
- Convert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints,
- Convert_v1_NodeList_To_api_NodeList,
- Convert_api_NodeList_To_v1_NodeList,
- Convert_v1_NodeProxyOptions_To_api_NodeProxyOptions,
- Convert_api_NodeProxyOptions_To_v1_NodeProxyOptions,
- Convert_v1_NodeSelector_To_api_NodeSelector,
- Convert_api_NodeSelector_To_v1_NodeSelector,
- Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement,
- Convert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement,
- Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm,
- Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm,
- Convert_v1_NodeSpec_To_api_NodeSpec,
- Convert_api_NodeSpec_To_v1_NodeSpec,
- Convert_v1_NodeStatus_To_api_NodeStatus,
- Convert_api_NodeStatus_To_v1_NodeStatus,
- Convert_v1_NodeSystemInfo_To_api_NodeSystemInfo,
- Convert_api_NodeSystemInfo_To_v1_NodeSystemInfo,
- Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector,
- Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector,
- Convert_v1_ObjectMeta_To_api_ObjectMeta,
- Convert_api_ObjectMeta_To_v1_ObjectMeta,
- Convert_v1_ObjectReference_To_api_ObjectReference,
- Convert_api_ObjectReference_To_v1_ObjectReference,
- Convert_v1_OwnerReference_To_api_OwnerReference,
- Convert_api_OwnerReference_To_v1_OwnerReference,
- Convert_v1_PersistentVolume_To_api_PersistentVolume,
- Convert_api_PersistentVolume_To_v1_PersistentVolume,
- Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim,
- Convert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim,
- Convert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList,
- Convert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList,
- Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec,
- Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec,
- Convert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus,
- Convert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus,
- Convert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource,
- Convert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource,
- Convert_v1_PersistentVolumeList_To_api_PersistentVolumeList,
- Convert_api_PersistentVolumeList_To_v1_PersistentVolumeList,
- Convert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource,
- Convert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource,
- Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec,
- Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec,
- Convert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus,
- Convert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus,
- Convert_v1_Pod_To_api_Pod,
- Convert_api_Pod_To_v1_Pod,
- Convert_v1_PodAffinity_To_api_PodAffinity,
- Convert_api_PodAffinity_To_v1_PodAffinity,
- Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm,
- Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm,
- Convert_v1_PodAntiAffinity_To_api_PodAntiAffinity,
- Convert_api_PodAntiAffinity_To_v1_PodAntiAffinity,
- Convert_v1_PodAttachOptions_To_api_PodAttachOptions,
- Convert_api_PodAttachOptions_To_v1_PodAttachOptions,
- Convert_v1_PodCondition_To_api_PodCondition,
- Convert_api_PodCondition_To_v1_PodCondition,
- Convert_v1_PodExecOptions_To_api_PodExecOptions,
- Convert_api_PodExecOptions_To_v1_PodExecOptions,
- Convert_v1_PodList_To_api_PodList,
- Convert_api_PodList_To_v1_PodList,
- Convert_v1_PodLogOptions_To_api_PodLogOptions,
- Convert_api_PodLogOptions_To_v1_PodLogOptions,
- Convert_v1_PodProxyOptions_To_api_PodProxyOptions,
- Convert_api_PodProxyOptions_To_v1_PodProxyOptions,
- Convert_v1_PodSecurityContext_To_api_PodSecurityContext,
- Convert_api_PodSecurityContext_To_v1_PodSecurityContext,
- Convert_v1_PodSpec_To_api_PodSpec,
- Convert_api_PodSpec_To_v1_PodSpec,
- Convert_v1_PodStatus_To_api_PodStatus,
- Convert_api_PodStatus_To_v1_PodStatus,
- Convert_v1_PodStatusResult_To_api_PodStatusResult,
- Convert_api_PodStatusResult_To_v1_PodStatusResult,
- Convert_v1_PodTemplate_To_api_PodTemplate,
- Convert_api_PodTemplate_To_v1_PodTemplate,
- Convert_v1_PodTemplateList_To_api_PodTemplateList,
- Convert_api_PodTemplateList_To_v1_PodTemplateList,
- Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec,
- Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec,
- Convert_v1_Preconditions_To_api_Preconditions,
- Convert_api_Preconditions_To_v1_Preconditions,
- Convert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm,
- Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm,
- Convert_v1_Probe_To_api_Probe,
- Convert_api_Probe_To_v1_Probe,
- Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource,
- Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource,
- Convert_v1_RangeAllocation_To_api_RangeAllocation,
- Convert_api_RangeAllocation_To_v1_RangeAllocation,
- Convert_v1_ReplicationController_To_api_ReplicationController,
- Convert_api_ReplicationController_To_v1_ReplicationController,
- Convert_v1_ReplicationControllerList_To_api_ReplicationControllerList,
- Convert_api_ReplicationControllerList_To_v1_ReplicationControllerList,
- Convert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec,
- Convert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec,
- Convert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus,
- Convert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus,
- Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector,
- Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector,
- Convert_v1_ResourceQuota_To_api_ResourceQuota,
- Convert_api_ResourceQuota_To_v1_ResourceQuota,
- Convert_v1_ResourceQuotaList_To_api_ResourceQuotaList,
- Convert_api_ResourceQuotaList_To_v1_ResourceQuotaList,
- Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec,
- Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec,
- Convert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus,
- Convert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus,
- Convert_v1_ResourceRequirements_To_api_ResourceRequirements,
- Convert_api_ResourceRequirements_To_v1_ResourceRequirements,
- Convert_v1_SELinuxOptions_To_api_SELinuxOptions,
- Convert_api_SELinuxOptions_To_v1_SELinuxOptions,
- Convert_v1_Secret_To_api_Secret,
- Convert_api_Secret_To_v1_Secret,
- Convert_v1_SecretKeySelector_To_api_SecretKeySelector,
- Convert_api_SecretKeySelector_To_v1_SecretKeySelector,
- Convert_v1_SecretList_To_api_SecretList,
- Convert_api_SecretList_To_v1_SecretList,
- Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource,
- Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource,
- Convert_v1_SecurityContext_To_api_SecurityContext,
- Convert_api_SecurityContext_To_v1_SecurityContext,
- Convert_v1_SerializedReference_To_api_SerializedReference,
- Convert_api_SerializedReference_To_v1_SerializedReference,
- Convert_v1_Service_To_api_Service,
- Convert_api_Service_To_v1_Service,
- Convert_v1_ServiceAccount_To_api_ServiceAccount,
- Convert_api_ServiceAccount_To_v1_ServiceAccount,
- Convert_v1_ServiceAccountList_To_api_ServiceAccountList,
- Convert_api_ServiceAccountList_To_v1_ServiceAccountList,
- Convert_v1_ServiceList_To_api_ServiceList,
- Convert_api_ServiceList_To_v1_ServiceList,
- Convert_v1_ServicePort_To_api_ServicePort,
- Convert_api_ServicePort_To_v1_ServicePort,
- Convert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions,
- Convert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions,
- Convert_v1_ServiceSpec_To_api_ServiceSpec,
- Convert_api_ServiceSpec_To_v1_ServiceSpec,
- Convert_v1_ServiceStatus_To_api_ServiceStatus,
- Convert_api_ServiceStatus_To_v1_ServiceStatus,
- Convert_v1_TCPSocketAction_To_api_TCPSocketAction,
- Convert_api_TCPSocketAction_To_v1_TCPSocketAction,
- Convert_v1_Taint_To_api_Taint,
- Convert_api_Taint_To_v1_Taint,
- Convert_v1_Toleration_To_api_Toleration,
- Convert_api_Toleration_To_v1_Toleration,
- Convert_v1_Volume_To_api_Volume,
- Convert_api_Volume_To_v1_Volume,
- Convert_v1_VolumeMount_To_api_VolumeMount,
- Convert_api_VolumeMount_To_v1_VolumeMount,
- Convert_v1_VolumeSource_To_api_VolumeSource,
- Convert_api_VolumeSource_To_v1_VolumeSource,
- Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource,
- Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource,
- Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm,
- Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm,
- ); err != nil {
- // if one of the conversion functions is malformed, detect it immediately.
- panic(err)
- }
-}
-
-func autoConvert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(in *AWSElasticBlockStoreVolumeSource, out *api.AWSElasticBlockStoreVolumeSource, s conversion.Scope) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(in *AWSElasticBlockStoreVolumeSource, out *api.AWSElasticBlockStoreVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(in, out, s)
-}
-
-func autoConvert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(in *api.AWSElasticBlockStoreVolumeSource, out *AWSElasticBlockStoreVolumeSource, s conversion.Scope) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(in *api.AWSElasticBlockStoreVolumeSource, out *AWSElasticBlockStoreVolumeSource, s conversion.Scope) error {
- return autoConvert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_Affinity_To_api_Affinity(in *Affinity, out *api.Affinity, s conversion.Scope) error {
- if in.NodeAffinity != nil {
- in, out := &in.NodeAffinity, &out.NodeAffinity
- *out = new(api.NodeAffinity)
- if err := Convert_v1_NodeAffinity_To_api_NodeAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NodeAffinity = nil
- }
- if in.PodAffinity != nil {
- in, out := &in.PodAffinity, &out.PodAffinity
- *out = new(api.PodAffinity)
- if err := Convert_v1_PodAffinity_To_api_PodAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PodAffinity = nil
- }
- if in.PodAntiAffinity != nil {
- in, out := &in.PodAntiAffinity, &out.PodAntiAffinity
- *out = new(api.PodAntiAffinity)
- if err := Convert_v1_PodAntiAffinity_To_api_PodAntiAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PodAntiAffinity = nil
- }
- return nil
-}
-
-func Convert_v1_Affinity_To_api_Affinity(in *Affinity, out *api.Affinity, s conversion.Scope) error {
- return autoConvert_v1_Affinity_To_api_Affinity(in, out, s)
-}
-
-func autoConvert_api_Affinity_To_v1_Affinity(in *api.Affinity, out *Affinity, s conversion.Scope) error {
- if in.NodeAffinity != nil {
- in, out := &in.NodeAffinity, &out.NodeAffinity
- *out = new(NodeAffinity)
- if err := Convert_api_NodeAffinity_To_v1_NodeAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NodeAffinity = nil
- }
- if in.PodAffinity != nil {
- in, out := &in.PodAffinity, &out.PodAffinity
- *out = new(PodAffinity)
- if err := Convert_api_PodAffinity_To_v1_PodAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PodAffinity = nil
- }
- if in.PodAntiAffinity != nil {
- in, out := &in.PodAntiAffinity, &out.PodAntiAffinity
- *out = new(PodAntiAffinity)
- if err := Convert_api_PodAntiAffinity_To_v1_PodAntiAffinity(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PodAntiAffinity = nil
- }
- return nil
-}
-
-func Convert_api_Affinity_To_v1_Affinity(in *api.Affinity, out *Affinity, s conversion.Scope) error {
- return autoConvert_api_Affinity_To_v1_Affinity(in, out, s)
-}
-
-func autoConvert_v1_AttachedVolume_To_api_AttachedVolume(in *AttachedVolume, out *api.AttachedVolume, s conversion.Scope) error {
- out.Name = api.UniqueVolumeName(in.Name)
- out.DevicePath = in.DevicePath
- return nil
-}
-
-func Convert_v1_AttachedVolume_To_api_AttachedVolume(in *AttachedVolume, out *api.AttachedVolume, s conversion.Scope) error {
- return autoConvert_v1_AttachedVolume_To_api_AttachedVolume(in, out, s)
-}
-
-func autoConvert_api_AttachedVolume_To_v1_AttachedVolume(in *api.AttachedVolume, out *AttachedVolume, s conversion.Scope) error {
- out.Name = UniqueVolumeName(in.Name)
- out.DevicePath = in.DevicePath
- return nil
-}
-
-func Convert_api_AttachedVolume_To_v1_AttachedVolume(in *api.AttachedVolume, out *AttachedVolume, s conversion.Scope) error {
- return autoConvert_api_AttachedVolume_To_v1_AttachedVolume(in, out, s)
-}
-
-func autoConvert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in *AzureFileVolumeSource, out *api.AzureFileVolumeSource, s conversion.Scope) error {
- out.SecretName = in.SecretName
- out.ShareName = in.ShareName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in *AzureFileVolumeSource, out *api.AzureFileVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in, out, s)
-}
-
-func autoConvert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in *api.AzureFileVolumeSource, out *AzureFileVolumeSource, s conversion.Scope) error {
- out.SecretName = in.SecretName
- out.ShareName = in.ShareName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in *api.AzureFileVolumeSource, out *AzureFileVolumeSource, s conversion.Scope) error {
- return autoConvert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_Binding_To_api_Binding(in *Binding, out *api.Binding, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(&in.Target, &out.Target, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_Binding_To_api_Binding(in *Binding, out *api.Binding, s conversion.Scope) error {
- return autoConvert_v1_Binding_To_api_Binding(in, out, s)
-}
-
-func autoConvert_api_Binding_To_v1_Binding(in *api.Binding, out *Binding, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(&in.Target, &out.Target, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_Binding_To_v1_Binding(in *api.Binding, out *Binding, s conversion.Scope) error {
- return autoConvert_api_Binding_To_v1_Binding(in, out, s)
-}
-
-func autoConvert_v1_Capabilities_To_api_Capabilities(in *Capabilities, out *api.Capabilities, s conversion.Scope) error {
- if in.Add != nil {
- in, out := &in.Add, &out.Add
- *out = make([]api.Capability, len(*in))
- for i := range *in {
- (*out)[i] = api.Capability((*in)[i])
- }
- } else {
- out.Add = nil
- }
- if in.Drop != nil {
- in, out := &in.Drop, &out.Drop
- *out = make([]api.Capability, len(*in))
- for i := range *in {
- (*out)[i] = api.Capability((*in)[i])
- }
- } else {
- out.Drop = nil
- }
- return nil
-}
-
-func Convert_v1_Capabilities_To_api_Capabilities(in *Capabilities, out *api.Capabilities, s conversion.Scope) error {
- return autoConvert_v1_Capabilities_To_api_Capabilities(in, out, s)
-}
-
-func autoConvert_api_Capabilities_To_v1_Capabilities(in *api.Capabilities, out *Capabilities, s conversion.Scope) error {
- if in.Add != nil {
- in, out := &in.Add, &out.Add
- *out = make([]Capability, len(*in))
- for i := range *in {
- (*out)[i] = Capability((*in)[i])
- }
- } else {
- out.Add = nil
- }
- if in.Drop != nil {
- in, out := &in.Drop, &out.Drop
- *out = make([]Capability, len(*in))
- for i := range *in {
- (*out)[i] = Capability((*in)[i])
- }
- } else {
- out.Drop = nil
- }
- return nil
-}
-
-func Convert_api_Capabilities_To_v1_Capabilities(in *api.Capabilities, out *Capabilities, s conversion.Scope) error {
- return autoConvert_api_Capabilities_To_v1_Capabilities(in, out, s)
-}
-
-func autoConvert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in *CephFSVolumeSource, out *api.CephFSVolumeSource, s conversion.Scope) error {
- out.Monitors = in.Monitors
- out.Path = in.Path
- out.User = in.User
- out.SecretFile = in.SecretFile
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(api.LocalObjectReference)
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in *CephFSVolumeSource, out *api.CephFSVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in, out, s)
-}
-
-func autoConvert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in *api.CephFSVolumeSource, out *CephFSVolumeSource, s conversion.Scope) error {
- out.Monitors = in.Monitors
- out.Path = in.Path
- out.User = in.User
- out.SecretFile = in.SecretFile
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in *api.CephFSVolumeSource, out *CephFSVolumeSource, s conversion.Scope) error {
- return autoConvert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in *CinderVolumeSource, out *api.CinderVolumeSource, s conversion.Scope) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in *CinderVolumeSource, out *api.CinderVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in, out, s)
-}
-
-func autoConvert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in *api.CinderVolumeSource, out *CinderVolumeSource, s conversion.Scope) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in *api.CinderVolumeSource, out *CinderVolumeSource, s conversion.Scope) error {
- return autoConvert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_ComponentCondition_To_api_ComponentCondition(in *ComponentCondition, out *api.ComponentCondition, s conversion.Scope) error {
- out.Type = api.ComponentConditionType(in.Type)
- out.Status = api.ConditionStatus(in.Status)
- out.Message = in.Message
- out.Error = in.Error
- return nil
-}
-
-func Convert_v1_ComponentCondition_To_api_ComponentCondition(in *ComponentCondition, out *api.ComponentCondition, s conversion.Scope) error {
- return autoConvert_v1_ComponentCondition_To_api_ComponentCondition(in, out, s)
-}
-
-func autoConvert_api_ComponentCondition_To_v1_ComponentCondition(in *api.ComponentCondition, out *ComponentCondition, s conversion.Scope) error {
- out.Type = ComponentConditionType(in.Type)
- out.Status = ConditionStatus(in.Status)
- out.Message = in.Message
- out.Error = in.Error
- return nil
-}
-
-func Convert_api_ComponentCondition_To_v1_ComponentCondition(in *api.ComponentCondition, out *ComponentCondition, s conversion.Scope) error {
- return autoConvert_api_ComponentCondition_To_v1_ComponentCondition(in, out, s)
-}
-
-func autoConvert_v1_ComponentStatus_To_api_ComponentStatus(in *ComponentStatus, out *api.ComponentStatus, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]api.ComponentCondition, len(*in))
- for i := range *in {
- if err := Convert_v1_ComponentCondition_To_api_ComponentCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- return nil
-}
-
-func Convert_v1_ComponentStatus_To_api_ComponentStatus(in *ComponentStatus, out *api.ComponentStatus, s conversion.Scope) error {
- return autoConvert_v1_ComponentStatus_To_api_ComponentStatus(in, out, s)
-}
-
-func autoConvert_api_ComponentStatus_To_v1_ComponentStatus(in *api.ComponentStatus, out *ComponentStatus, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]ComponentCondition, len(*in))
- for i := range *in {
- if err := Convert_api_ComponentCondition_To_v1_ComponentCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- return nil
-}
-
-func Convert_api_ComponentStatus_To_v1_ComponentStatus(in *api.ComponentStatus, out *ComponentStatus, s conversion.Scope) error {
- return autoConvert_api_ComponentStatus_To_v1_ComponentStatus(in, out, s)
-}
-
-func autoConvert_v1_ComponentStatusList_To_api_ComponentStatusList(in *ComponentStatusList, out *api.ComponentStatusList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.ComponentStatus, len(*in))
- for i := range *in {
- if err := Convert_v1_ComponentStatus_To_api_ComponentStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ComponentStatusList_To_api_ComponentStatusList(in *ComponentStatusList, out *api.ComponentStatusList, s conversion.Scope) error {
- return autoConvert_v1_ComponentStatusList_To_api_ComponentStatusList(in, out, s)
-}
-
-func autoConvert_api_ComponentStatusList_To_v1_ComponentStatusList(in *api.ComponentStatusList, out *ComponentStatusList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ComponentStatus, len(*in))
- for i := range *in {
- if err := Convert_api_ComponentStatus_To_v1_ComponentStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ComponentStatusList_To_v1_ComponentStatusList(in *api.ComponentStatusList, out *ComponentStatusList, s conversion.Scope) error {
- return autoConvert_api_ComponentStatusList_To_v1_ComponentStatusList(in, out, s)
-}
-
-func autoConvert_v1_ConfigMap_To_api_ConfigMap(in *ConfigMap, out *api.ConfigMap, s conversion.Scope) error {
- SetDefaults_ConfigMap(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Data = in.Data
- return nil
-}
-
-func Convert_v1_ConfigMap_To_api_ConfigMap(in *ConfigMap, out *api.ConfigMap, s conversion.Scope) error {
- return autoConvert_v1_ConfigMap_To_api_ConfigMap(in, out, s)
-}
-
-func autoConvert_api_ConfigMap_To_v1_ConfigMap(in *api.ConfigMap, out *ConfigMap, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Data = in.Data
- return nil
-}
-
-func Convert_api_ConfigMap_To_v1_ConfigMap(in *api.ConfigMap, out *ConfigMap, s conversion.Scope) error {
- return autoConvert_api_ConfigMap_To_v1_ConfigMap(in, out, s)
-}
-
-func autoConvert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in *ConfigMapKeySelector, out *api.ConfigMapKeySelector, s conversion.Scope) error {
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- out.Key = in.Key
- return nil
-}
-
-func Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in *ConfigMapKeySelector, out *api.ConfigMapKeySelector, s conversion.Scope) error {
- return autoConvert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in, out, s)
-}
-
-func autoConvert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in *api.ConfigMapKeySelector, out *ConfigMapKeySelector, s conversion.Scope) error {
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- out.Key = in.Key
- return nil
-}
-
-func Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in *api.ConfigMapKeySelector, out *ConfigMapKeySelector, s conversion.Scope) error {
- return autoConvert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in, out, s)
-}
-
-func autoConvert_v1_ConfigMapList_To_api_ConfigMapList(in *ConfigMapList, out *api.ConfigMapList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.ConfigMap, len(*in))
- for i := range *in {
- if err := Convert_v1_ConfigMap_To_api_ConfigMap(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ConfigMapList_To_api_ConfigMapList(in *ConfigMapList, out *api.ConfigMapList, s conversion.Scope) error {
- return autoConvert_v1_ConfigMapList_To_api_ConfigMapList(in, out, s)
-}
-
-func autoConvert_api_ConfigMapList_To_v1_ConfigMapList(in *api.ConfigMapList, out *ConfigMapList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ConfigMap, len(*in))
- for i := range *in {
- if err := Convert_api_ConfigMap_To_v1_ConfigMap(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ConfigMapList_To_v1_ConfigMapList(in *api.ConfigMapList, out *ConfigMapList, s conversion.Scope) error {
- return autoConvert_api_ConfigMapList_To_v1_ConfigMapList(in, out, s)
-}
-
-func autoConvert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in *ConfigMapVolumeSource, out *api.ConfigMapVolumeSource, s conversion.Scope) error {
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.KeyToPath, len(*in))
- for i := range *in {
- if err := Convert_v1_KeyToPath_To_api_KeyToPath(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in *ConfigMapVolumeSource, out *api.ConfigMapVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in, out, s)
-}
-
-func autoConvert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in *api.ConfigMapVolumeSource, out *ConfigMapVolumeSource, s conversion.Scope) error {
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]KeyToPath, len(*in))
- for i := range *in {
- if err := Convert_api_KeyToPath_To_v1_KeyToPath(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in *api.ConfigMapVolumeSource, out *ConfigMapVolumeSource, s conversion.Scope) error {
- return autoConvert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_Container_To_api_Container(in *Container, out *api.Container, s conversion.Scope) error {
- SetDefaults_Container(in)
- out.Name = in.Name
- out.Image = in.Image
- out.Command = in.Command
- out.Args = in.Args
- out.WorkingDir = in.WorkingDir
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]api.ContainerPort, len(*in))
- for i := range *in {
- if err := Convert_v1_ContainerPort_To_api_ContainerPort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- if in.Env != nil {
- in, out := &in.Env, &out.Env
- *out = make([]api.EnvVar, len(*in))
- for i := range *in {
- if err := Convert_v1_EnvVar_To_api_EnvVar(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Env = nil
- }
- if err := Convert_v1_ResourceRequirements_To_api_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil {
- return err
- }
- if in.VolumeMounts != nil {
- in, out := &in.VolumeMounts, &out.VolumeMounts
- *out = make([]api.VolumeMount, len(*in))
- for i := range *in {
- if err := Convert_v1_VolumeMount_To_api_VolumeMount(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.VolumeMounts = nil
- }
- if in.LivenessProbe != nil {
- in, out := &in.LivenessProbe, &out.LivenessProbe
- *out = new(api.Probe)
- if err := Convert_v1_Probe_To_api_Probe(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.LivenessProbe = nil
- }
- if in.ReadinessProbe != nil {
- in, out := &in.ReadinessProbe, &out.ReadinessProbe
- *out = new(api.Probe)
- if err := Convert_v1_Probe_To_api_Probe(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ReadinessProbe = nil
- }
- if in.Lifecycle != nil {
- in, out := &in.Lifecycle, &out.Lifecycle
- *out = new(api.Lifecycle)
- if err := Convert_v1_Lifecycle_To_api_Lifecycle(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Lifecycle = nil
- }
- out.TerminationMessagePath = in.TerminationMessagePath
- out.ImagePullPolicy = api.PullPolicy(in.ImagePullPolicy)
- if in.SecurityContext != nil {
- in, out := &in.SecurityContext, &out.SecurityContext
- *out = new(api.SecurityContext)
- if err := Convert_v1_SecurityContext_To_api_SecurityContext(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- out.Stdin = in.Stdin
- out.StdinOnce = in.StdinOnce
- out.TTY = in.TTY
- return nil
-}
-
-func Convert_v1_Container_To_api_Container(in *Container, out *api.Container, s conversion.Scope) error {
- return autoConvert_v1_Container_To_api_Container(in, out, s)
-}
-
-func autoConvert_api_Container_To_v1_Container(in *api.Container, out *Container, s conversion.Scope) error {
- out.Name = in.Name
- out.Image = in.Image
- out.Command = in.Command
- out.Args = in.Args
- out.WorkingDir = in.WorkingDir
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]ContainerPort, len(*in))
- for i := range *in {
- if err := Convert_api_ContainerPort_To_v1_ContainerPort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- if in.Env != nil {
- in, out := &in.Env, &out.Env
- *out = make([]EnvVar, len(*in))
- for i := range *in {
- if err := Convert_api_EnvVar_To_v1_EnvVar(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Env = nil
- }
- if err := Convert_api_ResourceRequirements_To_v1_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil {
- return err
- }
- if in.VolumeMounts != nil {
- in, out := &in.VolumeMounts, &out.VolumeMounts
- *out = make([]VolumeMount, len(*in))
- for i := range *in {
- if err := Convert_api_VolumeMount_To_v1_VolumeMount(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.VolumeMounts = nil
- }
- if in.LivenessProbe != nil {
- in, out := &in.LivenessProbe, &out.LivenessProbe
- *out = new(Probe)
- if err := Convert_api_Probe_To_v1_Probe(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.LivenessProbe = nil
- }
- if in.ReadinessProbe != nil {
- in, out := &in.ReadinessProbe, &out.ReadinessProbe
- *out = new(Probe)
- if err := Convert_api_Probe_To_v1_Probe(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ReadinessProbe = nil
- }
- if in.Lifecycle != nil {
- in, out := &in.Lifecycle, &out.Lifecycle
- *out = new(Lifecycle)
- if err := Convert_api_Lifecycle_To_v1_Lifecycle(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Lifecycle = nil
- }
- out.TerminationMessagePath = in.TerminationMessagePath
- out.ImagePullPolicy = PullPolicy(in.ImagePullPolicy)
- if in.SecurityContext != nil {
- in, out := &in.SecurityContext, &out.SecurityContext
- *out = new(SecurityContext)
- if err := Convert_api_SecurityContext_To_v1_SecurityContext(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- out.Stdin = in.Stdin
- out.StdinOnce = in.StdinOnce
- out.TTY = in.TTY
- return nil
-}
-
-func Convert_api_Container_To_v1_Container(in *api.Container, out *Container, s conversion.Scope) error {
- return autoConvert_api_Container_To_v1_Container(in, out, s)
-}
-
-func autoConvert_v1_ContainerImage_To_api_ContainerImage(in *ContainerImage, out *api.ContainerImage, s conversion.Scope) error {
- out.Names = in.Names
- out.SizeBytes = in.SizeBytes
- return nil
-}
-
-func Convert_v1_ContainerImage_To_api_ContainerImage(in *ContainerImage, out *api.ContainerImage, s conversion.Scope) error {
- return autoConvert_v1_ContainerImage_To_api_ContainerImage(in, out, s)
-}
-
-func autoConvert_api_ContainerImage_To_v1_ContainerImage(in *api.ContainerImage, out *ContainerImage, s conversion.Scope) error {
- out.Names = in.Names
- out.SizeBytes = in.SizeBytes
- return nil
-}
-
-func Convert_api_ContainerImage_To_v1_ContainerImage(in *api.ContainerImage, out *ContainerImage, s conversion.Scope) error {
- return autoConvert_api_ContainerImage_To_v1_ContainerImage(in, out, s)
-}
-
-func autoConvert_v1_ContainerPort_To_api_ContainerPort(in *ContainerPort, out *api.ContainerPort, s conversion.Scope) error {
- SetDefaults_ContainerPort(in)
- out.Name = in.Name
- out.HostPort = in.HostPort
- out.ContainerPort = in.ContainerPort
- out.Protocol = api.Protocol(in.Protocol)
- out.HostIP = in.HostIP
- return nil
-}
-
-func Convert_v1_ContainerPort_To_api_ContainerPort(in *ContainerPort, out *api.ContainerPort, s conversion.Scope) error {
- return autoConvert_v1_ContainerPort_To_api_ContainerPort(in, out, s)
-}
-
-func autoConvert_api_ContainerPort_To_v1_ContainerPort(in *api.ContainerPort, out *ContainerPort, s conversion.Scope) error {
- out.Name = in.Name
- out.HostPort = in.HostPort
- out.ContainerPort = in.ContainerPort
- out.Protocol = Protocol(in.Protocol)
- out.HostIP = in.HostIP
- return nil
-}
-
-func Convert_api_ContainerPort_To_v1_ContainerPort(in *api.ContainerPort, out *ContainerPort, s conversion.Scope) error {
- return autoConvert_api_ContainerPort_To_v1_ContainerPort(in, out, s)
-}
-
-func autoConvert_v1_ContainerState_To_api_ContainerState(in *ContainerState, out *api.ContainerState, s conversion.Scope) error {
- if in.Waiting != nil {
- in, out := &in.Waiting, &out.Waiting
- *out = new(api.ContainerStateWaiting)
- if err := Convert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Waiting = nil
- }
- if in.Running != nil {
- in, out := &in.Running, &out.Running
- *out = new(api.ContainerStateRunning)
- if err := Convert_v1_ContainerStateRunning_To_api_ContainerStateRunning(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Running = nil
- }
- if in.Terminated != nil {
- in, out := &in.Terminated, &out.Terminated
- *out = new(api.ContainerStateTerminated)
- if err := Convert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Terminated = nil
- }
- return nil
-}
-
-func Convert_v1_ContainerState_To_api_ContainerState(in *ContainerState, out *api.ContainerState, s conversion.Scope) error {
- return autoConvert_v1_ContainerState_To_api_ContainerState(in, out, s)
-}
-
-func autoConvert_api_ContainerState_To_v1_ContainerState(in *api.ContainerState, out *ContainerState, s conversion.Scope) error {
- if in.Waiting != nil {
- in, out := &in.Waiting, &out.Waiting
- *out = new(ContainerStateWaiting)
- if err := Convert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Waiting = nil
- }
- if in.Running != nil {
- in, out := &in.Running, &out.Running
- *out = new(ContainerStateRunning)
- if err := Convert_api_ContainerStateRunning_To_v1_ContainerStateRunning(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Running = nil
- }
- if in.Terminated != nil {
- in, out := &in.Terminated, &out.Terminated
- *out = new(ContainerStateTerminated)
- if err := Convert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Terminated = nil
- }
- return nil
-}
-
-func Convert_api_ContainerState_To_v1_ContainerState(in *api.ContainerState, out *ContainerState, s conversion.Scope) error {
- return autoConvert_api_ContainerState_To_v1_ContainerState(in, out, s)
-}
-
-func autoConvert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in *ContainerStateRunning, out *api.ContainerStateRunning, s conversion.Scope) error {
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.StartedAt, &out.StartedAt, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in *ContainerStateRunning, out *api.ContainerStateRunning, s conversion.Scope) error {
- return autoConvert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in, out, s)
-}
-
-func autoConvert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in *api.ContainerStateRunning, out *ContainerStateRunning, s conversion.Scope) error {
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.StartedAt, &out.StartedAt, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in *api.ContainerStateRunning, out *ContainerStateRunning, s conversion.Scope) error {
- return autoConvert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in, out, s)
-}
-
-func autoConvert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in *ContainerStateTerminated, out *api.ContainerStateTerminated, s conversion.Scope) error {
- out.ExitCode = in.ExitCode
- out.Signal = in.Signal
- out.Reason = in.Reason
- out.Message = in.Message
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.StartedAt, &out.StartedAt, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.FinishedAt, &out.FinishedAt, s); err != nil {
- return err
- }
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func Convert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in *ContainerStateTerminated, out *api.ContainerStateTerminated, s conversion.Scope) error {
- return autoConvert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in, out, s)
-}
-
-func autoConvert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in *api.ContainerStateTerminated, out *ContainerStateTerminated, s conversion.Scope) error {
- out.ExitCode = in.ExitCode
- out.Signal = in.Signal
- out.Reason = in.Reason
- out.Message = in.Message
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.StartedAt, &out.StartedAt, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.FinishedAt, &out.FinishedAt, s); err != nil {
- return err
- }
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func Convert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in *api.ContainerStateTerminated, out *ContainerStateTerminated, s conversion.Scope) error {
- return autoConvert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in, out, s)
-}
-
-func autoConvert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in *ContainerStateWaiting, out *api.ContainerStateWaiting, s conversion.Scope) error {
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in *ContainerStateWaiting, out *api.ContainerStateWaiting, s conversion.Scope) error {
- return autoConvert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in, out, s)
-}
-
-func autoConvert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in *api.ContainerStateWaiting, out *ContainerStateWaiting, s conversion.Scope) error {
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in *api.ContainerStateWaiting, out *ContainerStateWaiting, s conversion.Scope) error {
- return autoConvert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in, out, s)
-}
-
-func autoConvert_v1_ContainerStatus_To_api_ContainerStatus(in *ContainerStatus, out *api.ContainerStatus, s conversion.Scope) error {
- out.Name = in.Name
- if err := Convert_v1_ContainerState_To_api_ContainerState(&in.State, &out.State, s); err != nil {
- return err
- }
- if err := Convert_v1_ContainerState_To_api_ContainerState(&in.LastTerminationState, &out.LastTerminationState, s); err != nil {
- return err
- }
- out.Ready = in.Ready
- out.RestartCount = in.RestartCount
- out.Image = in.Image
- out.ImageID = in.ImageID
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func Convert_v1_ContainerStatus_To_api_ContainerStatus(in *ContainerStatus, out *api.ContainerStatus, s conversion.Scope) error {
- return autoConvert_v1_ContainerStatus_To_api_ContainerStatus(in, out, s)
-}
-
-func autoConvert_api_ContainerStatus_To_v1_ContainerStatus(in *api.ContainerStatus, out *ContainerStatus, s conversion.Scope) error {
- out.Name = in.Name
- if err := Convert_api_ContainerState_To_v1_ContainerState(&in.State, &out.State, s); err != nil {
- return err
- }
- if err := Convert_api_ContainerState_To_v1_ContainerState(&in.LastTerminationState, &out.LastTerminationState, s); err != nil {
- return err
- }
- out.Ready = in.Ready
- out.RestartCount = in.RestartCount
- out.Image = in.Image
- out.ImageID = in.ImageID
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func Convert_api_ContainerStatus_To_v1_ContainerStatus(in *api.ContainerStatus, out *ContainerStatus, s conversion.Scope) error {
- return autoConvert_api_ContainerStatus_To_v1_ContainerStatus(in, out, s)
-}
-
-func autoConvert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in *DaemonEndpoint, out *api.DaemonEndpoint, s conversion.Scope) error {
- out.Port = in.Port
- return nil
-}
-
-func Convert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in *DaemonEndpoint, out *api.DaemonEndpoint, s conversion.Scope) error {
- return autoConvert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in, out, s)
-}
-
-func autoConvert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in *api.DaemonEndpoint, out *DaemonEndpoint, s conversion.Scope) error {
- out.Port = in.Port
- return nil
-}
-
-func Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in *api.DaemonEndpoint, out *DaemonEndpoint, s conversion.Scope) error {
- return autoConvert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in, out, s)
-}
-
-func autoConvert_v1_DeleteOptions_To_api_DeleteOptions(in *DeleteOptions, out *api.DeleteOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.GracePeriodSeconds = in.GracePeriodSeconds
- if in.Preconditions != nil {
- in, out := &in.Preconditions, &out.Preconditions
- *out = new(api.Preconditions)
- if err := Convert_v1_Preconditions_To_api_Preconditions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Preconditions = nil
- }
- out.OrphanDependents = in.OrphanDependents
- return nil
-}
-
-func Convert_v1_DeleteOptions_To_api_DeleteOptions(in *DeleteOptions, out *api.DeleteOptions, s conversion.Scope) error {
- return autoConvert_v1_DeleteOptions_To_api_DeleteOptions(in, out, s)
-}
-
-func autoConvert_api_DeleteOptions_To_v1_DeleteOptions(in *api.DeleteOptions, out *DeleteOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.GracePeriodSeconds = in.GracePeriodSeconds
- if in.Preconditions != nil {
- in, out := &in.Preconditions, &out.Preconditions
- *out = new(Preconditions)
- if err := Convert_api_Preconditions_To_v1_Preconditions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Preconditions = nil
- }
- out.OrphanDependents = in.OrphanDependents
- return nil
-}
-
-func Convert_api_DeleteOptions_To_v1_DeleteOptions(in *api.DeleteOptions, out *DeleteOptions, s conversion.Scope) error {
- return autoConvert_api_DeleteOptions_To_v1_DeleteOptions(in, out, s)
-}
-
-func autoConvert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in *DownwardAPIVolumeFile, out *api.DownwardAPIVolumeFile, s conversion.Scope) error {
- out.Path = in.Path
- if in.FieldRef != nil {
- in, out := &in.FieldRef, &out.FieldRef
- *out = new(api.ObjectFieldSelector)
- if err := Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := &in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(api.ResourceFieldSelector)
- if err := Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- return nil
-}
-
-func Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in *DownwardAPIVolumeFile, out *api.DownwardAPIVolumeFile, s conversion.Scope) error {
- return autoConvert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in, out, s)
-}
-
-func autoConvert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in *api.DownwardAPIVolumeFile, out *DownwardAPIVolumeFile, s conversion.Scope) error {
- out.Path = in.Path
- if in.FieldRef != nil {
- in, out := &in.FieldRef, &out.FieldRef
- *out = new(ObjectFieldSelector)
- if err := Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := &in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(ResourceFieldSelector)
- if err := Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- return nil
-}
-
-func Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in *api.DownwardAPIVolumeFile, out *DownwardAPIVolumeFile, s conversion.Scope) error {
- return autoConvert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in, out, s)
-}
-
-func autoConvert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in *DownwardAPIVolumeSource, out *api.DownwardAPIVolumeSource, s conversion.Scope) error {
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.DownwardAPIVolumeFile, len(*in))
- for i := range *in {
- if err := Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in *DownwardAPIVolumeSource, out *api.DownwardAPIVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in, out, s)
-}
-
-func autoConvert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *api.DownwardAPIVolumeSource, out *DownwardAPIVolumeSource, s conversion.Scope) error {
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]DownwardAPIVolumeFile, len(*in))
- for i := range *in {
- if err := Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *api.DownwardAPIVolumeSource, out *DownwardAPIVolumeSource, s conversion.Scope) error {
- return autoConvert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error {
- out.Medium = api.StorageMedium(in.Medium)
- return nil
-}
-
-func Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in, out, s)
-}
-
-func autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error {
- out.Medium = StorageMedium(in.Medium)
- return nil
-}
-
-func Convert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error {
- return autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_EndpointAddress_To_api_EndpointAddress(in *EndpointAddress, out *api.EndpointAddress, s conversion.Scope) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- if in.TargetRef != nil {
- in, out := &in.TargetRef, &out.TargetRef
- *out = new(api.ObjectReference)
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.TargetRef = nil
- }
- return nil
-}
-
-func Convert_v1_EndpointAddress_To_api_EndpointAddress(in *EndpointAddress, out *api.EndpointAddress, s conversion.Scope) error {
- return autoConvert_v1_EndpointAddress_To_api_EndpointAddress(in, out, s)
-}
-
-func autoConvert_api_EndpointAddress_To_v1_EndpointAddress(in *api.EndpointAddress, out *EndpointAddress, s conversion.Scope) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- if in.TargetRef != nil {
- in, out := &in.TargetRef, &out.TargetRef
- *out = new(ObjectReference)
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.TargetRef = nil
- }
- return nil
-}
-
-func Convert_api_EndpointAddress_To_v1_EndpointAddress(in *api.EndpointAddress, out *EndpointAddress, s conversion.Scope) error {
- return autoConvert_api_EndpointAddress_To_v1_EndpointAddress(in, out, s)
-}
-
-func autoConvert_v1_EndpointPort_To_api_EndpointPort(in *EndpointPort, out *api.EndpointPort, s conversion.Scope) error {
- out.Name = in.Name
- out.Port = in.Port
- out.Protocol = api.Protocol(in.Protocol)
- return nil
-}
-
-func Convert_v1_EndpointPort_To_api_EndpointPort(in *EndpointPort, out *api.EndpointPort, s conversion.Scope) error {
- return autoConvert_v1_EndpointPort_To_api_EndpointPort(in, out, s)
-}
-
-func autoConvert_api_EndpointPort_To_v1_EndpointPort(in *api.EndpointPort, out *EndpointPort, s conversion.Scope) error {
- out.Name = in.Name
- out.Port = in.Port
- out.Protocol = Protocol(in.Protocol)
- return nil
-}
-
-func Convert_api_EndpointPort_To_v1_EndpointPort(in *api.EndpointPort, out *EndpointPort, s conversion.Scope) error {
- return autoConvert_api_EndpointPort_To_v1_EndpointPort(in, out, s)
-}
-
-func autoConvert_v1_EndpointSubset_To_api_EndpointSubset(in *EndpointSubset, out *api.EndpointSubset, s conversion.Scope) error {
- if in.Addresses != nil {
- in, out := &in.Addresses, &out.Addresses
- *out = make([]api.EndpointAddress, len(*in))
- for i := range *in {
- if err := Convert_v1_EndpointAddress_To_api_EndpointAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Addresses = nil
- }
- if in.NotReadyAddresses != nil {
- in, out := &in.NotReadyAddresses, &out.NotReadyAddresses
- *out = make([]api.EndpointAddress, len(*in))
- for i := range *in {
- if err := Convert_v1_EndpointAddress_To_api_EndpointAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.NotReadyAddresses = nil
- }
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]api.EndpointPort, len(*in))
- for i := range *in {
- if err := Convert_v1_EndpointPort_To_api_EndpointPort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- return nil
-}
-
-func Convert_v1_EndpointSubset_To_api_EndpointSubset(in *EndpointSubset, out *api.EndpointSubset, s conversion.Scope) error {
- return autoConvert_v1_EndpointSubset_To_api_EndpointSubset(in, out, s)
-}
-
-func autoConvert_api_EndpointSubset_To_v1_EndpointSubset(in *api.EndpointSubset, out *EndpointSubset, s conversion.Scope) error {
- if in.Addresses != nil {
- in, out := &in.Addresses, &out.Addresses
- *out = make([]EndpointAddress, len(*in))
- for i := range *in {
- if err := Convert_api_EndpointAddress_To_v1_EndpointAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Addresses = nil
- }
- if in.NotReadyAddresses != nil {
- in, out := &in.NotReadyAddresses, &out.NotReadyAddresses
- *out = make([]EndpointAddress, len(*in))
- for i := range *in {
- if err := Convert_api_EndpointAddress_To_v1_EndpointAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.NotReadyAddresses = nil
- }
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]EndpointPort, len(*in))
- for i := range *in {
- if err := Convert_api_EndpointPort_To_v1_EndpointPort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- return nil
-}
-
-func Convert_api_EndpointSubset_To_v1_EndpointSubset(in *api.EndpointSubset, out *EndpointSubset, s conversion.Scope) error {
- return autoConvert_api_EndpointSubset_To_v1_EndpointSubset(in, out, s)
-}
-
-func autoConvert_v1_Endpoints_To_api_Endpoints(in *Endpoints, out *api.Endpoints, s conversion.Scope) error {
- SetDefaults_Endpoints(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Subsets != nil {
- in, out := &in.Subsets, &out.Subsets
- *out = make([]api.EndpointSubset, len(*in))
- for i := range *in {
- if err := Convert_v1_EndpointSubset_To_api_EndpointSubset(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Subsets = nil
- }
- return nil
-}
-
-func Convert_v1_Endpoints_To_api_Endpoints(in *Endpoints, out *api.Endpoints, s conversion.Scope) error {
- return autoConvert_v1_Endpoints_To_api_Endpoints(in, out, s)
-}
-
-func autoConvert_api_Endpoints_To_v1_Endpoints(in *api.Endpoints, out *Endpoints, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Subsets != nil {
- in, out := &in.Subsets, &out.Subsets
- *out = make([]EndpointSubset, len(*in))
- for i := range *in {
- if err := Convert_api_EndpointSubset_To_v1_EndpointSubset(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Subsets = nil
- }
- return nil
-}
-
-func Convert_api_Endpoints_To_v1_Endpoints(in *api.Endpoints, out *Endpoints, s conversion.Scope) error {
- return autoConvert_api_Endpoints_To_v1_Endpoints(in, out, s)
-}
-
-func autoConvert_v1_EndpointsList_To_api_EndpointsList(in *EndpointsList, out *api.EndpointsList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Endpoints, len(*in))
- for i := range *in {
- if err := Convert_v1_Endpoints_To_api_Endpoints(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_EndpointsList_To_api_EndpointsList(in *EndpointsList, out *api.EndpointsList, s conversion.Scope) error {
- return autoConvert_v1_EndpointsList_To_api_EndpointsList(in, out, s)
-}
-
-func autoConvert_api_EndpointsList_To_v1_EndpointsList(in *api.EndpointsList, out *EndpointsList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Endpoints, len(*in))
- for i := range *in {
- if err := Convert_api_Endpoints_To_v1_Endpoints(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_EndpointsList_To_v1_EndpointsList(in *api.EndpointsList, out *EndpointsList, s conversion.Scope) error {
- return autoConvert_api_EndpointsList_To_v1_EndpointsList(in, out, s)
-}
-
-func autoConvert_v1_EnvVar_To_api_EnvVar(in *EnvVar, out *api.EnvVar, s conversion.Scope) error {
- out.Name = in.Name
- out.Value = in.Value
- if in.ValueFrom != nil {
- in, out := &in.ValueFrom, &out.ValueFrom
- *out = new(api.EnvVarSource)
- if err := Convert_v1_EnvVarSource_To_api_EnvVarSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ValueFrom = nil
- }
- return nil
-}
-
-func Convert_v1_EnvVar_To_api_EnvVar(in *EnvVar, out *api.EnvVar, s conversion.Scope) error {
- return autoConvert_v1_EnvVar_To_api_EnvVar(in, out, s)
-}
-
-func autoConvert_api_EnvVar_To_v1_EnvVar(in *api.EnvVar, out *EnvVar, s conversion.Scope) error {
- out.Name = in.Name
- out.Value = in.Value
- if in.ValueFrom != nil {
- in, out := &in.ValueFrom, &out.ValueFrom
- *out = new(EnvVarSource)
- if err := Convert_api_EnvVarSource_To_v1_EnvVarSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ValueFrom = nil
- }
- return nil
-}
-
-func Convert_api_EnvVar_To_v1_EnvVar(in *api.EnvVar, out *EnvVar, s conversion.Scope) error {
- return autoConvert_api_EnvVar_To_v1_EnvVar(in, out, s)
-}
-
-func autoConvert_v1_EnvVarSource_To_api_EnvVarSource(in *EnvVarSource, out *api.EnvVarSource, s conversion.Scope) error {
- if in.FieldRef != nil {
- in, out := &in.FieldRef, &out.FieldRef
- *out = new(api.ObjectFieldSelector)
- if err := Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := &in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(api.ResourceFieldSelector)
- if err := Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- if in.ConfigMapKeyRef != nil {
- in, out := &in.ConfigMapKeyRef, &out.ConfigMapKeyRef
- *out = new(api.ConfigMapKeySelector)
- if err := Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ConfigMapKeyRef = nil
- }
- if in.SecretKeyRef != nil {
- in, out := &in.SecretKeyRef, &out.SecretKeyRef
- *out = new(api.SecretKeySelector)
- if err := Convert_v1_SecretKeySelector_To_api_SecretKeySelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretKeyRef = nil
- }
- return nil
-}
-
-func Convert_v1_EnvVarSource_To_api_EnvVarSource(in *EnvVarSource, out *api.EnvVarSource, s conversion.Scope) error {
- return autoConvert_v1_EnvVarSource_To_api_EnvVarSource(in, out, s)
-}
-
-func autoConvert_api_EnvVarSource_To_v1_EnvVarSource(in *api.EnvVarSource, out *EnvVarSource, s conversion.Scope) error {
- if in.FieldRef != nil {
- in, out := &in.FieldRef, &out.FieldRef
- *out = new(ObjectFieldSelector)
- if err := Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := &in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(ResourceFieldSelector)
- if err := Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- if in.ConfigMapKeyRef != nil {
- in, out := &in.ConfigMapKeyRef, &out.ConfigMapKeyRef
- *out = new(ConfigMapKeySelector)
- if err := Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ConfigMapKeyRef = nil
- }
- if in.SecretKeyRef != nil {
- in, out := &in.SecretKeyRef, &out.SecretKeyRef
- *out = new(SecretKeySelector)
- if err := Convert_api_SecretKeySelector_To_v1_SecretKeySelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretKeyRef = nil
- }
- return nil
-}
-
-func Convert_api_EnvVarSource_To_v1_EnvVarSource(in *api.EnvVarSource, out *EnvVarSource, s conversion.Scope) error {
- return autoConvert_api_EnvVarSource_To_v1_EnvVarSource(in, out, s)
-}
-
-func autoConvert_v1_Event_To_api_Event(in *Event, out *api.Event, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(&in.InvolvedObject, &out.InvolvedObject, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- if err := Convert_v1_EventSource_To_api_EventSource(&in.Source, &out.Source, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.FirstTimestamp, &out.FirstTimestamp, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTimestamp, &out.LastTimestamp, s); err != nil {
- return err
- }
- out.Count = in.Count
- out.Type = in.Type
- return nil
-}
-
-func Convert_v1_Event_To_api_Event(in *Event, out *api.Event, s conversion.Scope) error {
- return autoConvert_v1_Event_To_api_Event(in, out, s)
-}
-
-func autoConvert_api_Event_To_v1_Event(in *api.Event, out *Event, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(&in.InvolvedObject, &out.InvolvedObject, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- if err := Convert_api_EventSource_To_v1_EventSource(&in.Source, &out.Source, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.FirstTimestamp, &out.FirstTimestamp, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTimestamp, &out.LastTimestamp, s); err != nil {
- return err
- }
- out.Count = in.Count
- out.Type = in.Type
- return nil
-}
-
-func Convert_api_Event_To_v1_Event(in *api.Event, out *Event, s conversion.Scope) error {
- return autoConvert_api_Event_To_v1_Event(in, out, s)
-}
-
-func autoConvert_v1_EventList_To_api_EventList(in *EventList, out *api.EventList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Event, len(*in))
- for i := range *in {
- if err := Convert_v1_Event_To_api_Event(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_EventList_To_api_EventList(in *EventList, out *api.EventList, s conversion.Scope) error {
- return autoConvert_v1_EventList_To_api_EventList(in, out, s)
-}
-
-func autoConvert_api_EventList_To_v1_EventList(in *api.EventList, out *EventList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Event, len(*in))
- for i := range *in {
- if err := Convert_api_Event_To_v1_Event(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_EventList_To_v1_EventList(in *api.EventList, out *EventList, s conversion.Scope) error {
- return autoConvert_api_EventList_To_v1_EventList(in, out, s)
-}
-
-func autoConvert_v1_EventSource_To_api_EventSource(in *EventSource, out *api.EventSource, s conversion.Scope) error {
- out.Component = in.Component
- out.Host = in.Host
- return nil
-}
-
-func Convert_v1_EventSource_To_api_EventSource(in *EventSource, out *api.EventSource, s conversion.Scope) error {
- return autoConvert_v1_EventSource_To_api_EventSource(in, out, s)
-}
-
-func autoConvert_api_EventSource_To_v1_EventSource(in *api.EventSource, out *EventSource, s conversion.Scope) error {
- out.Component = in.Component
- out.Host = in.Host
- return nil
-}
-
-func Convert_api_EventSource_To_v1_EventSource(in *api.EventSource, out *EventSource, s conversion.Scope) error {
- return autoConvert_api_EventSource_To_v1_EventSource(in, out, s)
-}
-
-func autoConvert_v1_ExecAction_To_api_ExecAction(in *ExecAction, out *api.ExecAction, s conversion.Scope) error {
- out.Command = in.Command
- return nil
-}
-
-func Convert_v1_ExecAction_To_api_ExecAction(in *ExecAction, out *api.ExecAction, s conversion.Scope) error {
- return autoConvert_v1_ExecAction_To_api_ExecAction(in, out, s)
-}
-
-func autoConvert_api_ExecAction_To_v1_ExecAction(in *api.ExecAction, out *ExecAction, s conversion.Scope) error {
- out.Command = in.Command
- return nil
-}
-
-func Convert_api_ExecAction_To_v1_ExecAction(in *api.ExecAction, out *ExecAction, s conversion.Scope) error {
- return autoConvert_api_ExecAction_To_v1_ExecAction(in, out, s)
-}
-
-func autoConvert_v1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Export = in.Export
- out.Exact = in.Exact
- return nil
-}
-
-func Convert_v1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error {
- return autoConvert_v1_ExportOptions_To_api_ExportOptions(in, out, s)
-}
-
-func autoConvert_api_ExportOptions_To_v1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Export = in.Export
- out.Exact = in.Exact
- return nil
-}
-
-func Convert_api_ExportOptions_To_v1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error {
- return autoConvert_api_ExportOptions_To_v1_ExportOptions(in, out, s)
-}
-
-func autoConvert_v1_FCVolumeSource_To_api_FCVolumeSource(in *FCVolumeSource, out *api.FCVolumeSource, s conversion.Scope) error {
- out.TargetWWNs = in.TargetWWNs
- out.Lun = in.Lun
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_FCVolumeSource_To_api_FCVolumeSource(in *FCVolumeSource, out *api.FCVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_FCVolumeSource_To_api_FCVolumeSource(in, out, s)
-}
-
-func autoConvert_api_FCVolumeSource_To_v1_FCVolumeSource(in *api.FCVolumeSource, out *FCVolumeSource, s conversion.Scope) error {
- out.TargetWWNs = in.TargetWWNs
- out.Lun = in.Lun
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_FCVolumeSource_To_v1_FCVolumeSource(in *api.FCVolumeSource, out *FCVolumeSource, s conversion.Scope) error {
- return autoConvert_api_FCVolumeSource_To_v1_FCVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in *FlexVolumeSource, out *api.FlexVolumeSource, s conversion.Scope) error {
- out.Driver = in.Driver
- out.FSType = in.FSType
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(api.LocalObjectReference)
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- out.Options = in.Options
- return nil
-}
-
-func Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in *FlexVolumeSource, out *api.FlexVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in, out, s)
-}
-
-func autoConvert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in *api.FlexVolumeSource, out *FlexVolumeSource, s conversion.Scope) error {
- out.Driver = in.Driver
- out.FSType = in.FSType
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- out.Options = in.Options
- return nil
-}
-
-func Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in *api.FlexVolumeSource, out *FlexVolumeSource, s conversion.Scope) error {
- return autoConvert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in *FlockerVolumeSource, out *api.FlockerVolumeSource, s conversion.Scope) error {
- out.DatasetName = in.DatasetName
- return nil
-}
-
-func Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in *FlockerVolumeSource, out *api.FlockerVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in, out, s)
-}
-
-func autoConvert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in *api.FlockerVolumeSource, out *FlockerVolumeSource, s conversion.Scope) error {
- out.DatasetName = in.DatasetName
- return nil
-}
-
-func Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in *api.FlockerVolumeSource, out *FlockerVolumeSource, s conversion.Scope) error {
- return autoConvert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(in *GCEPersistentDiskVolumeSource, out *api.GCEPersistentDiskVolumeSource, s conversion.Scope) error {
- out.PDName = in.PDName
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(in *GCEPersistentDiskVolumeSource, out *api.GCEPersistentDiskVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(in, out, s)
-}
-
-func autoConvert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(in *api.GCEPersistentDiskVolumeSource, out *GCEPersistentDiskVolumeSource, s conversion.Scope) error {
- out.PDName = in.PDName
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(in *api.GCEPersistentDiskVolumeSource, out *GCEPersistentDiskVolumeSource, s conversion.Scope) error {
- return autoConvert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in *GitRepoVolumeSource, out *api.GitRepoVolumeSource, s conversion.Scope) error {
- out.Repository = in.Repository
- out.Revision = in.Revision
- out.Directory = in.Directory
- return nil
-}
-
-func Convert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in *GitRepoVolumeSource, out *api.GitRepoVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in, out, s)
-}
-
-func autoConvert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in *api.GitRepoVolumeSource, out *GitRepoVolumeSource, s conversion.Scope) error {
- out.Repository = in.Repository
- out.Revision = in.Revision
- out.Directory = in.Directory
- return nil
-}
-
-func Convert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in *api.GitRepoVolumeSource, out *GitRepoVolumeSource, s conversion.Scope) error {
- return autoConvert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in *GlusterfsVolumeSource, out *api.GlusterfsVolumeSource, s conversion.Scope) error {
- out.EndpointsName = in.EndpointsName
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in *GlusterfsVolumeSource, out *api.GlusterfsVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in, out, s)
-}
-
-func autoConvert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in *api.GlusterfsVolumeSource, out *GlusterfsVolumeSource, s conversion.Scope) error {
- out.EndpointsName = in.EndpointsName
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in *api.GlusterfsVolumeSource, out *GlusterfsVolumeSource, s conversion.Scope) error {
- return autoConvert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_HTTPGetAction_To_api_HTTPGetAction(in *HTTPGetAction, out *api.HTTPGetAction, s conversion.Scope) error {
- SetDefaults_HTTPGetAction(in)
- out.Path = in.Path
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.Port, &out.Port, s); err != nil {
- return err
- }
- out.Host = in.Host
- out.Scheme = api.URIScheme(in.Scheme)
- if in.HTTPHeaders != nil {
- in, out := &in.HTTPHeaders, &out.HTTPHeaders
- *out = make([]api.HTTPHeader, len(*in))
- for i := range *in {
- if err := Convert_v1_HTTPHeader_To_api_HTTPHeader(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.HTTPHeaders = nil
- }
- return nil
-}
-
-func Convert_v1_HTTPGetAction_To_api_HTTPGetAction(in *HTTPGetAction, out *api.HTTPGetAction, s conversion.Scope) error {
- return autoConvert_v1_HTTPGetAction_To_api_HTTPGetAction(in, out, s)
-}
-
-func autoConvert_api_HTTPGetAction_To_v1_HTTPGetAction(in *api.HTTPGetAction, out *HTTPGetAction, s conversion.Scope) error {
- out.Path = in.Path
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.Port, &out.Port, s); err != nil {
- return err
- }
- out.Host = in.Host
- out.Scheme = URIScheme(in.Scheme)
- if in.HTTPHeaders != nil {
- in, out := &in.HTTPHeaders, &out.HTTPHeaders
- *out = make([]HTTPHeader, len(*in))
- for i := range *in {
- if err := Convert_api_HTTPHeader_To_v1_HTTPHeader(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.HTTPHeaders = nil
- }
- return nil
-}
-
-func Convert_api_HTTPGetAction_To_v1_HTTPGetAction(in *api.HTTPGetAction, out *HTTPGetAction, s conversion.Scope) error {
- return autoConvert_api_HTTPGetAction_To_v1_HTTPGetAction(in, out, s)
-}
-
-func autoConvert_v1_HTTPHeader_To_api_HTTPHeader(in *HTTPHeader, out *api.HTTPHeader, s conversion.Scope) error {
- out.Name = in.Name
- out.Value = in.Value
- return nil
-}
-
-func Convert_v1_HTTPHeader_To_api_HTTPHeader(in *HTTPHeader, out *api.HTTPHeader, s conversion.Scope) error {
- return autoConvert_v1_HTTPHeader_To_api_HTTPHeader(in, out, s)
-}
-
-func autoConvert_api_HTTPHeader_To_v1_HTTPHeader(in *api.HTTPHeader, out *HTTPHeader, s conversion.Scope) error {
- out.Name = in.Name
- out.Value = in.Value
- return nil
-}
-
-func Convert_api_HTTPHeader_To_v1_HTTPHeader(in *api.HTTPHeader, out *HTTPHeader, s conversion.Scope) error {
- return autoConvert_api_HTTPHeader_To_v1_HTTPHeader(in, out, s)
-}
-
-func autoConvert_v1_Handler_To_api_Handler(in *Handler, out *api.Handler, s conversion.Scope) error {
- if in.Exec != nil {
- in, out := &in.Exec, &out.Exec
- *out = new(api.ExecAction)
- if err := Convert_v1_ExecAction_To_api_ExecAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Exec = nil
- }
- if in.HTTPGet != nil {
- in, out := &in.HTTPGet, &out.HTTPGet
- *out = new(api.HTTPGetAction)
- if err := Convert_v1_HTTPGetAction_To_api_HTTPGetAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HTTPGet = nil
- }
- if in.TCPSocket != nil {
- in, out := &in.TCPSocket, &out.TCPSocket
- *out = new(api.TCPSocketAction)
- if err := Convert_v1_TCPSocketAction_To_api_TCPSocketAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.TCPSocket = nil
- }
- return nil
-}
-
-func Convert_v1_Handler_To_api_Handler(in *Handler, out *api.Handler, s conversion.Scope) error {
- return autoConvert_v1_Handler_To_api_Handler(in, out, s)
-}
-
-func autoConvert_api_Handler_To_v1_Handler(in *api.Handler, out *Handler, s conversion.Scope) error {
- if in.Exec != nil {
- in, out := &in.Exec, &out.Exec
- *out = new(ExecAction)
- if err := Convert_api_ExecAction_To_v1_ExecAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Exec = nil
- }
- if in.HTTPGet != nil {
- in, out := &in.HTTPGet, &out.HTTPGet
- *out = new(HTTPGetAction)
- if err := Convert_api_HTTPGetAction_To_v1_HTTPGetAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HTTPGet = nil
- }
- if in.TCPSocket != nil {
- in, out := &in.TCPSocket, &out.TCPSocket
- *out = new(TCPSocketAction)
- if err := Convert_api_TCPSocketAction_To_v1_TCPSocketAction(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.TCPSocket = nil
- }
- return nil
-}
-
-func Convert_api_Handler_To_v1_Handler(in *api.Handler, out *Handler, s conversion.Scope) error {
- return autoConvert_api_Handler_To_v1_Handler(in, out, s)
-}
-
-func autoConvert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in *HostPathVolumeSource, out *api.HostPathVolumeSource, s conversion.Scope) error {
- out.Path = in.Path
- return nil
-}
-
-func Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in *HostPathVolumeSource, out *api.HostPathVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in, out, s)
-}
-
-func autoConvert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in *api.HostPathVolumeSource, out *HostPathVolumeSource, s conversion.Scope) error {
- out.Path = in.Path
- return nil
-}
-
-func Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in *api.HostPathVolumeSource, out *HostPathVolumeSource, s conversion.Scope) error {
- return autoConvert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in *ISCSIVolumeSource, out *api.ISCSIVolumeSource, s conversion.Scope) error {
- SetDefaults_ISCSIVolumeSource(in)
- out.TargetPortal = in.TargetPortal
- out.IQN = in.IQN
- out.Lun = in.Lun
- out.ISCSIInterface = in.ISCSIInterface
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in *ISCSIVolumeSource, out *api.ISCSIVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in, out, s)
-}
-
-func autoConvert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in *api.ISCSIVolumeSource, out *ISCSIVolumeSource, s conversion.Scope) error {
- out.TargetPortal = in.TargetPortal
- out.IQN = in.IQN
- out.Lun = in.Lun
- out.ISCSIInterface = in.ISCSIInterface
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in *api.ISCSIVolumeSource, out *ISCSIVolumeSource, s conversion.Scope) error {
- return autoConvert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_KeyToPath_To_api_KeyToPath(in *KeyToPath, out *api.KeyToPath, s conversion.Scope) error {
- out.Key = in.Key
- out.Path = in.Path
- return nil
-}
-
-func Convert_v1_KeyToPath_To_api_KeyToPath(in *KeyToPath, out *api.KeyToPath, s conversion.Scope) error {
- return autoConvert_v1_KeyToPath_To_api_KeyToPath(in, out, s)
-}
-
-func autoConvert_api_KeyToPath_To_v1_KeyToPath(in *api.KeyToPath, out *KeyToPath, s conversion.Scope) error {
- out.Key = in.Key
- out.Path = in.Path
- return nil
-}
-
-func Convert_api_KeyToPath_To_v1_KeyToPath(in *api.KeyToPath, out *KeyToPath, s conversion.Scope) error {
- return autoConvert_api_KeyToPath_To_v1_KeyToPath(in, out, s)
-}
-
-func autoConvert_v1_Lifecycle_To_api_Lifecycle(in *Lifecycle, out *api.Lifecycle, s conversion.Scope) error {
- if in.PostStart != nil {
- in, out := &in.PostStart, &out.PostStart
- *out = new(api.Handler)
- if err := Convert_v1_Handler_To_api_Handler(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PostStart = nil
- }
- if in.PreStop != nil {
- in, out := &in.PreStop, &out.PreStop
- *out = new(api.Handler)
- if err := Convert_v1_Handler_To_api_Handler(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PreStop = nil
- }
- return nil
-}
-
-func Convert_v1_Lifecycle_To_api_Lifecycle(in *Lifecycle, out *api.Lifecycle, s conversion.Scope) error {
- return autoConvert_v1_Lifecycle_To_api_Lifecycle(in, out, s)
-}
-
-func autoConvert_api_Lifecycle_To_v1_Lifecycle(in *api.Lifecycle, out *Lifecycle, s conversion.Scope) error {
- if in.PostStart != nil {
- in, out := &in.PostStart, &out.PostStart
- *out = new(Handler)
- if err := Convert_api_Handler_To_v1_Handler(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PostStart = nil
- }
- if in.PreStop != nil {
- in, out := &in.PreStop, &out.PreStop
- *out = new(Handler)
- if err := Convert_api_Handler_To_v1_Handler(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PreStop = nil
- }
- return nil
-}
-
-func Convert_api_Lifecycle_To_v1_Lifecycle(in *api.Lifecycle, out *Lifecycle, s conversion.Scope) error {
- return autoConvert_api_Lifecycle_To_v1_Lifecycle(in, out, s)
-}
-
-func autoConvert_v1_LimitRange_To_api_LimitRange(in *LimitRange, out *api.LimitRange, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_LimitRange_To_api_LimitRange(in *LimitRange, out *api.LimitRange, s conversion.Scope) error {
- return autoConvert_v1_LimitRange_To_api_LimitRange(in, out, s)
-}
-
-func autoConvert_api_LimitRange_To_v1_LimitRange(in *api.LimitRange, out *LimitRange, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_LimitRange_To_v1_LimitRange(in *api.LimitRange, out *LimitRange, s conversion.Scope) error {
- return autoConvert_api_LimitRange_To_v1_LimitRange(in, out, s)
-}
-
-func autoConvert_v1_LimitRangeItem_To_api_LimitRangeItem(in *LimitRangeItem, out *api.LimitRangeItem, s conversion.Scope) error {
- SetDefaults_LimitRangeItem(in)
- out.Type = api.LimitType(in.Type)
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Max, &out.Max, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Min, &out.Min, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Default, &out.Default, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.DefaultRequest, &out.DefaultRequest, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.MaxLimitRequestRatio, &out.MaxLimitRequestRatio, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_LimitRangeItem_To_api_LimitRangeItem(in *LimitRangeItem, out *api.LimitRangeItem, s conversion.Scope) error {
- return autoConvert_v1_LimitRangeItem_To_api_LimitRangeItem(in, out, s)
-}
-
-func autoConvert_api_LimitRangeItem_To_v1_LimitRangeItem(in *api.LimitRangeItem, out *LimitRangeItem, s conversion.Scope) error {
- out.Type = LimitType(in.Type)
- if in.Max != nil {
- in, out := &in.Max, &out.Max
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Max = nil
- }
- if in.Min != nil {
- in, out := &in.Min, &out.Min
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Min = nil
- }
- if in.Default != nil {
- in, out := &in.Default, &out.Default
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Default = nil
- }
- if in.DefaultRequest != nil {
- in, out := &in.DefaultRequest, &out.DefaultRequest
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.DefaultRequest = nil
- }
- if in.MaxLimitRequestRatio != nil {
- in, out := &in.MaxLimitRequestRatio, &out.MaxLimitRequestRatio
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.MaxLimitRequestRatio = nil
- }
- return nil
-}
-
-func Convert_api_LimitRangeItem_To_v1_LimitRangeItem(in *api.LimitRangeItem, out *LimitRangeItem, s conversion.Scope) error {
- return autoConvert_api_LimitRangeItem_To_v1_LimitRangeItem(in, out, s)
-}
-
-func autoConvert_v1_LimitRangeList_To_api_LimitRangeList(in *LimitRangeList, out *api.LimitRangeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.LimitRange, len(*in))
- for i := range *in {
- if err := Convert_v1_LimitRange_To_api_LimitRange(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_LimitRangeList_To_api_LimitRangeList(in *LimitRangeList, out *api.LimitRangeList, s conversion.Scope) error {
- return autoConvert_v1_LimitRangeList_To_api_LimitRangeList(in, out, s)
-}
-
-func autoConvert_api_LimitRangeList_To_v1_LimitRangeList(in *api.LimitRangeList, out *LimitRangeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]LimitRange, len(*in))
- for i := range *in {
- if err := Convert_api_LimitRange_To_v1_LimitRange(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_LimitRangeList_To_v1_LimitRangeList(in *api.LimitRangeList, out *LimitRangeList, s conversion.Scope) error {
- return autoConvert_api_LimitRangeList_To_v1_LimitRangeList(in, out, s)
-}
-
-func autoConvert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in *LimitRangeSpec, out *api.LimitRangeSpec, s conversion.Scope) error {
- if in.Limits != nil {
- in, out := &in.Limits, &out.Limits
- *out = make([]api.LimitRangeItem, len(*in))
- for i := range *in {
- if err := Convert_v1_LimitRangeItem_To_api_LimitRangeItem(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Limits = nil
- }
- return nil
-}
-
-func Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in *LimitRangeSpec, out *api.LimitRangeSpec, s conversion.Scope) error {
- return autoConvert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in, out, s)
-}
-
-func autoConvert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in *api.LimitRangeSpec, out *LimitRangeSpec, s conversion.Scope) error {
- if in.Limits != nil {
- in, out := &in.Limits, &out.Limits
- *out = make([]LimitRangeItem, len(*in))
- for i := range *in {
- if err := Convert_api_LimitRangeItem_To_v1_LimitRangeItem(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Limits = nil
- }
- return nil
-}
-
-func Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in *api.LimitRangeSpec, out *LimitRangeSpec, s conversion.Scope) error {
- return autoConvert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in, out, s)
-}
-
-func autoConvert_v1_List_To_api_List(in *List, out *api.List, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]runtime.Object, len(*in))
- for i := range *in {
- if err := runtime.Convert_runtime_RawExtension_To_runtime_Object(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_List_To_api_List(in *List, out *api.List, s conversion.Scope) error {
- return autoConvert_v1_List_To_api_List(in, out, s)
-}
-
-func autoConvert_api_List_To_v1_List(in *api.List, out *List, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]runtime.RawExtension, len(*in))
- for i := range *in {
- if err := runtime.Convert_runtime_Object_To_runtime_RawExtension(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_List_To_v1_List(in *api.List, out *List, s conversion.Scope) error {
- return autoConvert_api_List_To_v1_List(in, out, s)
-}
-
-func autoConvert_v1_ListOptions_To_api_ListOptions(in *ListOptions, out *api.ListOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_string_To_labels_Selector(&in.LabelSelector, &out.LabelSelector, s); err != nil {
- return err
- }
- if err := api.Convert_string_To_fields_Selector(&in.FieldSelector, &out.FieldSelector, s); err != nil {
- return err
- }
- out.Watch = in.Watch
- out.ResourceVersion = in.ResourceVersion
- out.TimeoutSeconds = in.TimeoutSeconds
- return nil
-}
-
-func Convert_v1_ListOptions_To_api_ListOptions(in *ListOptions, out *api.ListOptions, s conversion.Scope) error {
- return autoConvert_v1_ListOptions_To_api_ListOptions(in, out, s)
-}
-
-func autoConvert_api_ListOptions_To_v1_ListOptions(in *api.ListOptions, out *ListOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_labels_Selector_To_string(&in.LabelSelector, &out.LabelSelector, s); err != nil {
- return err
- }
- if err := api.Convert_fields_Selector_To_string(&in.FieldSelector, &out.FieldSelector, s); err != nil {
- return err
- }
- out.Watch = in.Watch
- out.ResourceVersion = in.ResourceVersion
- out.TimeoutSeconds = in.TimeoutSeconds
- return nil
-}
-
-func Convert_api_ListOptions_To_v1_ListOptions(in *api.ListOptions, out *ListOptions, s conversion.Scope) error {
- return autoConvert_api_ListOptions_To_v1_ListOptions(in, out, s)
-}
-
-func autoConvert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in *LoadBalancerIngress, out *api.LoadBalancerIngress, s conversion.Scope) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- return nil
-}
-
-func Convert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in *LoadBalancerIngress, out *api.LoadBalancerIngress, s conversion.Scope) error {
- return autoConvert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in, out, s)
-}
-
-func autoConvert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in *api.LoadBalancerIngress, out *LoadBalancerIngress, s conversion.Scope) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- return nil
-}
-
-func Convert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in *api.LoadBalancerIngress, out *LoadBalancerIngress, s conversion.Scope) error {
- return autoConvert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in, out, s)
-}
-
-func autoConvert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in *LoadBalancerStatus, out *api.LoadBalancerStatus, s conversion.Scope) error {
- if in.Ingress != nil {
- in, out := &in.Ingress, &out.Ingress
- *out = make([]api.LoadBalancerIngress, len(*in))
- for i := range *in {
- if err := Convert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ingress = nil
- }
- return nil
-}
-
-func Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in *LoadBalancerStatus, out *api.LoadBalancerStatus, s conversion.Scope) error {
- return autoConvert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in, out, s)
-}
-
-func autoConvert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in *api.LoadBalancerStatus, out *LoadBalancerStatus, s conversion.Scope) error {
- if in.Ingress != nil {
- in, out := &in.Ingress, &out.Ingress
- *out = make([]LoadBalancerIngress, len(*in))
- for i := range *in {
- if err := Convert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ingress = nil
- }
- return nil
-}
-
-func Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in *api.LoadBalancerStatus, out *LoadBalancerStatus, s conversion.Scope) error {
- return autoConvert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in, out, s)
-}
-
-func autoConvert_v1_LocalObjectReference_To_api_LocalObjectReference(in *LocalObjectReference, out *api.LocalObjectReference, s conversion.Scope) error {
- out.Name = in.Name
- return nil
-}
-
-func Convert_v1_LocalObjectReference_To_api_LocalObjectReference(in *LocalObjectReference, out *api.LocalObjectReference, s conversion.Scope) error {
- return autoConvert_v1_LocalObjectReference_To_api_LocalObjectReference(in, out, s)
-}
-
-func autoConvert_api_LocalObjectReference_To_v1_LocalObjectReference(in *api.LocalObjectReference, out *LocalObjectReference, s conversion.Scope) error {
- out.Name = in.Name
- return nil
-}
-
-func Convert_api_LocalObjectReference_To_v1_LocalObjectReference(in *api.LocalObjectReference, out *LocalObjectReference, s conversion.Scope) error {
- return autoConvert_api_LocalObjectReference_To_v1_LocalObjectReference(in, out, s)
-}
-
-func autoConvert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in *NFSVolumeSource, out *api.NFSVolumeSource, s conversion.Scope) error {
- out.Server = in.Server
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in *NFSVolumeSource, out *api.NFSVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in, out, s)
-}
-
-func autoConvert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in *api.NFSVolumeSource, out *NFSVolumeSource, s conversion.Scope) error {
- out.Server = in.Server
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in *api.NFSVolumeSource, out *NFSVolumeSource, s conversion.Scope) error {
- return autoConvert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_Namespace_To_api_Namespace(in *Namespace, out *api.Namespace, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_NamespaceSpec_To_api_NamespaceSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_NamespaceStatus_To_api_NamespaceStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_Namespace_To_api_Namespace(in *Namespace, out *api.Namespace, s conversion.Scope) error {
- return autoConvert_v1_Namespace_To_api_Namespace(in, out, s)
-}
-
-func autoConvert_api_Namespace_To_v1_Namespace(in *api.Namespace, out *Namespace, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_NamespaceSpec_To_v1_NamespaceSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_NamespaceStatus_To_v1_NamespaceStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_Namespace_To_v1_Namespace(in *api.Namespace, out *Namespace, s conversion.Scope) error {
- return autoConvert_api_Namespace_To_v1_Namespace(in, out, s)
-}
-
-func autoConvert_v1_NamespaceList_To_api_NamespaceList(in *NamespaceList, out *api.NamespaceList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Namespace, len(*in))
- for i := range *in {
- if err := Convert_v1_Namespace_To_api_Namespace(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_NamespaceList_To_api_NamespaceList(in *NamespaceList, out *api.NamespaceList, s conversion.Scope) error {
- return autoConvert_v1_NamespaceList_To_api_NamespaceList(in, out, s)
-}
-
-func autoConvert_api_NamespaceList_To_v1_NamespaceList(in *api.NamespaceList, out *NamespaceList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Namespace, len(*in))
- for i := range *in {
- if err := Convert_api_Namespace_To_v1_Namespace(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_NamespaceList_To_v1_NamespaceList(in *api.NamespaceList, out *NamespaceList, s conversion.Scope) error {
- return autoConvert_api_NamespaceList_To_v1_NamespaceList(in, out, s)
-}
-
-func autoConvert_v1_NamespaceSpec_To_api_NamespaceSpec(in *NamespaceSpec, out *api.NamespaceSpec, s conversion.Scope) error {
- if in.Finalizers != nil {
- in, out := &in.Finalizers, &out.Finalizers
- *out = make([]api.FinalizerName, len(*in))
- for i := range *in {
- (*out)[i] = api.FinalizerName((*in)[i])
- }
- } else {
- out.Finalizers = nil
- }
- return nil
-}
-
-func Convert_v1_NamespaceSpec_To_api_NamespaceSpec(in *NamespaceSpec, out *api.NamespaceSpec, s conversion.Scope) error {
- return autoConvert_v1_NamespaceSpec_To_api_NamespaceSpec(in, out, s)
-}
-
-func autoConvert_api_NamespaceSpec_To_v1_NamespaceSpec(in *api.NamespaceSpec, out *NamespaceSpec, s conversion.Scope) error {
- if in.Finalizers != nil {
- in, out := &in.Finalizers, &out.Finalizers
- *out = make([]FinalizerName, len(*in))
- for i := range *in {
- (*out)[i] = FinalizerName((*in)[i])
- }
- } else {
- out.Finalizers = nil
- }
- return nil
-}
-
-func Convert_api_NamespaceSpec_To_v1_NamespaceSpec(in *api.NamespaceSpec, out *NamespaceSpec, s conversion.Scope) error {
- return autoConvert_api_NamespaceSpec_To_v1_NamespaceSpec(in, out, s)
-}
-
-func autoConvert_v1_NamespaceStatus_To_api_NamespaceStatus(in *NamespaceStatus, out *api.NamespaceStatus, s conversion.Scope) error {
- SetDefaults_NamespaceStatus(in)
- out.Phase = api.NamespacePhase(in.Phase)
- return nil
-}
-
-func Convert_v1_NamespaceStatus_To_api_NamespaceStatus(in *NamespaceStatus, out *api.NamespaceStatus, s conversion.Scope) error {
- return autoConvert_v1_NamespaceStatus_To_api_NamespaceStatus(in, out, s)
-}
-
-func autoConvert_api_NamespaceStatus_To_v1_NamespaceStatus(in *api.NamespaceStatus, out *NamespaceStatus, s conversion.Scope) error {
- out.Phase = NamespacePhase(in.Phase)
- return nil
-}
-
-func Convert_api_NamespaceStatus_To_v1_NamespaceStatus(in *api.NamespaceStatus, out *NamespaceStatus, s conversion.Scope) error {
- return autoConvert_api_NamespaceStatus_To_v1_NamespaceStatus(in, out, s)
-}
-
-func autoConvert_v1_Node_To_api_Node(in *Node, out *api.Node, s conversion.Scope) error {
- SetDefaults_Node(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_NodeSpec_To_api_NodeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_NodeStatus_To_api_NodeStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_Node_To_api_Node(in *Node, out *api.Node, s conversion.Scope) error {
- return autoConvert_v1_Node_To_api_Node(in, out, s)
-}
-
-func autoConvert_api_Node_To_v1_Node(in *api.Node, out *Node, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_NodeSpec_To_v1_NodeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_NodeStatus_To_v1_NodeStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_Node_To_v1_Node(in *api.Node, out *Node, s conversion.Scope) error {
- return autoConvert_api_Node_To_v1_Node(in, out, s)
-}
-
-func autoConvert_v1_NodeAddress_To_api_NodeAddress(in *NodeAddress, out *api.NodeAddress, s conversion.Scope) error {
- out.Type = api.NodeAddressType(in.Type)
- out.Address = in.Address
- return nil
-}
-
-func Convert_v1_NodeAddress_To_api_NodeAddress(in *NodeAddress, out *api.NodeAddress, s conversion.Scope) error {
- return autoConvert_v1_NodeAddress_To_api_NodeAddress(in, out, s)
-}
-
-func autoConvert_api_NodeAddress_To_v1_NodeAddress(in *api.NodeAddress, out *NodeAddress, s conversion.Scope) error {
- out.Type = NodeAddressType(in.Type)
- out.Address = in.Address
- return nil
-}
-
-func Convert_api_NodeAddress_To_v1_NodeAddress(in *api.NodeAddress, out *NodeAddress, s conversion.Scope) error {
- return autoConvert_api_NodeAddress_To_v1_NodeAddress(in, out, s)
-}
-
-func autoConvert_v1_NodeAffinity_To_api_NodeAffinity(in *NodeAffinity, out *api.NodeAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = new(api.NodeSelector)
- if err := Convert_v1_NodeSelector_To_api_NodeSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]api.PreferredSchedulingTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_v1_NodeAffinity_To_api_NodeAffinity(in *NodeAffinity, out *api.NodeAffinity, s conversion.Scope) error {
- return autoConvert_v1_NodeAffinity_To_api_NodeAffinity(in, out, s)
-}
-
-func autoConvert_api_NodeAffinity_To_v1_NodeAffinity(in *api.NodeAffinity, out *NodeAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = new(NodeSelector)
- if err := Convert_api_NodeSelector_To_v1_NodeSelector(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]PreferredSchedulingTerm, len(*in))
- for i := range *in {
- if err := Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_api_NodeAffinity_To_v1_NodeAffinity(in *api.NodeAffinity, out *NodeAffinity, s conversion.Scope) error {
- return autoConvert_api_NodeAffinity_To_v1_NodeAffinity(in, out, s)
-}
-
-func autoConvert_v1_NodeCondition_To_api_NodeCondition(in *NodeCondition, out *api.NodeCondition, s conversion.Scope) error {
- out.Type = api.NodeConditionType(in.Type)
- out.Status = api.ConditionStatus(in.Status)
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastHeartbeatTime, &out.LastHeartbeatTime, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTransitionTime, &out.LastTransitionTime, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_v1_NodeCondition_To_api_NodeCondition(in *NodeCondition, out *api.NodeCondition, s conversion.Scope) error {
- return autoConvert_v1_NodeCondition_To_api_NodeCondition(in, out, s)
-}
-
-func autoConvert_api_NodeCondition_To_v1_NodeCondition(in *api.NodeCondition, out *NodeCondition, s conversion.Scope) error {
- out.Type = NodeConditionType(in.Type)
- out.Status = ConditionStatus(in.Status)
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastHeartbeatTime, &out.LastHeartbeatTime, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTransitionTime, &out.LastTransitionTime, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_api_NodeCondition_To_v1_NodeCondition(in *api.NodeCondition, out *NodeCondition, s conversion.Scope) error {
- return autoConvert_api_NodeCondition_To_v1_NodeCondition(in, out, s)
-}
-
-func autoConvert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in *NodeDaemonEndpoints, out *api.NodeDaemonEndpoints, s conversion.Scope) error {
- if err := Convert_v1_DaemonEndpoint_To_api_DaemonEndpoint(&in.KubeletEndpoint, &out.KubeletEndpoint, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in *NodeDaemonEndpoints, out *api.NodeDaemonEndpoints, s conversion.Scope) error {
- return autoConvert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in, out, s)
-}
-
-func autoConvert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in *api.NodeDaemonEndpoints, out *NodeDaemonEndpoints, s conversion.Scope) error {
- if err := Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint(&in.KubeletEndpoint, &out.KubeletEndpoint, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in *api.NodeDaemonEndpoints, out *NodeDaemonEndpoints, s conversion.Scope) error {
- return autoConvert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in, out, s)
-}
-
-func autoConvert_v1_NodeList_To_api_NodeList(in *NodeList, out *api.NodeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Node, len(*in))
- for i := range *in {
- if err := Convert_v1_Node_To_api_Node(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_NodeList_To_api_NodeList(in *NodeList, out *api.NodeList, s conversion.Scope) error {
- return autoConvert_v1_NodeList_To_api_NodeList(in, out, s)
-}
-
-func autoConvert_api_NodeList_To_v1_NodeList(in *api.NodeList, out *NodeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Node, len(*in))
- for i := range *in {
- if err := Convert_api_Node_To_v1_Node(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_NodeList_To_v1_NodeList(in *api.NodeList, out *NodeList, s conversion.Scope) error {
- return autoConvert_api_NodeList_To_v1_NodeList(in, out, s)
-}
-
-func autoConvert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in *NodeProxyOptions, out *api.NodeProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in *NodeProxyOptions, out *api.NodeProxyOptions, s conversion.Scope) error {
- return autoConvert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in, out, s)
-}
-
-func autoConvert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in *api.NodeProxyOptions, out *NodeProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in *api.NodeProxyOptions, out *NodeProxyOptions, s conversion.Scope) error {
- return autoConvert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in, out, s)
-}
-
-func autoConvert_v1_NodeSelector_To_api_NodeSelector(in *NodeSelector, out *api.NodeSelector, s conversion.Scope) error {
- if in.NodeSelectorTerms != nil {
- in, out := &in.NodeSelectorTerms, &out.NodeSelectorTerms
- *out = make([]api.NodeSelectorTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.NodeSelectorTerms = nil
- }
- return nil
-}
-
-func Convert_v1_NodeSelector_To_api_NodeSelector(in *NodeSelector, out *api.NodeSelector, s conversion.Scope) error {
- return autoConvert_v1_NodeSelector_To_api_NodeSelector(in, out, s)
-}
-
-func autoConvert_api_NodeSelector_To_v1_NodeSelector(in *api.NodeSelector, out *NodeSelector, s conversion.Scope) error {
- if in.NodeSelectorTerms != nil {
- in, out := &in.NodeSelectorTerms, &out.NodeSelectorTerms
- *out = make([]NodeSelectorTerm, len(*in))
- for i := range *in {
- if err := Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.NodeSelectorTerms = nil
- }
- return nil
-}
-
-func Convert_api_NodeSelector_To_v1_NodeSelector(in *api.NodeSelector, out *NodeSelector, s conversion.Scope) error {
- return autoConvert_api_NodeSelector_To_v1_NodeSelector(in, out, s)
-}
-
-func autoConvert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in *NodeSelectorRequirement, out *api.NodeSelectorRequirement, s conversion.Scope) error {
- out.Key = in.Key
- out.Operator = api.NodeSelectorOperator(in.Operator)
- out.Values = in.Values
- return nil
-}
-
-func Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in *NodeSelectorRequirement, out *api.NodeSelectorRequirement, s conversion.Scope) error {
- return autoConvert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in, out, s)
-}
-
-func autoConvert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in *api.NodeSelectorRequirement, out *NodeSelectorRequirement, s conversion.Scope) error {
- out.Key = in.Key
- out.Operator = NodeSelectorOperator(in.Operator)
- out.Values = in.Values
- return nil
-}
-
-func Convert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in *api.NodeSelectorRequirement, out *NodeSelectorRequirement, s conversion.Scope) error {
- return autoConvert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in, out, s)
-}
-
-func autoConvert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in *NodeSelectorTerm, out *api.NodeSelectorTerm, s conversion.Scope) error {
- if in.MatchExpressions != nil {
- in, out := &in.MatchExpressions, &out.MatchExpressions
- *out = make([]api.NodeSelectorRequirement, len(*in))
- for i := range *in {
- if err := Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.MatchExpressions = nil
- }
- return nil
-}
-
-func Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in *NodeSelectorTerm, out *api.NodeSelectorTerm, s conversion.Scope) error {
- return autoConvert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in, out, s)
-}
-
-func autoConvert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in *api.NodeSelectorTerm, out *NodeSelectorTerm, s conversion.Scope) error {
- if in.MatchExpressions != nil {
- in, out := &in.MatchExpressions, &out.MatchExpressions
- *out = make([]NodeSelectorRequirement, len(*in))
- for i := range *in {
- if err := Convert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.MatchExpressions = nil
- }
- return nil
-}
-
-func Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in *api.NodeSelectorTerm, out *NodeSelectorTerm, s conversion.Scope) error {
- return autoConvert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in, out, s)
-}
-
-func autoConvert_v1_NodeSpec_To_api_NodeSpec(in *NodeSpec, out *api.NodeSpec, s conversion.Scope) error {
- out.PodCIDR = in.PodCIDR
- out.ExternalID = in.ExternalID
- out.ProviderID = in.ProviderID
- out.Unschedulable = in.Unschedulable
- return nil
-}
-
-func Convert_v1_NodeSpec_To_api_NodeSpec(in *NodeSpec, out *api.NodeSpec, s conversion.Scope) error {
- return autoConvert_v1_NodeSpec_To_api_NodeSpec(in, out, s)
-}
-
-func autoConvert_api_NodeSpec_To_v1_NodeSpec(in *api.NodeSpec, out *NodeSpec, s conversion.Scope) error {
- out.PodCIDR = in.PodCIDR
- out.ExternalID = in.ExternalID
- out.ProviderID = in.ProviderID
- out.Unschedulable = in.Unschedulable
- return nil
-}
-
-func Convert_api_NodeSpec_To_v1_NodeSpec(in *api.NodeSpec, out *NodeSpec, s conversion.Scope) error {
- return autoConvert_api_NodeSpec_To_v1_NodeSpec(in, out, s)
-}
-
-func autoConvert_v1_NodeStatus_To_api_NodeStatus(in *NodeStatus, out *api.NodeStatus, s conversion.Scope) error {
- SetDefaults_NodeStatus(in)
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Capacity, &out.Capacity, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Allocatable, &out.Allocatable, s); err != nil {
- return err
- }
- out.Phase = api.NodePhase(in.Phase)
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]api.NodeCondition, len(*in))
- for i := range *in {
- if err := Convert_v1_NodeCondition_To_api_NodeCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- if in.Addresses != nil {
- in, out := &in.Addresses, &out.Addresses
- *out = make([]api.NodeAddress, len(*in))
- for i := range *in {
- if err := Convert_v1_NodeAddress_To_api_NodeAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Addresses = nil
- }
- if err := Convert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(&in.DaemonEndpoints, &out.DaemonEndpoints, s); err != nil {
- return err
- }
- if err := Convert_v1_NodeSystemInfo_To_api_NodeSystemInfo(&in.NodeInfo, &out.NodeInfo, s); err != nil {
- return err
- }
- if in.Images != nil {
- in, out := &in.Images, &out.Images
- *out = make([]api.ContainerImage, len(*in))
- for i := range *in {
- if err := Convert_v1_ContainerImage_To_api_ContainerImage(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Images = nil
- }
- if in.VolumesInUse != nil {
- in, out := &in.VolumesInUse, &out.VolumesInUse
- *out = make([]api.UniqueVolumeName, len(*in))
- for i := range *in {
- (*out)[i] = api.UniqueVolumeName((*in)[i])
- }
- } else {
- out.VolumesInUse = nil
- }
- if in.VolumesAttached != nil {
- in, out := &in.VolumesAttached, &out.VolumesAttached
- *out = make([]api.AttachedVolume, len(*in))
- for i := range *in {
- if err := Convert_v1_AttachedVolume_To_api_AttachedVolume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.VolumesAttached = nil
- }
- return nil
-}
-
-func Convert_v1_NodeStatus_To_api_NodeStatus(in *NodeStatus, out *api.NodeStatus, s conversion.Scope) error {
- return autoConvert_v1_NodeStatus_To_api_NodeStatus(in, out, s)
-}
-
-func autoConvert_api_NodeStatus_To_v1_NodeStatus(in *api.NodeStatus, out *NodeStatus, s conversion.Scope) error {
- if in.Capacity != nil {
- in, out := &in.Capacity, &out.Capacity
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Capacity = nil
- }
- if in.Allocatable != nil {
- in, out := &in.Allocatable, &out.Allocatable
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Allocatable = nil
- }
- out.Phase = NodePhase(in.Phase)
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]NodeCondition, len(*in))
- for i := range *in {
- if err := Convert_api_NodeCondition_To_v1_NodeCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- if in.Addresses != nil {
- in, out := &in.Addresses, &out.Addresses
- *out = make([]NodeAddress, len(*in))
- for i := range *in {
- if err := Convert_api_NodeAddress_To_v1_NodeAddress(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Addresses = nil
- }
- if err := Convert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(&in.DaemonEndpoints, &out.DaemonEndpoints, s); err != nil {
- return err
- }
- if err := Convert_api_NodeSystemInfo_To_v1_NodeSystemInfo(&in.NodeInfo, &out.NodeInfo, s); err != nil {
- return err
- }
- if in.Images != nil {
- in, out := &in.Images, &out.Images
- *out = make([]ContainerImage, len(*in))
- for i := range *in {
- if err := Convert_api_ContainerImage_To_v1_ContainerImage(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Images = nil
- }
- if in.VolumesInUse != nil {
- in, out := &in.VolumesInUse, &out.VolumesInUse
- *out = make([]UniqueVolumeName, len(*in))
- for i := range *in {
- (*out)[i] = UniqueVolumeName((*in)[i])
- }
- } else {
- out.VolumesInUse = nil
- }
- if in.VolumesAttached != nil {
- in, out := &in.VolumesAttached, &out.VolumesAttached
- *out = make([]AttachedVolume, len(*in))
- for i := range *in {
- if err := Convert_api_AttachedVolume_To_v1_AttachedVolume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.VolumesAttached = nil
- }
- return nil
-}
-
-func Convert_api_NodeStatus_To_v1_NodeStatus(in *api.NodeStatus, out *NodeStatus, s conversion.Scope) error {
- return autoConvert_api_NodeStatus_To_v1_NodeStatus(in, out, s)
-}
-
-func autoConvert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in *NodeSystemInfo, out *api.NodeSystemInfo, s conversion.Scope) error {
- out.MachineID = in.MachineID
- out.SystemUUID = in.SystemUUID
- out.BootID = in.BootID
- out.KernelVersion = in.KernelVersion
- out.OSImage = in.OSImage
- out.ContainerRuntimeVersion = in.ContainerRuntimeVersion
- out.KubeletVersion = in.KubeletVersion
- out.KubeProxyVersion = in.KubeProxyVersion
- out.OperatingSystem = in.OperatingSystem
- out.Architecture = in.Architecture
- return nil
-}
-
-func Convert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in *NodeSystemInfo, out *api.NodeSystemInfo, s conversion.Scope) error {
- return autoConvert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in, out, s)
-}
-
-func autoConvert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in *api.NodeSystemInfo, out *NodeSystemInfo, s conversion.Scope) error {
- out.MachineID = in.MachineID
- out.SystemUUID = in.SystemUUID
- out.BootID = in.BootID
- out.KernelVersion = in.KernelVersion
- out.OSImage = in.OSImage
- out.ContainerRuntimeVersion = in.ContainerRuntimeVersion
- out.KubeletVersion = in.KubeletVersion
- out.KubeProxyVersion = in.KubeProxyVersion
- out.OperatingSystem = in.OperatingSystem
- out.Architecture = in.Architecture
- return nil
-}
-
-func Convert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in *api.NodeSystemInfo, out *NodeSystemInfo, s conversion.Scope) error {
- return autoConvert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in, out, s)
-}
-
-func autoConvert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in *ObjectFieldSelector, out *api.ObjectFieldSelector, s conversion.Scope) error {
- SetDefaults_ObjectFieldSelector(in)
- out.APIVersion = in.APIVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in *ObjectFieldSelector, out *api.ObjectFieldSelector, s conversion.Scope) error {
- return autoConvert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in, out, s)
-}
-
-func autoConvert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in *api.ObjectFieldSelector, out *ObjectFieldSelector, s conversion.Scope) error {
- out.APIVersion = in.APIVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in *api.ObjectFieldSelector, out *ObjectFieldSelector, s conversion.Scope) error {
- return autoConvert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in, out, s)
-}
-
-func autoConvert_v1_ObjectMeta_To_api_ObjectMeta(in *ObjectMeta, out *api.ObjectMeta, s conversion.Scope) error {
- out.Name = in.Name
- out.GenerateName = in.GenerateName
- out.Namespace = in.Namespace
- out.SelfLink = in.SelfLink
- out.UID = types.UID(in.UID)
- out.ResourceVersion = in.ResourceVersion
- out.Generation = in.Generation
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.CreationTimestamp, &out.CreationTimestamp, s); err != nil {
- return err
- }
- out.DeletionTimestamp = in.DeletionTimestamp
- out.DeletionGracePeriodSeconds = in.DeletionGracePeriodSeconds
- out.Labels = in.Labels
- out.Annotations = in.Annotations
- if in.OwnerReferences != nil {
- in, out := &in.OwnerReferences, &out.OwnerReferences
- *out = make([]api.OwnerReference, len(*in))
- for i := range *in {
- if err := Convert_v1_OwnerReference_To_api_OwnerReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.OwnerReferences = nil
- }
- out.Finalizers = in.Finalizers
- return nil
-}
-
-func Convert_v1_ObjectMeta_To_api_ObjectMeta(in *ObjectMeta, out *api.ObjectMeta, s conversion.Scope) error {
- return autoConvert_v1_ObjectMeta_To_api_ObjectMeta(in, out, s)
-}
-
-func autoConvert_api_ObjectMeta_To_v1_ObjectMeta(in *api.ObjectMeta, out *ObjectMeta, s conversion.Scope) error {
- out.Name = in.Name
- out.GenerateName = in.GenerateName
- out.Namespace = in.Namespace
- out.SelfLink = in.SelfLink
- out.UID = types.UID(in.UID)
- out.ResourceVersion = in.ResourceVersion
- out.Generation = in.Generation
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.CreationTimestamp, &out.CreationTimestamp, s); err != nil {
- return err
- }
- out.DeletionTimestamp = in.DeletionTimestamp
- out.DeletionGracePeriodSeconds = in.DeletionGracePeriodSeconds
- out.Labels = in.Labels
- out.Annotations = in.Annotations
- if in.OwnerReferences != nil {
- in, out := &in.OwnerReferences, &out.OwnerReferences
- *out = make([]OwnerReference, len(*in))
- for i := range *in {
- if err := Convert_api_OwnerReference_To_v1_OwnerReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.OwnerReferences = nil
- }
- out.Finalizers = in.Finalizers
- return nil
-}
-
-func Convert_api_ObjectMeta_To_v1_ObjectMeta(in *api.ObjectMeta, out *ObjectMeta, s conversion.Scope) error {
- return autoConvert_api_ObjectMeta_To_v1_ObjectMeta(in, out, s)
-}
-
-func autoConvert_v1_ObjectReference_To_api_ObjectReference(in *ObjectReference, out *api.ObjectReference, s conversion.Scope) error {
- out.Kind = in.Kind
- out.Namespace = in.Namespace
- out.Name = in.Name
- out.UID = types.UID(in.UID)
- out.APIVersion = in.APIVersion
- out.ResourceVersion = in.ResourceVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func Convert_v1_ObjectReference_To_api_ObjectReference(in *ObjectReference, out *api.ObjectReference, s conversion.Scope) error {
- return autoConvert_v1_ObjectReference_To_api_ObjectReference(in, out, s)
-}
-
-func autoConvert_api_ObjectReference_To_v1_ObjectReference(in *api.ObjectReference, out *ObjectReference, s conversion.Scope) error {
- out.Kind = in.Kind
- out.Namespace = in.Namespace
- out.Name = in.Name
- out.UID = types.UID(in.UID)
- out.APIVersion = in.APIVersion
- out.ResourceVersion = in.ResourceVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func Convert_api_ObjectReference_To_v1_ObjectReference(in *api.ObjectReference, out *ObjectReference, s conversion.Scope) error {
- return autoConvert_api_ObjectReference_To_v1_ObjectReference(in, out, s)
-}
-
-func autoConvert_v1_OwnerReference_To_api_OwnerReference(in *OwnerReference, out *api.OwnerReference, s conversion.Scope) error {
- out.APIVersion = in.APIVersion
- out.Kind = in.Kind
- out.Name = in.Name
- out.UID = types.UID(in.UID)
- out.Controller = in.Controller
- return nil
-}
-
-func Convert_v1_OwnerReference_To_api_OwnerReference(in *OwnerReference, out *api.OwnerReference, s conversion.Scope) error {
- return autoConvert_v1_OwnerReference_To_api_OwnerReference(in, out, s)
-}
-
-func autoConvert_api_OwnerReference_To_v1_OwnerReference(in *api.OwnerReference, out *OwnerReference, s conversion.Scope) error {
- out.APIVersion = in.APIVersion
- out.Kind = in.Kind
- out.Name = in.Name
- out.UID = types.UID(in.UID)
- out.Controller = in.Controller
- return nil
-}
-
-func Convert_api_OwnerReference_To_v1_OwnerReference(in *api.OwnerReference, out *OwnerReference, s conversion.Scope) error {
- return autoConvert_api_OwnerReference_To_v1_OwnerReference(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolume_To_api_PersistentVolume(in *PersistentVolume, out *api.PersistentVolume, s conversion.Scope) error {
- SetDefaults_PersistentVolume(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_PersistentVolume_To_api_PersistentVolume(in *PersistentVolume, out *api.PersistentVolume, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolume_To_api_PersistentVolume(in, out, s)
-}
-
-func autoConvert_api_PersistentVolume_To_v1_PersistentVolume(in *api.PersistentVolume, out *PersistentVolume, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_PersistentVolume_To_v1_PersistentVolume(in *api.PersistentVolume, out *PersistentVolume, s conversion.Scope) error {
- return autoConvert_api_PersistentVolume_To_v1_PersistentVolume(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in *PersistentVolumeClaim, out *api.PersistentVolumeClaim, s conversion.Scope) error {
- SetDefaults_PersistentVolumeClaim(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in *PersistentVolumeClaim, out *api.PersistentVolumeClaim, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in *api.PersistentVolumeClaim, out *PersistentVolumeClaim, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in *api.PersistentVolumeClaim, out *PersistentVolumeClaim, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(in *PersistentVolumeClaimList, out *api.PersistentVolumeClaimList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.PersistentVolumeClaim, len(*in))
- for i := range *in {
- if err := Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(in *PersistentVolumeClaimList, out *api.PersistentVolumeClaimList, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in *api.PersistentVolumeClaimList, out *PersistentVolumeClaimList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]PersistentVolumeClaim, len(*in))
- for i := range *in {
- if err := Convert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in *api.PersistentVolumeClaimList, out *PersistentVolumeClaimList, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in *PersistentVolumeClaimSpec, out *api.PersistentVolumeClaimSpec, s conversion.Scope) error {
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]api.PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = api.PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- out.Selector = in.Selector
- if err := Convert_v1_ResourceRequirements_To_api_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil {
- return err
- }
- out.VolumeName = in.VolumeName
- return nil
-}
-
-func Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in *PersistentVolumeClaimSpec, out *api.PersistentVolumeClaimSpec, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in *api.PersistentVolumeClaimSpec, out *PersistentVolumeClaimSpec, s conversion.Scope) error {
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- out.Selector = in.Selector
- if err := Convert_api_ResourceRequirements_To_v1_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil {
- return err
- }
- out.VolumeName = in.VolumeName
- return nil
-}
-
-func Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in *api.PersistentVolumeClaimSpec, out *PersistentVolumeClaimSpec, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(in *PersistentVolumeClaimStatus, out *api.PersistentVolumeClaimStatus, s conversion.Scope) error {
- out.Phase = api.PersistentVolumeClaimPhase(in.Phase)
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]api.PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = api.PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Capacity, &out.Capacity, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(in *PersistentVolumeClaimStatus, out *api.PersistentVolumeClaimStatus, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(in *api.PersistentVolumeClaimStatus, out *PersistentVolumeClaimStatus, s conversion.Scope) error {
- out.Phase = PersistentVolumeClaimPhase(in.Phase)
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- if in.Capacity != nil {
- in, out := &in.Capacity, &out.Capacity
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Capacity = nil
- }
- return nil
-}
-
-func Convert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(in *api.PersistentVolumeClaimStatus, out *PersistentVolumeClaimStatus, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(in *PersistentVolumeClaimVolumeSource, out *api.PersistentVolumeClaimVolumeSource, s conversion.Scope) error {
- out.ClaimName = in.ClaimName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(in *PersistentVolumeClaimVolumeSource, out *api.PersistentVolumeClaimVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(in *api.PersistentVolumeClaimVolumeSource, out *PersistentVolumeClaimVolumeSource, s conversion.Scope) error {
- out.ClaimName = in.ClaimName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(in *api.PersistentVolumeClaimVolumeSource, out *PersistentVolumeClaimVolumeSource, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in *PersistentVolumeList, out *api.PersistentVolumeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.PersistentVolume, len(*in))
- for i := range *in {
- if err := Convert_v1_PersistentVolume_To_api_PersistentVolume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in *PersistentVolumeList, out *api.PersistentVolumeList, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in *api.PersistentVolumeList, out *PersistentVolumeList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]PersistentVolume, len(*in))
- for i := range *in {
- if err := Convert_api_PersistentVolume_To_v1_PersistentVolume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in *api.PersistentVolumeList, out *PersistentVolumeList, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in *PersistentVolumeSource, out *api.PersistentVolumeSource, s conversion.Scope) error {
- if in.GCEPersistentDisk != nil {
- in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(api.GCEPersistentDiskVolumeSource)
- if err := Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(api.AWSElasticBlockStoreVolumeSource)
- if err := Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.HostPath != nil {
- in, out := &in.HostPath, &out.HostPath
- *out = new(api.HostPathVolumeSource)
- if err := Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HostPath = nil
- }
- if in.Glusterfs != nil {
- in, out := &in.Glusterfs, &out.Glusterfs
- *out = new(api.GlusterfsVolumeSource)
- if err := Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Glusterfs = nil
- }
- if in.NFS != nil {
- in, out := &in.NFS, &out.NFS
- *out = new(api.NFSVolumeSource)
- if err := Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NFS = nil
- }
- if in.RBD != nil {
- in, out := &in.RBD, &out.RBD
- *out = new(api.RBDVolumeSource)
- if err := Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.ISCSI != nil {
- in, out := &in.ISCSI, &out.ISCSI
- *out = new(api.ISCSIVolumeSource)
- if err := Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ISCSI = nil
- }
- if in.Cinder != nil {
- in, out := &in.Cinder, &out.Cinder
- *out = new(api.CinderVolumeSource)
- if err := Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := &in.CephFS, &out.CephFS
- *out = new(api.CephFSVolumeSource)
- if err := Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.FC != nil {
- in, out := &in.FC, &out.FC
- *out = new(api.FCVolumeSource)
- if err := Convert_v1_FCVolumeSource_To_api_FCVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.Flocker != nil {
- in, out := &in.Flocker, &out.Flocker
- *out = new(api.FlockerVolumeSource)
- if err := Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Flocker = nil
- }
- if in.FlexVolume != nil {
- in, out := &in.FlexVolume, &out.FlexVolume
- *out = new(api.FlexVolumeSource)
- if err := Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.AzureFile != nil {
- in, out := &in.AzureFile, &out.AzureFile
- *out = new(api.AzureFileVolumeSource)
- if err := Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AzureFile = nil
- }
- if in.VsphereVolume != nil {
- in, out := &in.VsphereVolume, &out.VsphereVolume
- *out = new(api.VsphereVirtualDiskVolumeSource)
- if err := Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func Convert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in *PersistentVolumeSource, out *api.PersistentVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in *api.PersistentVolumeSource, out *PersistentVolumeSource, s conversion.Scope) error {
- if in.GCEPersistentDisk != nil {
- in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(GCEPersistentDiskVolumeSource)
- if err := Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(AWSElasticBlockStoreVolumeSource)
- if err := Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.HostPath != nil {
- in, out := &in.HostPath, &out.HostPath
- *out = new(HostPathVolumeSource)
- if err := Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HostPath = nil
- }
- if in.Glusterfs != nil {
- in, out := &in.Glusterfs, &out.Glusterfs
- *out = new(GlusterfsVolumeSource)
- if err := Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Glusterfs = nil
- }
- if in.NFS != nil {
- in, out := &in.NFS, &out.NFS
- *out = new(NFSVolumeSource)
- if err := Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NFS = nil
- }
- if in.RBD != nil {
- in, out := &in.RBD, &out.RBD
- *out = new(RBDVolumeSource)
- if err := Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.ISCSI != nil {
- in, out := &in.ISCSI, &out.ISCSI
- *out = new(ISCSIVolumeSource)
- if err := Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ISCSI = nil
- }
- if in.FlexVolume != nil {
- in, out := &in.FlexVolume, &out.FlexVolume
- *out = new(FlexVolumeSource)
- if err := Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.Cinder != nil {
- in, out := &in.Cinder, &out.Cinder
- *out = new(CinderVolumeSource)
- if err := Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := &in.CephFS, &out.CephFS
- *out = new(CephFSVolumeSource)
- if err := Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.FC != nil {
- in, out := &in.FC, &out.FC
- *out = new(FCVolumeSource)
- if err := Convert_api_FCVolumeSource_To_v1_FCVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.Flocker != nil {
- in, out := &in.Flocker, &out.Flocker
- *out = new(FlockerVolumeSource)
- if err := Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Flocker = nil
- }
- if in.AzureFile != nil {
- in, out := &in.AzureFile, &out.AzureFile
- *out = new(AzureFileVolumeSource)
- if err := Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AzureFile = nil
- }
- if in.VsphereVolume != nil {
- in, out := &in.VsphereVolume, &out.VsphereVolume
- *out = new(VsphereVirtualDiskVolumeSource)
- if err := Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func Convert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in *api.PersistentVolumeSource, out *PersistentVolumeSource, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in *PersistentVolumeSpec, out *api.PersistentVolumeSpec, s conversion.Scope) error {
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Capacity, &out.Capacity, s); err != nil {
- return err
- }
- if err := Convert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(&in.PersistentVolumeSource, &out.PersistentVolumeSource, s); err != nil {
- return err
- }
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]api.PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = api.PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- if in.ClaimRef != nil {
- in, out := &in.ClaimRef, &out.ClaimRef
- *out = new(api.ObjectReference)
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ClaimRef = nil
- }
- out.PersistentVolumeReclaimPolicy = api.PersistentVolumeReclaimPolicy(in.PersistentVolumeReclaimPolicy)
- return nil
-}
-
-func Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in *PersistentVolumeSpec, out *api.PersistentVolumeSpec, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in *api.PersistentVolumeSpec, out *PersistentVolumeSpec, s conversion.Scope) error {
- if in.Capacity != nil {
- in, out := &in.Capacity, &out.Capacity
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Capacity = nil
- }
- if err := Convert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(&in.PersistentVolumeSource, &out.PersistentVolumeSource, s); err != nil {
- return err
- }
- if in.AccessModes != nil {
- in, out := &in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(*in))
- for i := range *in {
- (*out)[i] = PersistentVolumeAccessMode((*in)[i])
- }
- } else {
- out.AccessModes = nil
- }
- if in.ClaimRef != nil {
- in, out := &in.ClaimRef, &out.ClaimRef
- *out = new(ObjectReference)
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ClaimRef = nil
- }
- out.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(in.PersistentVolumeReclaimPolicy)
- return nil
-}
-
-func Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in *api.PersistentVolumeSpec, out *PersistentVolumeSpec, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in, out, s)
-}
-
-func autoConvert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in *PersistentVolumeStatus, out *api.PersistentVolumeStatus, s conversion.Scope) error {
- out.Phase = api.PersistentVolumePhase(in.Phase)
- out.Message = in.Message
- out.Reason = in.Reason
- return nil
-}
-
-func Convert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in *PersistentVolumeStatus, out *api.PersistentVolumeStatus, s conversion.Scope) error {
- return autoConvert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in, out, s)
-}
-
-func autoConvert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in *api.PersistentVolumeStatus, out *PersistentVolumeStatus, s conversion.Scope) error {
- out.Phase = PersistentVolumePhase(in.Phase)
- out.Message = in.Message
- out.Reason = in.Reason
- return nil
-}
-
-func Convert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in *api.PersistentVolumeStatus, out *PersistentVolumeStatus, s conversion.Scope) error {
- return autoConvert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in, out, s)
-}
-
-func autoConvert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) error {
- SetDefaults_Pod(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PodSpec_To_api_PodSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_PodStatus_To_api_PodStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_api_Pod_To_v1_Pod(in *api.Pod, out *Pod, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PodSpec_To_v1_PodSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_PodStatus_To_v1_PodStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_v1_PodAffinity_To_api_PodAffinity(in *PodAffinity, out *api.PodAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]api.PodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]api.WeightedPodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_v1_PodAffinity_To_api_PodAffinity(in *PodAffinity, out *api.PodAffinity, s conversion.Scope) error {
- return autoConvert_v1_PodAffinity_To_api_PodAffinity(in, out, s)
-}
-
-func autoConvert_api_PodAffinity_To_v1_PodAffinity(in *api.PodAffinity, out *PodAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]PodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]WeightedPodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_api_PodAffinity_To_v1_PodAffinity(in *api.PodAffinity, out *PodAffinity, s conversion.Scope) error {
- return autoConvert_api_PodAffinity_To_v1_PodAffinity(in, out, s)
-}
-
-func autoConvert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in *PodAffinityTerm, out *api.PodAffinityTerm, s conversion.Scope) error {
- out.LabelSelector = in.LabelSelector
- out.Namespaces = in.Namespaces
- out.TopologyKey = in.TopologyKey
- return nil
-}
-
-func Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in *PodAffinityTerm, out *api.PodAffinityTerm, s conversion.Scope) error {
- return autoConvert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in, out, s)
-}
-
-func autoConvert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in *api.PodAffinityTerm, out *PodAffinityTerm, s conversion.Scope) error {
- out.LabelSelector = in.LabelSelector
- out.Namespaces = in.Namespaces
- out.TopologyKey = in.TopologyKey
- return nil
-}
-
-func Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in *api.PodAffinityTerm, out *PodAffinityTerm, s conversion.Scope) error {
- return autoConvert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in, out, s)
-}
-
-func autoConvert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in *PodAntiAffinity, out *api.PodAntiAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]api.PodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]api.WeightedPodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in *PodAntiAffinity, out *api.PodAntiAffinity, s conversion.Scope) error {
- return autoConvert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in, out, s)
-}
-
-func autoConvert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in *api.PodAntiAffinity, out *PodAntiAffinity, s conversion.Scope) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]PodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]WeightedPodAffinityTerm, len(*in))
- for i := range *in {
- if err := Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func Convert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in *api.PodAntiAffinity, out *PodAntiAffinity, s conversion.Scope) error {
- return autoConvert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in, out, s)
-}
-
-func autoConvert_v1_PodAttachOptions_To_api_PodAttachOptions(in *PodAttachOptions, out *api.PodAttachOptions, s conversion.Scope) error {
- SetDefaults_PodAttachOptions(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- return nil
-}
-
-func Convert_v1_PodAttachOptions_To_api_PodAttachOptions(in *PodAttachOptions, out *api.PodAttachOptions, s conversion.Scope) error {
- return autoConvert_v1_PodAttachOptions_To_api_PodAttachOptions(in, out, s)
-}
-
-func autoConvert_api_PodAttachOptions_To_v1_PodAttachOptions(in *api.PodAttachOptions, out *PodAttachOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- return nil
-}
-
-func Convert_api_PodAttachOptions_To_v1_PodAttachOptions(in *api.PodAttachOptions, out *PodAttachOptions, s conversion.Scope) error {
- return autoConvert_api_PodAttachOptions_To_v1_PodAttachOptions(in, out, s)
-}
-
-func autoConvert_v1_PodCondition_To_api_PodCondition(in *PodCondition, out *api.PodCondition, s conversion.Scope) error {
- out.Type = api.PodConditionType(in.Type)
- out.Status = api.ConditionStatus(in.Status)
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastProbeTime, &out.LastProbeTime, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTransitionTime, &out.LastTransitionTime, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_v1_PodCondition_To_api_PodCondition(in *PodCondition, out *api.PodCondition, s conversion.Scope) error {
- return autoConvert_v1_PodCondition_To_api_PodCondition(in, out, s)
-}
-
-func autoConvert_api_PodCondition_To_v1_PodCondition(in *api.PodCondition, out *PodCondition, s conversion.Scope) error {
- out.Type = PodConditionType(in.Type)
- out.Status = ConditionStatus(in.Status)
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastProbeTime, &out.LastProbeTime, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_Time_To_unversioned_Time(&in.LastTransitionTime, &out.LastTransitionTime, s); err != nil {
- return err
- }
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func Convert_api_PodCondition_To_v1_PodCondition(in *api.PodCondition, out *PodCondition, s conversion.Scope) error {
- return autoConvert_api_PodCondition_To_v1_PodCondition(in, out, s)
-}
-
-func autoConvert_v1_PodExecOptions_To_api_PodExecOptions(in *PodExecOptions, out *api.PodExecOptions, s conversion.Scope) error {
- SetDefaults_PodExecOptions(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- out.Command = in.Command
- return nil
-}
-
-func Convert_v1_PodExecOptions_To_api_PodExecOptions(in *PodExecOptions, out *api.PodExecOptions, s conversion.Scope) error {
- return autoConvert_v1_PodExecOptions_To_api_PodExecOptions(in, out, s)
-}
-
-func autoConvert_api_PodExecOptions_To_v1_PodExecOptions(in *api.PodExecOptions, out *PodExecOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- out.Command = in.Command
- return nil
-}
-
-func Convert_api_PodExecOptions_To_v1_PodExecOptions(in *api.PodExecOptions, out *PodExecOptions, s conversion.Scope) error {
- return autoConvert_api_PodExecOptions_To_v1_PodExecOptions(in, out, s)
-}
-
-func autoConvert_v1_PodList_To_api_PodList(in *PodList, out *api.PodList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Pod, len(*in))
- for i := range *in {
- if err := Convert_v1_Pod_To_api_Pod(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_PodList_To_api_PodList(in *PodList, out *api.PodList, s conversion.Scope) error {
- return autoConvert_v1_PodList_To_api_PodList(in, out, s)
-}
-
-func autoConvert_api_PodList_To_v1_PodList(in *api.PodList, out *PodList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Pod, len(*in))
- for i := range *in {
- if err := Convert_api_Pod_To_v1_Pod(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_PodList_To_v1_PodList(in *api.PodList, out *PodList, s conversion.Scope) error {
- return autoConvert_api_PodList_To_v1_PodList(in, out, s)
-}
-
-func autoConvert_v1_PodLogOptions_To_api_PodLogOptions(in *PodLogOptions, out *api.PodLogOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Container = in.Container
- out.Follow = in.Follow
- out.Previous = in.Previous
- out.SinceSeconds = in.SinceSeconds
- out.SinceTime = in.SinceTime
- out.Timestamps = in.Timestamps
- out.TailLines = in.TailLines
- out.LimitBytes = in.LimitBytes
- return nil
-}
-
-func Convert_v1_PodLogOptions_To_api_PodLogOptions(in *PodLogOptions, out *api.PodLogOptions, s conversion.Scope) error {
- return autoConvert_v1_PodLogOptions_To_api_PodLogOptions(in, out, s)
-}
-
-func autoConvert_api_PodLogOptions_To_v1_PodLogOptions(in *api.PodLogOptions, out *PodLogOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Container = in.Container
- out.Follow = in.Follow
- out.Previous = in.Previous
- out.SinceSeconds = in.SinceSeconds
- out.SinceTime = in.SinceTime
- out.Timestamps = in.Timestamps
- out.TailLines = in.TailLines
- out.LimitBytes = in.LimitBytes
- return nil
-}
-
-func Convert_api_PodLogOptions_To_v1_PodLogOptions(in *api.PodLogOptions, out *PodLogOptions, s conversion.Scope) error {
- return autoConvert_api_PodLogOptions_To_v1_PodLogOptions(in, out, s)
-}
-
-func autoConvert_v1_PodProxyOptions_To_api_PodProxyOptions(in *PodProxyOptions, out *api.PodProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_v1_PodProxyOptions_To_api_PodProxyOptions(in *PodProxyOptions, out *api.PodProxyOptions, s conversion.Scope) error {
- return autoConvert_v1_PodProxyOptions_To_api_PodProxyOptions(in, out, s)
-}
-
-func autoConvert_api_PodProxyOptions_To_v1_PodProxyOptions(in *api.PodProxyOptions, out *PodProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_api_PodProxyOptions_To_v1_PodProxyOptions(in *api.PodProxyOptions, out *PodProxyOptions, s conversion.Scope) error {
- return autoConvert_api_PodProxyOptions_To_v1_PodProxyOptions(in, out, s)
-}
-
-func autoConvert_v1_PodSecurityContext_To_api_PodSecurityContext(in *PodSecurityContext, out *api.PodSecurityContext, s conversion.Scope) error {
- if in.SELinuxOptions != nil {
- in, out := &in.SELinuxOptions, &out.SELinuxOptions
- *out = new(api.SELinuxOptions)
- if err := Convert_v1_SELinuxOptions_To_api_SELinuxOptions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.SupplementalGroups = in.SupplementalGroups
- out.FSGroup = in.FSGroup
- return nil
-}
-
-func autoConvert_api_PodSecurityContext_To_v1_PodSecurityContext(in *api.PodSecurityContext, out *PodSecurityContext, s conversion.Scope) error {
- if in.SELinuxOptions != nil {
- in, out := &in.SELinuxOptions, &out.SELinuxOptions
- *out = new(SELinuxOptions)
- if err := Convert_api_SELinuxOptions_To_v1_SELinuxOptions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.SupplementalGroups = in.SupplementalGroups
- out.FSGroup = in.FSGroup
- return nil
-}
-
-func autoConvert_v1_PodSpec_To_api_PodSpec(in *PodSpec, out *api.PodSpec, s conversion.Scope) error {
- SetDefaults_PodSpec(in)
- if in.Volumes != nil {
- in, out := &in.Volumes, &out.Volumes
- *out = make([]api.Volume, len(*in))
- for i := range *in {
- if err := Convert_v1_Volume_To_api_Volume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Volumes = nil
- }
- if in.InitContainers != nil {
- in, out := &in.InitContainers, &out.InitContainers
- *out = make([]api.Container, len(*in))
- for i := range *in {
- if err := Convert_v1_Container_To_api_Container(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.InitContainers = nil
- }
- if in.Containers != nil {
- in, out := &in.Containers, &out.Containers
- *out = make([]api.Container, len(*in))
- for i := range *in {
- if err := Convert_v1_Container_To_api_Container(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Containers = nil
- }
- out.RestartPolicy = api.RestartPolicy(in.RestartPolicy)
- out.TerminationGracePeriodSeconds = in.TerminationGracePeriodSeconds
- out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds
- out.DNSPolicy = api.DNSPolicy(in.DNSPolicy)
- out.NodeSelector = in.NodeSelector
- out.ServiceAccountName = in.ServiceAccountName
- out.NodeName = in.NodeName
- if in.SecurityContext != nil {
- in, out := &in.SecurityContext, &out.SecurityContext
- *out = new(api.PodSecurityContext)
- if err := Convert_v1_PodSecurityContext_To_api_PodSecurityContext(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := &in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]api.LocalObjectReference, len(*in))
- for i := range *in {
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ImagePullSecrets = nil
- }
- out.Hostname = in.Hostname
- out.Subdomain = in.Subdomain
- return nil
-}
-
-func autoConvert_api_PodSpec_To_v1_PodSpec(in *api.PodSpec, out *PodSpec, s conversion.Scope) error {
- if in.Volumes != nil {
- in, out := &in.Volumes, &out.Volumes
- *out = make([]Volume, len(*in))
- for i := range *in {
- if err := Convert_api_Volume_To_v1_Volume(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Volumes = nil
- }
- if in.InitContainers != nil {
- in, out := &in.InitContainers, &out.InitContainers
- *out = make([]Container, len(*in))
- for i := range *in {
- if err := Convert_api_Container_To_v1_Container(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.InitContainers = nil
- }
- if in.Containers != nil {
- in, out := &in.Containers, &out.Containers
- *out = make([]Container, len(*in))
- for i := range *in {
- if err := Convert_api_Container_To_v1_Container(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Containers = nil
- }
- out.RestartPolicy = RestartPolicy(in.RestartPolicy)
- out.TerminationGracePeriodSeconds = in.TerminationGracePeriodSeconds
- out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds
- out.DNSPolicy = DNSPolicy(in.DNSPolicy)
- out.NodeSelector = in.NodeSelector
- out.ServiceAccountName = in.ServiceAccountName
- out.NodeName = in.NodeName
- if in.SecurityContext != nil {
- in, out := &in.SecurityContext, &out.SecurityContext
- *out = new(PodSecurityContext)
- if err := Convert_api_PodSecurityContext_To_v1_PodSecurityContext(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := &in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]LocalObjectReference, len(*in))
- for i := range *in {
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ImagePullSecrets = nil
- }
- out.Hostname = in.Hostname
- out.Subdomain = in.Subdomain
- return nil
-}
-
-func autoConvert_v1_PodStatus_To_api_PodStatus(in *PodStatus, out *api.PodStatus, s conversion.Scope) error {
- out.Phase = api.PodPhase(in.Phase)
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]api.PodCondition, len(*in))
- for i := range *in {
- if err := Convert_v1_PodCondition_To_api_PodCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- out.Message = in.Message
- out.Reason = in.Reason
- out.HostIP = in.HostIP
- out.PodIP = in.PodIP
- out.StartTime = in.StartTime
- if in.InitContainerStatuses != nil {
- in, out := &in.InitContainerStatuses, &out.InitContainerStatuses
- *out = make([]api.ContainerStatus, len(*in))
- for i := range *in {
- if err := Convert_v1_ContainerStatus_To_api_ContainerStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.InitContainerStatuses = nil
- }
- if in.ContainerStatuses != nil {
- in, out := &in.ContainerStatuses, &out.ContainerStatuses
- *out = make([]api.ContainerStatus, len(*in))
- for i := range *in {
- if err := Convert_v1_ContainerStatus_To_api_ContainerStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ContainerStatuses = nil
- }
- return nil
-}
-
-func Convert_v1_PodStatus_To_api_PodStatus(in *PodStatus, out *api.PodStatus, s conversion.Scope) error {
- return autoConvert_v1_PodStatus_To_api_PodStatus(in, out, s)
-}
-
-func autoConvert_api_PodStatus_To_v1_PodStatus(in *api.PodStatus, out *PodStatus, s conversion.Scope) error {
- out.Phase = PodPhase(in.Phase)
- if in.Conditions != nil {
- in, out := &in.Conditions, &out.Conditions
- *out = make([]PodCondition, len(*in))
- for i := range *in {
- if err := Convert_api_PodCondition_To_v1_PodCondition(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- out.Message = in.Message
- out.Reason = in.Reason
- out.HostIP = in.HostIP
- out.PodIP = in.PodIP
- out.StartTime = in.StartTime
- if in.InitContainerStatuses != nil {
- in, out := &in.InitContainerStatuses, &out.InitContainerStatuses
- *out = make([]ContainerStatus, len(*in))
- for i := range *in {
- if err := Convert_api_ContainerStatus_To_v1_ContainerStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.InitContainerStatuses = nil
- }
- if in.ContainerStatuses != nil {
- in, out := &in.ContainerStatuses, &out.ContainerStatuses
- *out = make([]ContainerStatus, len(*in))
- for i := range *in {
- if err := Convert_api_ContainerStatus_To_v1_ContainerStatus(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ContainerStatuses = nil
- }
- return nil
-}
-
-func Convert_api_PodStatus_To_v1_PodStatus(in *api.PodStatus, out *PodStatus, s conversion.Scope) error {
- return autoConvert_api_PodStatus_To_v1_PodStatus(in, out, s)
-}
-
-func autoConvert_v1_PodStatusResult_To_api_PodStatusResult(in *PodStatusResult, out *api.PodStatusResult, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PodStatus_To_api_PodStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_api_PodStatusResult_To_v1_PodStatusResult(in *api.PodStatusResult, out *PodStatusResult, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PodStatus_To_v1_PodStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_v1_PodTemplate_To_api_PodTemplate(in *PodTemplate, out *api.PodTemplate, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_PodTemplate_To_api_PodTemplate(in *PodTemplate, out *api.PodTemplate, s conversion.Scope) error {
- return autoConvert_v1_PodTemplate_To_api_PodTemplate(in, out, s)
-}
-
-func autoConvert_api_PodTemplate_To_v1_PodTemplate(in *api.PodTemplate, out *PodTemplate, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_PodTemplate_To_v1_PodTemplate(in *api.PodTemplate, out *PodTemplate, s conversion.Scope) error {
- return autoConvert_api_PodTemplate_To_v1_PodTemplate(in, out, s)
-}
-
-func autoConvert_v1_PodTemplateList_To_api_PodTemplateList(in *PodTemplateList, out *api.PodTemplateList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.PodTemplate, len(*in))
- for i := range *in {
- if err := Convert_v1_PodTemplate_To_api_PodTemplate(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_PodTemplateList_To_api_PodTemplateList(in *PodTemplateList, out *api.PodTemplateList, s conversion.Scope) error {
- return autoConvert_v1_PodTemplateList_To_api_PodTemplateList(in, out, s)
-}
-
-func autoConvert_api_PodTemplateList_To_v1_PodTemplateList(in *api.PodTemplateList, out *PodTemplateList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]PodTemplate, len(*in))
- for i := range *in {
- if err := Convert_api_PodTemplate_To_v1_PodTemplate(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_PodTemplateList_To_v1_PodTemplateList(in *api.PodTemplateList, out *PodTemplateList, s conversion.Scope) error {
- return autoConvert_api_PodTemplateList_To_v1_PodTemplateList(in, out, s)
-}
-
-func autoConvert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in *PodTemplateSpec, out *api.PodTemplateSpec, s conversion.Scope) error {
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_PodSpec_To_api_PodSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_api_PodTemplateSpec_To_v1_PodTemplateSpec(in *api.PodTemplateSpec, out *PodTemplateSpec, s conversion.Scope) error {
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_PodSpec_To_v1_PodSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- return nil
-}
-
-func autoConvert_v1_Preconditions_To_api_Preconditions(in *Preconditions, out *api.Preconditions, s conversion.Scope) error {
- out.UID = in.UID
- return nil
-}
-
-func Convert_v1_Preconditions_To_api_Preconditions(in *Preconditions, out *api.Preconditions, s conversion.Scope) error {
- return autoConvert_v1_Preconditions_To_api_Preconditions(in, out, s)
-}
-
-func autoConvert_api_Preconditions_To_v1_Preconditions(in *api.Preconditions, out *Preconditions, s conversion.Scope) error {
- out.UID = in.UID
- return nil
-}
-
-func Convert_api_Preconditions_To_v1_Preconditions(in *api.Preconditions, out *Preconditions, s conversion.Scope) error {
- return autoConvert_api_Preconditions_To_v1_Preconditions(in, out, s)
-}
-
-func autoConvert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in *PreferredSchedulingTerm, out *api.PreferredSchedulingTerm, s conversion.Scope) error {
- out.Weight = in.Weight
- if err := Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(&in.Preference, &out.Preference, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in *PreferredSchedulingTerm, out *api.PreferredSchedulingTerm, s conversion.Scope) error {
- return autoConvert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in, out, s)
-}
-
-func autoConvert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in *api.PreferredSchedulingTerm, out *PreferredSchedulingTerm, s conversion.Scope) error {
- out.Weight = in.Weight
- if err := Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(&in.Preference, &out.Preference, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in *api.PreferredSchedulingTerm, out *PreferredSchedulingTerm, s conversion.Scope) error {
- return autoConvert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in, out, s)
-}
-
-func autoConvert_v1_Probe_To_api_Probe(in *Probe, out *api.Probe, s conversion.Scope) error {
- SetDefaults_Probe(in)
- if err := Convert_v1_Handler_To_api_Handler(&in.Handler, &out.Handler, s); err != nil {
- return err
- }
- out.InitialDelaySeconds = in.InitialDelaySeconds
- out.TimeoutSeconds = in.TimeoutSeconds
- out.PeriodSeconds = in.PeriodSeconds
- out.SuccessThreshold = in.SuccessThreshold
- out.FailureThreshold = in.FailureThreshold
- return nil
-}
-
-func Convert_v1_Probe_To_api_Probe(in *Probe, out *api.Probe, s conversion.Scope) error {
- return autoConvert_v1_Probe_To_api_Probe(in, out, s)
-}
-
-func autoConvert_api_Probe_To_v1_Probe(in *api.Probe, out *Probe, s conversion.Scope) error {
- if err := Convert_api_Handler_To_v1_Handler(&in.Handler, &out.Handler, s); err != nil {
- return err
- }
- out.InitialDelaySeconds = in.InitialDelaySeconds
- out.TimeoutSeconds = in.TimeoutSeconds
- out.PeriodSeconds = in.PeriodSeconds
- out.SuccessThreshold = in.SuccessThreshold
- out.FailureThreshold = in.FailureThreshold
- return nil
-}
-
-func Convert_api_Probe_To_v1_Probe(in *api.Probe, out *Probe, s conversion.Scope) error {
- return autoConvert_api_Probe_To_v1_Probe(in, out, s)
-}
-
-func autoConvert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in *RBDVolumeSource, out *api.RBDVolumeSource, s conversion.Scope) error {
- SetDefaults_RBDVolumeSource(in)
- out.CephMonitors = in.CephMonitors
- out.RBDImage = in.RBDImage
- out.FSType = in.FSType
- out.RBDPool = in.RBDPool
- out.RadosUser = in.RadosUser
- out.Keyring = in.Keyring
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(api.LocalObjectReference)
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in *RBDVolumeSource, out *api.RBDVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in, out, s)
-}
-
-func autoConvert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in *api.RBDVolumeSource, out *RBDVolumeSource, s conversion.Scope) error {
- out.CephMonitors = in.CephMonitors
- out.RBDImage = in.RBDImage
- out.FSType = in.FSType
- out.RBDPool = in.RBDPool
- out.RadosUser = in.RadosUser
- out.Keyring = in.Keyring
- if in.SecretRef != nil {
- in, out := &in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in *api.RBDVolumeSource, out *RBDVolumeSource, s conversion.Scope) error {
- return autoConvert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_RangeAllocation_To_api_RangeAllocation(in *RangeAllocation, out *api.RangeAllocation, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Range = in.Range
- if err := conversion.Convert_Slice_byte_To_Slice_byte(&in.Data, &out.Data, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_RangeAllocation_To_api_RangeAllocation(in *RangeAllocation, out *api.RangeAllocation, s conversion.Scope) error {
- return autoConvert_v1_RangeAllocation_To_api_RangeAllocation(in, out, s)
-}
-
-func autoConvert_api_RangeAllocation_To_v1_RangeAllocation(in *api.RangeAllocation, out *RangeAllocation, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Range = in.Range
- if err := conversion.Convert_Slice_byte_To_Slice_byte(&in.Data, &out.Data, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_RangeAllocation_To_v1_RangeAllocation(in *api.RangeAllocation, out *RangeAllocation, s conversion.Scope) error {
- return autoConvert_api_RangeAllocation_To_v1_RangeAllocation(in, out, s)
-}
-
-func autoConvert_v1_ReplicationController_To_api_ReplicationController(in *ReplicationController, out *api.ReplicationController, s conversion.Scope) error {
- SetDefaults_ReplicationController(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ReplicationController_To_api_ReplicationController(in *ReplicationController, out *api.ReplicationController, s conversion.Scope) error {
- return autoConvert_v1_ReplicationController_To_api_ReplicationController(in, out, s)
-}
-
-func autoConvert_api_ReplicationController_To_v1_ReplicationController(in *api.ReplicationController, out *ReplicationController, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_ReplicationController_To_v1_ReplicationController(in *api.ReplicationController, out *ReplicationController, s conversion.Scope) error {
- return autoConvert_api_ReplicationController_To_v1_ReplicationController(in, out, s)
-}
-
-func autoConvert_v1_ReplicationControllerList_To_api_ReplicationControllerList(in *ReplicationControllerList, out *api.ReplicationControllerList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.ReplicationController, len(*in))
- for i := range *in {
- if err := Convert_v1_ReplicationController_To_api_ReplicationController(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ReplicationControllerList_To_api_ReplicationControllerList(in *ReplicationControllerList, out *api.ReplicationControllerList, s conversion.Scope) error {
- return autoConvert_v1_ReplicationControllerList_To_api_ReplicationControllerList(in, out, s)
-}
-
-func autoConvert_api_ReplicationControllerList_To_v1_ReplicationControllerList(in *api.ReplicationControllerList, out *ReplicationControllerList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ReplicationController, len(*in))
- for i := range *in {
- if err := Convert_api_ReplicationController_To_v1_ReplicationController(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ReplicationControllerList_To_v1_ReplicationControllerList(in *api.ReplicationControllerList, out *ReplicationControllerList, s conversion.Scope) error {
- return autoConvert_api_ReplicationControllerList_To_v1_ReplicationControllerList(in, out, s)
-}
-
-func autoConvert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(in *ReplicationControllerStatus, out *api.ReplicationControllerStatus, s conversion.Scope) error {
- out.Replicas = in.Replicas
- out.FullyLabeledReplicas = in.FullyLabeledReplicas
- out.ObservedGeneration = in.ObservedGeneration
- return nil
-}
-
-func Convert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(in *ReplicationControllerStatus, out *api.ReplicationControllerStatus, s conversion.Scope) error {
- return autoConvert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(in, out, s)
-}
-
-func autoConvert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(in *api.ReplicationControllerStatus, out *ReplicationControllerStatus, s conversion.Scope) error {
- out.Replicas = in.Replicas
- out.FullyLabeledReplicas = in.FullyLabeledReplicas
- out.ObservedGeneration = in.ObservedGeneration
- return nil
-}
-
-func Convert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(in *api.ReplicationControllerStatus, out *ReplicationControllerStatus, s conversion.Scope) error {
- return autoConvert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(in, out, s)
-}
-
-func autoConvert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in *ResourceFieldSelector, out *api.ResourceFieldSelector, s conversion.Scope) error {
- out.ContainerName = in.ContainerName
- out.Resource = in.Resource
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&in.Divisor, &out.Divisor, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in *ResourceFieldSelector, out *api.ResourceFieldSelector, s conversion.Scope) error {
- return autoConvert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in, out, s)
-}
-
-func autoConvert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in *api.ResourceFieldSelector, out *ResourceFieldSelector, s conversion.Scope) error {
- out.ContainerName = in.ContainerName
- out.Resource = in.Resource
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&in.Divisor, &out.Divisor, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in *api.ResourceFieldSelector, out *ResourceFieldSelector, s conversion.Scope) error {
- return autoConvert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in, out, s)
-}
-
-func autoConvert_v1_ResourceQuota_To_api_ResourceQuota(in *ResourceQuota, out *api.ResourceQuota, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ResourceQuota_To_api_ResourceQuota(in *ResourceQuota, out *api.ResourceQuota, s conversion.Scope) error {
- return autoConvert_v1_ResourceQuota_To_api_ResourceQuota(in, out, s)
-}
-
-func autoConvert_api_ResourceQuota_To_v1_ResourceQuota(in *api.ResourceQuota, out *ResourceQuota, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_ResourceQuota_To_v1_ResourceQuota(in *api.ResourceQuota, out *ResourceQuota, s conversion.Scope) error {
- return autoConvert_api_ResourceQuota_To_v1_ResourceQuota(in, out, s)
-}
-
-func autoConvert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in *ResourceQuotaList, out *api.ResourceQuotaList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.ResourceQuota, len(*in))
- for i := range *in {
- if err := Convert_v1_ResourceQuota_To_api_ResourceQuota(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in *ResourceQuotaList, out *api.ResourceQuotaList, s conversion.Scope) error {
- return autoConvert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in, out, s)
-}
-
-func autoConvert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in *api.ResourceQuotaList, out *ResourceQuotaList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ResourceQuota, len(*in))
- for i := range *in {
- if err := Convert_api_ResourceQuota_To_v1_ResourceQuota(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in *api.ResourceQuotaList, out *ResourceQuotaList, s conversion.Scope) error {
- return autoConvert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in, out, s)
-}
-
-func autoConvert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in *ResourceQuotaSpec, out *api.ResourceQuotaSpec, s conversion.Scope) error {
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Hard, &out.Hard, s); err != nil {
- return err
- }
- if in.Scopes != nil {
- in, out := &in.Scopes, &out.Scopes
- *out = make([]api.ResourceQuotaScope, len(*in))
- for i := range *in {
- (*out)[i] = api.ResourceQuotaScope((*in)[i])
- }
- } else {
- out.Scopes = nil
- }
- return nil
-}
-
-func Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in *ResourceQuotaSpec, out *api.ResourceQuotaSpec, s conversion.Scope) error {
- return autoConvert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in, out, s)
-}
-
-func autoConvert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in *api.ResourceQuotaSpec, out *ResourceQuotaSpec, s conversion.Scope) error {
- if in.Hard != nil {
- in, out := &in.Hard, &out.Hard
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Hard = nil
- }
- if in.Scopes != nil {
- in, out := &in.Scopes, &out.Scopes
- *out = make([]ResourceQuotaScope, len(*in))
- for i := range *in {
- (*out)[i] = ResourceQuotaScope((*in)[i])
- }
- } else {
- out.Scopes = nil
- }
- return nil
-}
-
-func Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in *api.ResourceQuotaSpec, out *ResourceQuotaSpec, s conversion.Scope) error {
- return autoConvert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in, out, s)
-}
-
-func autoConvert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in *ResourceQuotaStatus, out *api.ResourceQuotaStatus, s conversion.Scope) error {
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Hard, &out.Hard, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Used, &out.Used, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in *ResourceQuotaStatus, out *api.ResourceQuotaStatus, s conversion.Scope) error {
- return autoConvert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in, out, s)
-}
-
-func autoConvert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in *api.ResourceQuotaStatus, out *ResourceQuotaStatus, s conversion.Scope) error {
- if in.Hard != nil {
- in, out := &in.Hard, &out.Hard
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Hard = nil
- }
- if in.Used != nil {
- in, out := &in.Used, &out.Used
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Used = nil
- }
- return nil
-}
-
-func Convert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in *api.ResourceQuotaStatus, out *ResourceQuotaStatus, s conversion.Scope) error {
- return autoConvert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in, out, s)
-}
-
-func autoConvert_v1_ResourceRequirements_To_api_ResourceRequirements(in *ResourceRequirements, out *api.ResourceRequirements, s conversion.Scope) error {
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Limits, &out.Limits, s); err != nil {
- return err
- }
- if err := Convert_v1_ResourceList_To_api_ResourceList(&in.Requests, &out.Requests, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ResourceRequirements_To_api_ResourceRequirements(in *ResourceRequirements, out *api.ResourceRequirements, s conversion.Scope) error {
- return autoConvert_v1_ResourceRequirements_To_api_ResourceRequirements(in, out, s)
-}
-
-func autoConvert_api_ResourceRequirements_To_v1_ResourceRequirements(in *api.ResourceRequirements, out *ResourceRequirements, s conversion.Scope) error {
- if in.Limits != nil {
- in, out := &in.Limits, &out.Limits
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Limits = nil
- }
- if in.Requests != nil {
- in, out := &in.Requests, &out.Requests
- *out = make(ResourceList, len(*in))
- for key, val := range *in {
- newVal := new(resource.Quantity)
- if err := api.Convert_resource_Quantity_To_resource_Quantity(&val, newVal, s); err != nil {
- return err
- }
- (*out)[ResourceName(key)] = *newVal
- }
- } else {
- out.Requests = nil
- }
- return nil
-}
-
-func Convert_api_ResourceRequirements_To_v1_ResourceRequirements(in *api.ResourceRequirements, out *ResourceRequirements, s conversion.Scope) error {
- return autoConvert_api_ResourceRequirements_To_v1_ResourceRequirements(in, out, s)
-}
-
-func autoConvert_v1_SELinuxOptions_To_api_SELinuxOptions(in *SELinuxOptions, out *api.SELinuxOptions, s conversion.Scope) error {
- out.User = in.User
- out.Role = in.Role
- out.Type = in.Type
- out.Level = in.Level
- return nil
-}
-
-func Convert_v1_SELinuxOptions_To_api_SELinuxOptions(in *SELinuxOptions, out *api.SELinuxOptions, s conversion.Scope) error {
- return autoConvert_v1_SELinuxOptions_To_api_SELinuxOptions(in, out, s)
-}
-
-func autoConvert_api_SELinuxOptions_To_v1_SELinuxOptions(in *api.SELinuxOptions, out *SELinuxOptions, s conversion.Scope) error {
- out.User = in.User
- out.Role = in.Role
- out.Type = in.Type
- out.Level = in.Level
- return nil
-}
-
-func Convert_api_SELinuxOptions_To_v1_SELinuxOptions(in *api.SELinuxOptions, out *SELinuxOptions, s conversion.Scope) error {
- return autoConvert_api_SELinuxOptions_To_v1_SELinuxOptions(in, out, s)
-}
-
-func autoConvert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversion.Scope) error {
- SetDefaults_Secret(in)
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Data = in.Data
- out.Type = api.SecretType(in.Type)
- return nil
-}
-
-func autoConvert_api_Secret_To_v1_Secret(in *api.Secret, out *Secret, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- out.Data = in.Data
- out.Type = SecretType(in.Type)
- return nil
-}
-
-func Convert_api_Secret_To_v1_Secret(in *api.Secret, out *Secret, s conversion.Scope) error {
- return autoConvert_api_Secret_To_v1_Secret(in, out, s)
-}
-
-func autoConvert_v1_SecretKeySelector_To_api_SecretKeySelector(in *SecretKeySelector, out *api.SecretKeySelector, s conversion.Scope) error {
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- out.Key = in.Key
- return nil
-}
-
-func Convert_v1_SecretKeySelector_To_api_SecretKeySelector(in *SecretKeySelector, out *api.SecretKeySelector, s conversion.Scope) error {
- return autoConvert_v1_SecretKeySelector_To_api_SecretKeySelector(in, out, s)
-}
-
-func autoConvert_api_SecretKeySelector_To_v1_SecretKeySelector(in *api.SecretKeySelector, out *SecretKeySelector, s conversion.Scope) error {
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
- return err
- }
- out.Key = in.Key
- return nil
-}
-
-func Convert_api_SecretKeySelector_To_v1_SecretKeySelector(in *api.SecretKeySelector, out *SecretKeySelector, s conversion.Scope) error {
- return autoConvert_api_SecretKeySelector_To_v1_SecretKeySelector(in, out, s)
-}
-
-func autoConvert_v1_SecretList_To_api_SecretList(in *SecretList, out *api.SecretList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Secret, len(*in))
- for i := range *in {
- if err := Convert_v1_Secret_To_api_Secret(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_SecretList_To_api_SecretList(in *SecretList, out *api.SecretList, s conversion.Scope) error {
- return autoConvert_v1_SecretList_To_api_SecretList(in, out, s)
-}
-
-func autoConvert_api_SecretList_To_v1_SecretList(in *api.SecretList, out *SecretList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Secret, len(*in))
- for i := range *in {
- if err := Convert_api_Secret_To_v1_Secret(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_SecretList_To_v1_SecretList(in *api.SecretList, out *SecretList, s conversion.Scope) error {
- return autoConvert_api_SecretList_To_v1_SecretList(in, out, s)
-}
-
-func autoConvert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in *SecretVolumeSource, out *api.SecretVolumeSource, s conversion.Scope) error {
- out.SecretName = in.SecretName
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.KeyToPath, len(*in))
- for i := range *in {
- if err := Convert_v1_KeyToPath_To_api_KeyToPath(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in *SecretVolumeSource, out *api.SecretVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in, out, s)
-}
-
-func autoConvert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in *api.SecretVolumeSource, out *SecretVolumeSource, s conversion.Scope) error {
- out.SecretName = in.SecretName
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]KeyToPath, len(*in))
- for i := range *in {
- if err := Convert_api_KeyToPath_To_v1_KeyToPath(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in *api.SecretVolumeSource, out *SecretVolumeSource, s conversion.Scope) error {
- return autoConvert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_SecurityContext_To_api_SecurityContext(in *SecurityContext, out *api.SecurityContext, s conversion.Scope) error {
- if in.Capabilities != nil {
- in, out := &in.Capabilities, &out.Capabilities
- *out = new(api.Capabilities)
- if err := Convert_v1_Capabilities_To_api_Capabilities(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Capabilities = nil
- }
- out.Privileged = in.Privileged
- if in.SELinuxOptions != nil {
- in, out := &in.SELinuxOptions, &out.SELinuxOptions
- *out = new(api.SELinuxOptions)
- if err := Convert_v1_SELinuxOptions_To_api_SELinuxOptions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem
- return nil
-}
-
-func Convert_v1_SecurityContext_To_api_SecurityContext(in *SecurityContext, out *api.SecurityContext, s conversion.Scope) error {
- return autoConvert_v1_SecurityContext_To_api_SecurityContext(in, out, s)
-}
-
-func autoConvert_api_SecurityContext_To_v1_SecurityContext(in *api.SecurityContext, out *SecurityContext, s conversion.Scope) error {
- if in.Capabilities != nil {
- in, out := &in.Capabilities, &out.Capabilities
- *out = new(Capabilities)
- if err := Convert_api_Capabilities_To_v1_Capabilities(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Capabilities = nil
- }
- out.Privileged = in.Privileged
- if in.SELinuxOptions != nil {
- in, out := &in.SELinuxOptions, &out.SELinuxOptions
- *out = new(SELinuxOptions)
- if err := Convert_api_SELinuxOptions_To_v1_SELinuxOptions(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.SELinuxOptions = nil
- }
- out.RunAsUser = in.RunAsUser
- out.RunAsNonRoot = in.RunAsNonRoot
- out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem
- return nil
-}
-
-func Convert_api_SecurityContext_To_v1_SecurityContext(in *api.SecurityContext, out *SecurityContext, s conversion.Scope) error {
- return autoConvert_api_SecurityContext_To_v1_SecurityContext(in, out, s)
-}
-
-func autoConvert_v1_SerializedReference_To_api_SerializedReference(in *SerializedReference, out *api.SerializedReference, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(&in.Reference, &out.Reference, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_SerializedReference_To_api_SerializedReference(in *SerializedReference, out *api.SerializedReference, s conversion.Scope) error {
- return autoConvert_v1_SerializedReference_To_api_SerializedReference(in, out, s)
-}
-
-func autoConvert_api_SerializedReference_To_v1_SerializedReference(in *api.SerializedReference, out *SerializedReference, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(&in.Reference, &out.Reference, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_SerializedReference_To_v1_SerializedReference(in *api.SerializedReference, out *SerializedReference, s conversion.Scope) error {
- return autoConvert_api_SerializedReference_To_v1_SerializedReference(in, out, s)
-}
-
-func autoConvert_v1_Service_To_api_Service(in *Service, out *api.Service, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ServiceSpec_To_api_ServiceSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_v1_ServiceStatus_To_api_ServiceStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_Service_To_api_Service(in *Service, out *api.Service, s conversion.Scope) error {
- return autoConvert_v1_Service_To_api_Service(in, out, s)
-}
-
-func autoConvert_api_Service_To_v1_Service(in *api.Service, out *Service, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ServiceSpec_To_v1_ServiceSpec(&in.Spec, &out.Spec, s); err != nil {
- return err
- }
- if err := Convert_api_ServiceStatus_To_v1_ServiceStatus(&in.Status, &out.Status, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_Service_To_v1_Service(in *api.Service, out *Service, s conversion.Scope) error {
- return autoConvert_api_Service_To_v1_Service(in, out, s)
-}
-
-func autoConvert_v1_ServiceAccount_To_api_ServiceAccount(in *ServiceAccount, out *api.ServiceAccount, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Secrets != nil {
- in, out := &in.Secrets, &out.Secrets
- *out = make([]api.ObjectReference, len(*in))
- for i := range *in {
- if err := Convert_v1_ObjectReference_To_api_ObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Secrets = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := &in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]api.LocalObjectReference, len(*in))
- for i := range *in {
- if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ImagePullSecrets = nil
- }
- return nil
-}
-
-func Convert_v1_ServiceAccount_To_api_ServiceAccount(in *ServiceAccount, out *api.ServiceAccount, s conversion.Scope) error {
- return autoConvert_v1_ServiceAccount_To_api_ServiceAccount(in, out, s)
-}
-
-func autoConvert_api_ServiceAccount_To_v1_ServiceAccount(in *api.ServiceAccount, out *ServiceAccount, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil {
- return err
- }
- if in.Secrets != nil {
- in, out := &in.Secrets, &out.Secrets
- *out = make([]ObjectReference, len(*in))
- for i := range *in {
- if err := Convert_api_ObjectReference_To_v1_ObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Secrets = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := &in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]LocalObjectReference, len(*in))
- for i := range *in {
- if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.ImagePullSecrets = nil
- }
- return nil
-}
-
-func Convert_api_ServiceAccount_To_v1_ServiceAccount(in *api.ServiceAccount, out *ServiceAccount, s conversion.Scope) error {
- return autoConvert_api_ServiceAccount_To_v1_ServiceAccount(in, out, s)
-}
-
-func autoConvert_v1_ServiceAccountList_To_api_ServiceAccountList(in *ServiceAccountList, out *api.ServiceAccountList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.ServiceAccount, len(*in))
- for i := range *in {
- if err := Convert_v1_ServiceAccount_To_api_ServiceAccount(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ServiceAccountList_To_api_ServiceAccountList(in *ServiceAccountList, out *api.ServiceAccountList, s conversion.Scope) error {
- return autoConvert_v1_ServiceAccountList_To_api_ServiceAccountList(in, out, s)
-}
-
-func autoConvert_api_ServiceAccountList_To_v1_ServiceAccountList(in *api.ServiceAccountList, out *ServiceAccountList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]ServiceAccount, len(*in))
- for i := range *in {
- if err := Convert_api_ServiceAccount_To_v1_ServiceAccount(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ServiceAccountList_To_v1_ServiceAccountList(in *api.ServiceAccountList, out *ServiceAccountList, s conversion.Scope) error {
- return autoConvert_api_ServiceAccountList_To_v1_ServiceAccountList(in, out, s)
-}
-
-func autoConvert_v1_ServiceList_To_api_ServiceList(in *ServiceList, out *api.ServiceList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]api.Service, len(*in))
- for i := range *in {
- if err := Convert_v1_Service_To_api_Service(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_v1_ServiceList_To_api_ServiceList(in *ServiceList, out *api.ServiceList, s conversion.Scope) error {
- return autoConvert_v1_ServiceList_To_api_ServiceList(in, out, s)
-}
-
-func autoConvert_api_ServiceList_To_v1_ServiceList(in *api.ServiceList, out *ServiceList, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- if err := api.Convert_unversioned_ListMeta_To_unversioned_ListMeta(&in.ListMeta, &out.ListMeta, s); err != nil {
- return err
- }
- if in.Items != nil {
- in, out := &in.Items, &out.Items
- *out = make([]Service, len(*in))
- for i := range *in {
- if err := Convert_api_Service_To_v1_Service(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func Convert_api_ServiceList_To_v1_ServiceList(in *api.ServiceList, out *ServiceList, s conversion.Scope) error {
- return autoConvert_api_ServiceList_To_v1_ServiceList(in, out, s)
-}
-
-func autoConvert_v1_ServicePort_To_api_ServicePort(in *ServicePort, out *api.ServicePort, s conversion.Scope) error {
- out.Name = in.Name
- out.Protocol = api.Protocol(in.Protocol)
- out.Port = in.Port
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.TargetPort, &out.TargetPort, s); err != nil {
- return err
- }
- out.NodePort = in.NodePort
- return nil
-}
-
-func Convert_v1_ServicePort_To_api_ServicePort(in *ServicePort, out *api.ServicePort, s conversion.Scope) error {
- return autoConvert_v1_ServicePort_To_api_ServicePort(in, out, s)
-}
-
-func autoConvert_api_ServicePort_To_v1_ServicePort(in *api.ServicePort, out *ServicePort, s conversion.Scope) error {
- out.Name = in.Name
- out.Protocol = Protocol(in.Protocol)
- out.Port = in.Port
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.TargetPort, &out.TargetPort, s); err != nil {
- return err
- }
- out.NodePort = in.NodePort
- return nil
-}
-
-func Convert_api_ServicePort_To_v1_ServicePort(in *api.ServicePort, out *ServicePort, s conversion.Scope) error {
- return autoConvert_api_ServicePort_To_v1_ServicePort(in, out, s)
-}
-
-func autoConvert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in *ServiceProxyOptions, out *api.ServiceProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in *ServiceProxyOptions, out *api.ServiceProxyOptions, s conversion.Scope) error {
- return autoConvert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in, out, s)
-}
-
-func autoConvert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in *api.ServiceProxyOptions, out *ServiceProxyOptions, s conversion.Scope) error {
- if err := api.Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(&in.TypeMeta, &out.TypeMeta, s); err != nil {
- return err
- }
- out.Path = in.Path
- return nil
-}
-
-func Convert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in *api.ServiceProxyOptions, out *ServiceProxyOptions, s conversion.Scope) error {
- return autoConvert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in, out, s)
-}
-
-func autoConvert_v1_ServiceSpec_To_api_ServiceSpec(in *ServiceSpec, out *api.ServiceSpec, s conversion.Scope) error {
- SetDefaults_ServiceSpec(in)
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]api.ServicePort, len(*in))
- for i := range *in {
- if err := Convert_v1_ServicePort_To_api_ServicePort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- out.Selector = in.Selector
- out.ClusterIP = in.ClusterIP
- out.Type = api.ServiceType(in.Type)
- out.ExternalIPs = in.ExternalIPs
- out.SessionAffinity = api.ServiceAffinity(in.SessionAffinity)
- out.LoadBalancerIP = in.LoadBalancerIP
- out.LoadBalancerSourceRanges = in.LoadBalancerSourceRanges
- return nil
-}
-
-func autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *ServiceSpec, s conversion.Scope) error {
- out.Type = ServiceType(in.Type)
- if in.Ports != nil {
- in, out := &in.Ports, &out.Ports
- *out = make([]ServicePort, len(*in))
- for i := range *in {
- if err := Convert_api_ServicePort_To_v1_ServicePort(&(*in)[i], &(*out)[i], s); err != nil {
- return err
- }
- }
- } else {
- out.Ports = nil
- }
- out.Selector = in.Selector
- out.ClusterIP = in.ClusterIP
- out.ExternalIPs = in.ExternalIPs
- out.LoadBalancerIP = in.LoadBalancerIP
- out.SessionAffinity = ServiceAffinity(in.SessionAffinity)
- out.LoadBalancerSourceRanges = in.LoadBalancerSourceRanges
- return nil
-}
-
-func autoConvert_v1_ServiceStatus_To_api_ServiceStatus(in *ServiceStatus, out *api.ServiceStatus, s conversion.Scope) error {
- if err := Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_ServiceStatus_To_api_ServiceStatus(in *ServiceStatus, out *api.ServiceStatus, s conversion.Scope) error {
- return autoConvert_v1_ServiceStatus_To_api_ServiceStatus(in, out, s)
-}
-
-func autoConvert_api_ServiceStatus_To_v1_ServiceStatus(in *api.ServiceStatus, out *ServiceStatus, s conversion.Scope) error {
- if err := Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_ServiceStatus_To_v1_ServiceStatus(in *api.ServiceStatus, out *ServiceStatus, s conversion.Scope) error {
- return autoConvert_api_ServiceStatus_To_v1_ServiceStatus(in, out, s)
-}
-
-func autoConvert_v1_TCPSocketAction_To_api_TCPSocketAction(in *TCPSocketAction, out *api.TCPSocketAction, s conversion.Scope) error {
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.Port, &out.Port, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_TCPSocketAction_To_api_TCPSocketAction(in *TCPSocketAction, out *api.TCPSocketAction, s conversion.Scope) error {
- return autoConvert_v1_TCPSocketAction_To_api_TCPSocketAction(in, out, s)
-}
-
-func autoConvert_api_TCPSocketAction_To_v1_TCPSocketAction(in *api.TCPSocketAction, out *TCPSocketAction, s conversion.Scope) error {
- if err := api.Convert_intstr_IntOrString_To_intstr_IntOrString(&in.Port, &out.Port, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_TCPSocketAction_To_v1_TCPSocketAction(in *api.TCPSocketAction, out *TCPSocketAction, s conversion.Scope) error {
- return autoConvert_api_TCPSocketAction_To_v1_TCPSocketAction(in, out, s)
-}
-
-func autoConvert_v1_Taint_To_api_Taint(in *Taint, out *api.Taint, s conversion.Scope) error {
- out.Key = in.Key
- out.Value = in.Value
- out.Effect = api.TaintEffect(in.Effect)
- return nil
-}
-
-func Convert_v1_Taint_To_api_Taint(in *Taint, out *api.Taint, s conversion.Scope) error {
- return autoConvert_v1_Taint_To_api_Taint(in, out, s)
-}
-
-func autoConvert_api_Taint_To_v1_Taint(in *api.Taint, out *Taint, s conversion.Scope) error {
- out.Key = in.Key
- out.Value = in.Value
- out.Effect = TaintEffect(in.Effect)
- return nil
-}
-
-func Convert_api_Taint_To_v1_Taint(in *api.Taint, out *Taint, s conversion.Scope) error {
- return autoConvert_api_Taint_To_v1_Taint(in, out, s)
-}
-
-func autoConvert_v1_Toleration_To_api_Toleration(in *Toleration, out *api.Toleration, s conversion.Scope) error {
- out.Key = in.Key
- out.Operator = api.TolerationOperator(in.Operator)
- out.Value = in.Value
- out.Effect = api.TaintEffect(in.Effect)
- return nil
-}
-
-func Convert_v1_Toleration_To_api_Toleration(in *Toleration, out *api.Toleration, s conversion.Scope) error {
- return autoConvert_v1_Toleration_To_api_Toleration(in, out, s)
-}
-
-func autoConvert_api_Toleration_To_v1_Toleration(in *api.Toleration, out *Toleration, s conversion.Scope) error {
- out.Key = in.Key
- out.Operator = TolerationOperator(in.Operator)
- out.Value = in.Value
- out.Effect = TaintEffect(in.Effect)
- return nil
-}
-
-func Convert_api_Toleration_To_v1_Toleration(in *api.Toleration, out *Toleration, s conversion.Scope) error {
- return autoConvert_api_Toleration_To_v1_Toleration(in, out, s)
-}
-
-func autoConvert_v1_Volume_To_api_Volume(in *Volume, out *api.Volume, s conversion.Scope) error {
- SetDefaults_Volume(in)
- out.Name = in.Name
- if err := Convert_v1_VolumeSource_To_api_VolumeSource(&in.VolumeSource, &out.VolumeSource, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_Volume_To_api_Volume(in *Volume, out *api.Volume, s conversion.Scope) error {
- return autoConvert_v1_Volume_To_api_Volume(in, out, s)
-}
-
-func autoConvert_api_Volume_To_v1_Volume(in *api.Volume, out *Volume, s conversion.Scope) error {
- out.Name = in.Name
- if err := Convert_api_VolumeSource_To_v1_VolumeSource(&in.VolumeSource, &out.VolumeSource, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_Volume_To_v1_Volume(in *api.Volume, out *Volume, s conversion.Scope) error {
- return autoConvert_api_Volume_To_v1_Volume(in, out, s)
-}
-
-func autoConvert_v1_VolumeMount_To_api_VolumeMount(in *VolumeMount, out *api.VolumeMount, s conversion.Scope) error {
- out.Name = in.Name
- out.ReadOnly = in.ReadOnly
- out.MountPath = in.MountPath
- out.SubPath = in.SubPath
- return nil
-}
-
-func Convert_v1_VolumeMount_To_api_VolumeMount(in *VolumeMount, out *api.VolumeMount, s conversion.Scope) error {
- return autoConvert_v1_VolumeMount_To_api_VolumeMount(in, out, s)
-}
-
-func autoConvert_api_VolumeMount_To_v1_VolumeMount(in *api.VolumeMount, out *VolumeMount, s conversion.Scope) error {
- out.Name = in.Name
- out.ReadOnly = in.ReadOnly
- out.MountPath = in.MountPath
- out.SubPath = in.SubPath
- return nil
-}
-
-func Convert_api_VolumeMount_To_v1_VolumeMount(in *api.VolumeMount, out *VolumeMount, s conversion.Scope) error {
- return autoConvert_api_VolumeMount_To_v1_VolumeMount(in, out, s)
-}
-
-func autoConvert_v1_VolumeSource_To_api_VolumeSource(in *VolumeSource, out *api.VolumeSource, s conversion.Scope) error {
- if in.HostPath != nil {
- in, out := &in.HostPath, &out.HostPath
- *out = new(api.HostPathVolumeSource)
- if err := Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HostPath = nil
- }
- if in.EmptyDir != nil {
- in, out := &in.EmptyDir, &out.EmptyDir
- *out = new(api.EmptyDirVolumeSource)
- if err := Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.EmptyDir = nil
- }
- if in.GCEPersistentDisk != nil {
- in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(api.GCEPersistentDiskVolumeSource)
- if err := Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(api.AWSElasticBlockStoreVolumeSource)
- if err := Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.GitRepo != nil {
- in, out := &in.GitRepo, &out.GitRepo
- *out = new(api.GitRepoVolumeSource)
- if err := Convert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GitRepo = nil
- }
- if in.Secret != nil {
- in, out := &in.Secret, &out.Secret
- *out = new(api.SecretVolumeSource)
- if err := Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Secret = nil
- }
- if in.NFS != nil {
- in, out := &in.NFS, &out.NFS
- *out = new(api.NFSVolumeSource)
- if err := Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NFS = nil
- }
- if in.ISCSI != nil {
- in, out := &in.ISCSI, &out.ISCSI
- *out = new(api.ISCSIVolumeSource)
- if err := Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ISCSI = nil
- }
- if in.Glusterfs != nil {
- in, out := &in.Glusterfs, &out.Glusterfs
- *out = new(api.GlusterfsVolumeSource)
- if err := Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Glusterfs = nil
- }
- if in.PersistentVolumeClaim != nil {
- in, out := &in.PersistentVolumeClaim, &out.PersistentVolumeClaim
- *out = new(api.PersistentVolumeClaimVolumeSource)
- if err := Convert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PersistentVolumeClaim = nil
- }
- if in.RBD != nil {
- in, out := &in.RBD, &out.RBD
- *out = new(api.RBDVolumeSource)
- if err := Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.FlexVolume != nil {
- in, out := &in.FlexVolume, &out.FlexVolume
- *out = new(api.FlexVolumeSource)
- if err := Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.Cinder != nil {
- in, out := &in.Cinder, &out.Cinder
- *out = new(api.CinderVolumeSource)
- if err := Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := &in.CephFS, &out.CephFS
- *out = new(api.CephFSVolumeSource)
- if err := Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.Flocker != nil {
- in, out := &in.Flocker, &out.Flocker
- *out = new(api.FlockerVolumeSource)
- if err := Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Flocker = nil
- }
- if in.DownwardAPI != nil {
- in, out := &in.DownwardAPI, &out.DownwardAPI
- *out = new(api.DownwardAPIVolumeSource)
- if err := Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.DownwardAPI = nil
- }
- if in.FC != nil {
- in, out := &in.FC, &out.FC
- *out = new(api.FCVolumeSource)
- if err := Convert_v1_FCVolumeSource_To_api_FCVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.AzureFile != nil {
- in, out := &in.AzureFile, &out.AzureFile
- *out = new(api.AzureFileVolumeSource)
- if err := Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AzureFile = nil
- }
- if in.ConfigMap != nil {
- in, out := &in.ConfigMap, &out.ConfigMap
- *out = new(api.ConfigMapVolumeSource)
- if err := Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ConfigMap = nil
- }
- if in.VsphereVolume != nil {
- in, out := &in.VsphereVolume, &out.VsphereVolume
- *out = new(api.VsphereVirtualDiskVolumeSource)
- if err := Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func Convert_v1_VolumeSource_To_api_VolumeSource(in *VolumeSource, out *api.VolumeSource, s conversion.Scope) error {
- return autoConvert_v1_VolumeSource_To_api_VolumeSource(in, out, s)
-}
-
-func autoConvert_api_VolumeSource_To_v1_VolumeSource(in *api.VolumeSource, out *VolumeSource, s conversion.Scope) error {
- if in.HostPath != nil {
- in, out := &in.HostPath, &out.HostPath
- *out = new(HostPathVolumeSource)
- if err := Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.HostPath = nil
- }
- if in.EmptyDir != nil {
- in, out := &in.EmptyDir, &out.EmptyDir
- *out = new(EmptyDirVolumeSource)
- if err := Convert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.EmptyDir = nil
- }
- if in.GCEPersistentDisk != nil {
- in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(GCEPersistentDiskVolumeSource)
- if err := Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(AWSElasticBlockStoreVolumeSource)
- if err := Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.GitRepo != nil {
- in, out := &in.GitRepo, &out.GitRepo
- *out = new(GitRepoVolumeSource)
- if err := Convert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.GitRepo = nil
- }
- if in.Secret != nil {
- in, out := &in.Secret, &out.Secret
- *out = new(SecretVolumeSource)
- if err := Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Secret = nil
- }
- if in.NFS != nil {
- in, out := &in.NFS, &out.NFS
- *out = new(NFSVolumeSource)
- if err := Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.NFS = nil
- }
- if in.ISCSI != nil {
- in, out := &in.ISCSI, &out.ISCSI
- *out = new(ISCSIVolumeSource)
- if err := Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ISCSI = nil
- }
- if in.Glusterfs != nil {
- in, out := &in.Glusterfs, &out.Glusterfs
- *out = new(GlusterfsVolumeSource)
- if err := Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Glusterfs = nil
- }
- if in.PersistentVolumeClaim != nil {
- in, out := &in.PersistentVolumeClaim, &out.PersistentVolumeClaim
- *out = new(PersistentVolumeClaimVolumeSource)
- if err := Convert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.PersistentVolumeClaim = nil
- }
- if in.RBD != nil {
- in, out := &in.RBD, &out.RBD
- *out = new(RBDVolumeSource)
- if err := Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.FlexVolume != nil {
- in, out := &in.FlexVolume, &out.FlexVolume
- *out = new(FlexVolumeSource)
- if err := Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.Cinder != nil {
- in, out := &in.Cinder, &out.Cinder
- *out = new(CinderVolumeSource)
- if err := Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := &in.CephFS, &out.CephFS
- *out = new(CephFSVolumeSource)
- if err := Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.Flocker != nil {
- in, out := &in.Flocker, &out.Flocker
- *out = new(FlockerVolumeSource)
- if err := Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.Flocker = nil
- }
- if in.DownwardAPI != nil {
- in, out := &in.DownwardAPI, &out.DownwardAPI
- *out = new(DownwardAPIVolumeSource)
- if err := Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.DownwardAPI = nil
- }
- if in.FC != nil {
- in, out := &in.FC, &out.FC
- *out = new(FCVolumeSource)
- if err := Convert_api_FCVolumeSource_To_v1_FCVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.AzureFile != nil {
- in, out := &in.AzureFile, &out.AzureFile
- *out = new(AzureFileVolumeSource)
- if err := Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.AzureFile = nil
- }
- if in.ConfigMap != nil {
- in, out := &in.ConfigMap, &out.ConfigMap
- *out = new(ConfigMapVolumeSource)
- if err := Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.ConfigMap = nil
- }
- if in.VsphereVolume != nil {
- in, out := &in.VsphereVolume, &out.VsphereVolume
- *out = new(VsphereVirtualDiskVolumeSource)
- if err := Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(*in, *out, s); err != nil {
- return err
- }
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func Convert_api_VolumeSource_To_v1_VolumeSource(in *api.VolumeSource, out *VolumeSource, s conversion.Scope) error {
- return autoConvert_api_VolumeSource_To_v1_VolumeSource(in, out, s)
-}
-
-func autoConvert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in *VsphereVirtualDiskVolumeSource, out *api.VsphereVirtualDiskVolumeSource, s conversion.Scope) error {
- out.VolumePath = in.VolumePath
- out.FSType = in.FSType
- return nil
-}
-
-func Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in *VsphereVirtualDiskVolumeSource, out *api.VsphereVirtualDiskVolumeSource, s conversion.Scope) error {
- return autoConvert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in, out, s)
-}
-
-func autoConvert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in *api.VsphereVirtualDiskVolumeSource, out *VsphereVirtualDiskVolumeSource, s conversion.Scope) error {
- out.VolumePath = in.VolumePath
- out.FSType = in.FSType
- return nil
-}
-
-func Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in *api.VsphereVirtualDiskVolumeSource, out *VsphereVirtualDiskVolumeSource, s conversion.Scope) error {
- return autoConvert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in, out, s)
-}
-
-func autoConvert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in *WeightedPodAffinityTerm, out *api.WeightedPodAffinityTerm, s conversion.Scope) error {
- out.Weight = int(in.Weight)
- if err := Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm(&in.PodAffinityTerm, &out.PodAffinityTerm, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in *WeightedPodAffinityTerm, out *api.WeightedPodAffinityTerm, s conversion.Scope) error {
- return autoConvert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in, out, s)
-}
-
-func autoConvert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in *api.WeightedPodAffinityTerm, out *WeightedPodAffinityTerm, s conversion.Scope) error {
- out.Weight = int32(in.Weight)
- if err := Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm(&in.PodAffinityTerm, &out.PodAffinityTerm, s); err != nil {
- return err
- }
- return nil
-}
-
-func Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in *api.WeightedPodAffinityTerm, out *WeightedPodAffinityTerm, s conversion.Scope) error {
- return autoConvert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in, out, s)
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/deep_copy_generated.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/deep_copy_generated.go
deleted file mode 100644
index 9054da3..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/deep_copy_generated.go
+++ /dev/null
@@ -1,2924 +0,0 @@
-// +build !ignore_autogenerated
-
-/*
-Copyright 2016 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.
-*/
-
-// This file was autogenerated by deepcopy-gen. Do not edit it manually!
-
-package v1
-
-import (
- api "k8s.io/kubernetes/pkg/api"
- unversioned "k8s.io/kubernetes/pkg/api/unversioned"
- conversion "k8s.io/kubernetes/pkg/conversion"
- runtime "k8s.io/kubernetes/pkg/runtime"
- types "k8s.io/kubernetes/pkg/types"
-)
-
-func init() {
- if err := api.Scheme.AddGeneratedDeepCopyFuncs(
- DeepCopy_v1_AWSElasticBlockStoreVolumeSource,
- DeepCopy_v1_Affinity,
- DeepCopy_v1_AttachedVolume,
- DeepCopy_v1_AzureFileVolumeSource,
- DeepCopy_v1_Binding,
- DeepCopy_v1_Capabilities,
- DeepCopy_v1_CephFSVolumeSource,
- DeepCopy_v1_CinderVolumeSource,
- DeepCopy_v1_ComponentCondition,
- DeepCopy_v1_ComponentStatus,
- DeepCopy_v1_ComponentStatusList,
- DeepCopy_v1_ConfigMap,
- DeepCopy_v1_ConfigMapKeySelector,
- DeepCopy_v1_ConfigMapList,
- DeepCopy_v1_ConfigMapVolumeSource,
- DeepCopy_v1_Container,
- DeepCopy_v1_ContainerImage,
- DeepCopy_v1_ContainerPort,
- DeepCopy_v1_ContainerState,
- DeepCopy_v1_ContainerStateRunning,
- DeepCopy_v1_ContainerStateTerminated,
- DeepCopy_v1_ContainerStateWaiting,
- DeepCopy_v1_ContainerStatus,
- DeepCopy_v1_DaemonEndpoint,
- DeepCopy_v1_DeleteOptions,
- DeepCopy_v1_DownwardAPIVolumeFile,
- DeepCopy_v1_DownwardAPIVolumeSource,
- DeepCopy_v1_EmptyDirVolumeSource,
- DeepCopy_v1_EndpointAddress,
- DeepCopy_v1_EndpointPort,
- DeepCopy_v1_EndpointSubset,
- DeepCopy_v1_Endpoints,
- DeepCopy_v1_EndpointsList,
- DeepCopy_v1_EnvVar,
- DeepCopy_v1_EnvVarSource,
- DeepCopy_v1_Event,
- DeepCopy_v1_EventList,
- DeepCopy_v1_EventSource,
- DeepCopy_v1_ExecAction,
- DeepCopy_v1_ExportOptions,
- DeepCopy_v1_FCVolumeSource,
- DeepCopy_v1_FlexVolumeSource,
- DeepCopy_v1_FlockerVolumeSource,
- DeepCopy_v1_GCEPersistentDiskVolumeSource,
- DeepCopy_v1_GitRepoVolumeSource,
- DeepCopy_v1_GlusterfsVolumeSource,
- DeepCopy_v1_HTTPGetAction,
- DeepCopy_v1_HTTPHeader,
- DeepCopy_v1_Handler,
- DeepCopy_v1_HostPathVolumeSource,
- DeepCopy_v1_ISCSIVolumeSource,
- DeepCopy_v1_KeyToPath,
- DeepCopy_v1_Lifecycle,
- DeepCopy_v1_LimitRange,
- DeepCopy_v1_LimitRangeItem,
- DeepCopy_v1_LimitRangeList,
- DeepCopy_v1_LimitRangeSpec,
- DeepCopy_v1_List,
- DeepCopy_v1_ListOptions,
- DeepCopy_v1_LoadBalancerIngress,
- DeepCopy_v1_LoadBalancerStatus,
- DeepCopy_v1_LocalObjectReference,
- DeepCopy_v1_NFSVolumeSource,
- DeepCopy_v1_Namespace,
- DeepCopy_v1_NamespaceList,
- DeepCopy_v1_NamespaceSpec,
- DeepCopy_v1_NamespaceStatus,
- DeepCopy_v1_Node,
- DeepCopy_v1_NodeAddress,
- DeepCopy_v1_NodeAffinity,
- DeepCopy_v1_NodeCondition,
- DeepCopy_v1_NodeDaemonEndpoints,
- DeepCopy_v1_NodeList,
- DeepCopy_v1_NodeProxyOptions,
- DeepCopy_v1_NodeSelector,
- DeepCopy_v1_NodeSelectorRequirement,
- DeepCopy_v1_NodeSelectorTerm,
- DeepCopy_v1_NodeSpec,
- DeepCopy_v1_NodeStatus,
- DeepCopy_v1_NodeSystemInfo,
- DeepCopy_v1_ObjectFieldSelector,
- DeepCopy_v1_ObjectMeta,
- DeepCopy_v1_ObjectReference,
- DeepCopy_v1_OwnerReference,
- DeepCopy_v1_PersistentVolume,
- DeepCopy_v1_PersistentVolumeClaim,
- DeepCopy_v1_PersistentVolumeClaimList,
- DeepCopy_v1_PersistentVolumeClaimSpec,
- DeepCopy_v1_PersistentVolumeClaimStatus,
- DeepCopy_v1_PersistentVolumeClaimVolumeSource,
- DeepCopy_v1_PersistentVolumeList,
- DeepCopy_v1_PersistentVolumeSource,
- DeepCopy_v1_PersistentVolumeSpec,
- DeepCopy_v1_PersistentVolumeStatus,
- DeepCopy_v1_Pod,
- DeepCopy_v1_PodAffinity,
- DeepCopy_v1_PodAffinityTerm,
- DeepCopy_v1_PodAntiAffinity,
- DeepCopy_v1_PodAttachOptions,
- DeepCopy_v1_PodCondition,
- DeepCopy_v1_PodExecOptions,
- DeepCopy_v1_PodList,
- DeepCopy_v1_PodLogOptions,
- DeepCopy_v1_PodProxyOptions,
- DeepCopy_v1_PodSecurityContext,
- DeepCopy_v1_PodSpec,
- DeepCopy_v1_PodStatus,
- DeepCopy_v1_PodStatusResult,
- DeepCopy_v1_PodTemplate,
- DeepCopy_v1_PodTemplateList,
- DeepCopy_v1_PodTemplateSpec,
- DeepCopy_v1_Preconditions,
- DeepCopy_v1_PreferredSchedulingTerm,
- DeepCopy_v1_Probe,
- DeepCopy_v1_RBDVolumeSource,
- DeepCopy_v1_RangeAllocation,
- DeepCopy_v1_ReplicationController,
- DeepCopy_v1_ReplicationControllerList,
- DeepCopy_v1_ReplicationControllerSpec,
- DeepCopy_v1_ReplicationControllerStatus,
- DeepCopy_v1_ResourceFieldSelector,
- DeepCopy_v1_ResourceQuota,
- DeepCopy_v1_ResourceQuotaList,
- DeepCopy_v1_ResourceQuotaSpec,
- DeepCopy_v1_ResourceQuotaStatus,
- DeepCopy_v1_ResourceRequirements,
- DeepCopy_v1_SELinuxOptions,
- DeepCopy_v1_Secret,
- DeepCopy_v1_SecretKeySelector,
- DeepCopy_v1_SecretList,
- DeepCopy_v1_SecretVolumeSource,
- DeepCopy_v1_SecurityContext,
- DeepCopy_v1_SerializedReference,
- DeepCopy_v1_Service,
- DeepCopy_v1_ServiceAccount,
- DeepCopy_v1_ServiceAccountList,
- DeepCopy_v1_ServiceList,
- DeepCopy_v1_ServicePort,
- DeepCopy_v1_ServiceProxyOptions,
- DeepCopy_v1_ServiceSpec,
- DeepCopy_v1_ServiceStatus,
- DeepCopy_v1_TCPSocketAction,
- DeepCopy_v1_Taint,
- DeepCopy_v1_Toleration,
- DeepCopy_v1_Volume,
- DeepCopy_v1_VolumeMount,
- DeepCopy_v1_VolumeSource,
- DeepCopy_v1_VsphereVirtualDiskVolumeSource,
- DeepCopy_v1_WeightedPodAffinityTerm,
- ); err != nil {
- // if one of the deep copy functions is malformed, detect it immediately.
- panic(err)
- }
-}
-
-func DeepCopy_v1_AWSElasticBlockStoreVolumeSource(in AWSElasticBlockStoreVolumeSource, out *AWSElasticBlockStoreVolumeSource, c *conversion.Cloner) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_Affinity(in Affinity, out *Affinity, c *conversion.Cloner) error {
- if in.NodeAffinity != nil {
- in, out := in.NodeAffinity, &out.NodeAffinity
- *out = new(NodeAffinity)
- if err := DeepCopy_v1_NodeAffinity(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.NodeAffinity = nil
- }
- if in.PodAffinity != nil {
- in, out := in.PodAffinity, &out.PodAffinity
- *out = new(PodAffinity)
- if err := DeepCopy_v1_PodAffinity(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.PodAffinity = nil
- }
- if in.PodAntiAffinity != nil {
- in, out := in.PodAntiAffinity, &out.PodAntiAffinity
- *out = new(PodAntiAffinity)
- if err := DeepCopy_v1_PodAntiAffinity(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.PodAntiAffinity = nil
- }
- return nil
-}
-
-func DeepCopy_v1_AttachedVolume(in AttachedVolume, out *AttachedVolume, c *conversion.Cloner) error {
- out.Name = in.Name
- out.DevicePath = in.DevicePath
- return nil
-}
-
-func DeepCopy_v1_AzureFileVolumeSource(in AzureFileVolumeSource, out *AzureFileVolumeSource, c *conversion.Cloner) error {
- out.SecretName = in.SecretName
- out.ShareName = in.ShareName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_Binding(in Binding, out *Binding, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- out.Target = in.Target
- return nil
-}
-
-func DeepCopy_v1_Capabilities(in Capabilities, out *Capabilities, c *conversion.Cloner) error {
- if in.Add != nil {
- in, out := in.Add, &out.Add
- *out = make([]Capability, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Add = nil
- }
- if in.Drop != nil {
- in, out := in.Drop, &out.Drop
- *out = make([]Capability, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Drop = nil
- }
- return nil
-}
-
-func DeepCopy_v1_CephFSVolumeSource(in CephFSVolumeSource, out *CephFSVolumeSource, c *conversion.Cloner) error {
- if in.Monitors != nil {
- in, out := in.Monitors, &out.Monitors
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Monitors = nil
- }
- out.Path = in.Path
- out.User = in.User
- out.SecretFile = in.SecretFile
- if in.SecretRef != nil {
- in, out := in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- **out = *in
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_CinderVolumeSource(in CinderVolumeSource, out *CinderVolumeSource, c *conversion.Cloner) error {
- out.VolumeID = in.VolumeID
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_ComponentCondition(in ComponentCondition, out *ComponentCondition, c *conversion.Cloner) error {
- out.Type = in.Type
- out.Status = in.Status
- out.Message = in.Message
- out.Error = in.Error
- return nil
-}
-
-func DeepCopy_v1_ComponentStatus(in ComponentStatus, out *ComponentStatus, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if in.Conditions != nil {
- in, out := in.Conditions, &out.Conditions
- *out = make([]ComponentCondition, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Conditions = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ComponentStatusList(in ComponentStatusList, out *ComponentStatusList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]ComponentStatus, len(in))
- for i := range in {
- if err := DeepCopy_v1_ComponentStatus(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ConfigMap(in ConfigMap, out *ConfigMap, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if in.Data != nil {
- in, out := in.Data, &out.Data
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Data = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ConfigMapKeySelector(in ConfigMapKeySelector, out *ConfigMapKeySelector, c *conversion.Cloner) error {
- out.LocalObjectReference = in.LocalObjectReference
- out.Key = in.Key
- return nil
-}
-
-func DeepCopy_v1_ConfigMapList(in ConfigMapList, out *ConfigMapList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]ConfigMap, len(in))
- for i := range in {
- if err := DeepCopy_v1_ConfigMap(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ConfigMapVolumeSource(in ConfigMapVolumeSource, out *ConfigMapVolumeSource, c *conversion.Cloner) error {
- out.LocalObjectReference = in.LocalObjectReference
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]KeyToPath, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_Container(in Container, out *Container, c *conversion.Cloner) error {
- out.Name = in.Name
- out.Image = in.Image
- if in.Command != nil {
- in, out := in.Command, &out.Command
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Command = nil
- }
- if in.Args != nil {
- in, out := in.Args, &out.Args
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Args = nil
- }
- out.WorkingDir = in.WorkingDir
- if in.Ports != nil {
- in, out := in.Ports, &out.Ports
- *out = make([]ContainerPort, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Ports = nil
- }
- if in.Env != nil {
- in, out := in.Env, &out.Env
- *out = make([]EnvVar, len(in))
- for i := range in {
- if err := DeepCopy_v1_EnvVar(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Env = nil
- }
- if err := DeepCopy_v1_ResourceRequirements(in.Resources, &out.Resources, c); err != nil {
- return err
- }
- if in.VolumeMounts != nil {
- in, out := in.VolumeMounts, &out.VolumeMounts
- *out = make([]VolumeMount, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.VolumeMounts = nil
- }
- if in.LivenessProbe != nil {
- in, out := in.LivenessProbe, &out.LivenessProbe
- *out = new(Probe)
- if err := DeepCopy_v1_Probe(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.LivenessProbe = nil
- }
- if in.ReadinessProbe != nil {
- in, out := in.ReadinessProbe, &out.ReadinessProbe
- *out = new(Probe)
- if err := DeepCopy_v1_Probe(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.ReadinessProbe = nil
- }
- if in.Lifecycle != nil {
- in, out := in.Lifecycle, &out.Lifecycle
- *out = new(Lifecycle)
- if err := DeepCopy_v1_Lifecycle(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Lifecycle = nil
- }
- out.TerminationMessagePath = in.TerminationMessagePath
- out.ImagePullPolicy = in.ImagePullPolicy
- if in.SecurityContext != nil {
- in, out := in.SecurityContext, &out.SecurityContext
- *out = new(SecurityContext)
- if err := DeepCopy_v1_SecurityContext(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- out.Stdin = in.Stdin
- out.StdinOnce = in.StdinOnce
- out.TTY = in.TTY
- return nil
-}
-
-func DeepCopy_v1_ContainerImage(in ContainerImage, out *ContainerImage, c *conversion.Cloner) error {
- if in.Names != nil {
- in, out := in.Names, &out.Names
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Names = nil
- }
- out.SizeBytes = in.SizeBytes
- return nil
-}
-
-func DeepCopy_v1_ContainerPort(in ContainerPort, out *ContainerPort, c *conversion.Cloner) error {
- out.Name = in.Name
- out.HostPort = in.HostPort
- out.ContainerPort = in.ContainerPort
- out.Protocol = in.Protocol
- out.HostIP = in.HostIP
- return nil
-}
-
-func DeepCopy_v1_ContainerState(in ContainerState, out *ContainerState, c *conversion.Cloner) error {
- if in.Waiting != nil {
- in, out := in.Waiting, &out.Waiting
- *out = new(ContainerStateWaiting)
- **out = *in
- } else {
- out.Waiting = nil
- }
- if in.Running != nil {
- in, out := in.Running, &out.Running
- *out = new(ContainerStateRunning)
- if err := DeepCopy_v1_ContainerStateRunning(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Running = nil
- }
- if in.Terminated != nil {
- in, out := in.Terminated, &out.Terminated
- *out = new(ContainerStateTerminated)
- if err := DeepCopy_v1_ContainerStateTerminated(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Terminated = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ContainerStateRunning(in ContainerStateRunning, out *ContainerStateRunning, c *conversion.Cloner) error {
- out.StartedAt = in.StartedAt.DeepCopy()
- return nil
-}
-
-func DeepCopy_v1_ContainerStateTerminated(in ContainerStateTerminated, out *ContainerStateTerminated, c *conversion.Cloner) error {
- out.ExitCode = in.ExitCode
- out.Signal = in.Signal
- out.Reason = in.Reason
- out.Message = in.Message
- out.StartedAt = in.StartedAt.DeepCopy()
- out.FinishedAt = in.FinishedAt.DeepCopy()
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func DeepCopy_v1_ContainerStateWaiting(in ContainerStateWaiting, out *ContainerStateWaiting, c *conversion.Cloner) error {
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func DeepCopy_v1_ContainerStatus(in ContainerStatus, out *ContainerStatus, c *conversion.Cloner) error {
- out.Name = in.Name
- if err := DeepCopy_v1_ContainerState(in.State, &out.State, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ContainerState(in.LastTerminationState, &out.LastTerminationState, c); err != nil {
- return err
- }
- out.Ready = in.Ready
- out.RestartCount = in.RestartCount
- out.Image = in.Image
- out.ImageID = in.ImageID
- out.ContainerID = in.ContainerID
- return nil
-}
-
-func DeepCopy_v1_DaemonEndpoint(in DaemonEndpoint, out *DaemonEndpoint, c *conversion.Cloner) error {
- out.Port = in.Port
- return nil
-}
-
-func DeepCopy_v1_DeleteOptions(in DeleteOptions, out *DeleteOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if in.GracePeriodSeconds != nil {
- in, out := in.GracePeriodSeconds, &out.GracePeriodSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.GracePeriodSeconds = nil
- }
- if in.Preconditions != nil {
- in, out := in.Preconditions, &out.Preconditions
- *out = new(Preconditions)
- if err := DeepCopy_v1_Preconditions(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Preconditions = nil
- }
- if in.OrphanDependents != nil {
- in, out := in.OrphanDependents, &out.OrphanDependents
- *out = new(bool)
- **out = *in
- } else {
- out.OrphanDependents = nil
- }
- return nil
-}
-
-func DeepCopy_v1_DownwardAPIVolumeFile(in DownwardAPIVolumeFile, out *DownwardAPIVolumeFile, c *conversion.Cloner) error {
- out.Path = in.Path
- if in.FieldRef != nil {
- in, out := in.FieldRef, &out.FieldRef
- *out = new(ObjectFieldSelector)
- **out = *in
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(ResourceFieldSelector)
- if err := DeepCopy_v1_ResourceFieldSelector(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- return nil
-}
-
-func DeepCopy_v1_DownwardAPIVolumeSource(in DownwardAPIVolumeSource, out *DownwardAPIVolumeSource, c *conversion.Cloner) error {
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]DownwardAPIVolumeFile, len(in))
- for i := range in {
- if err := DeepCopy_v1_DownwardAPIVolumeFile(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EmptyDirVolumeSource(in EmptyDirVolumeSource, out *EmptyDirVolumeSource, c *conversion.Cloner) error {
- out.Medium = in.Medium
- return nil
-}
-
-func DeepCopy_v1_EndpointAddress(in EndpointAddress, out *EndpointAddress, c *conversion.Cloner) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- if in.TargetRef != nil {
- in, out := in.TargetRef, &out.TargetRef
- *out = new(ObjectReference)
- **out = *in
- } else {
- out.TargetRef = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EndpointPort(in EndpointPort, out *EndpointPort, c *conversion.Cloner) error {
- out.Name = in.Name
- out.Port = in.Port
- out.Protocol = in.Protocol
- return nil
-}
-
-func DeepCopy_v1_EndpointSubset(in EndpointSubset, out *EndpointSubset, c *conversion.Cloner) error {
- if in.Addresses != nil {
- in, out := in.Addresses, &out.Addresses
- *out = make([]EndpointAddress, len(in))
- for i := range in {
- if err := DeepCopy_v1_EndpointAddress(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Addresses = nil
- }
- if in.NotReadyAddresses != nil {
- in, out := in.NotReadyAddresses, &out.NotReadyAddresses
- *out = make([]EndpointAddress, len(in))
- for i := range in {
- if err := DeepCopy_v1_EndpointAddress(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.NotReadyAddresses = nil
- }
- if in.Ports != nil {
- in, out := in.Ports, &out.Ports
- *out = make([]EndpointPort, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Ports = nil
- }
- return nil
-}
-
-func DeepCopy_v1_Endpoints(in Endpoints, out *Endpoints, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if in.Subsets != nil {
- in, out := in.Subsets, &out.Subsets
- *out = make([]EndpointSubset, len(in))
- for i := range in {
- if err := DeepCopy_v1_EndpointSubset(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Subsets = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EndpointsList(in EndpointsList, out *EndpointsList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Endpoints, len(in))
- for i := range in {
- if err := DeepCopy_v1_Endpoints(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EnvVar(in EnvVar, out *EnvVar, c *conversion.Cloner) error {
- out.Name = in.Name
- out.Value = in.Value
- if in.ValueFrom != nil {
- in, out := in.ValueFrom, &out.ValueFrom
- *out = new(EnvVarSource)
- if err := DeepCopy_v1_EnvVarSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.ValueFrom = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EnvVarSource(in EnvVarSource, out *EnvVarSource, c *conversion.Cloner) error {
- if in.FieldRef != nil {
- in, out := in.FieldRef, &out.FieldRef
- *out = new(ObjectFieldSelector)
- **out = *in
- } else {
- out.FieldRef = nil
- }
- if in.ResourceFieldRef != nil {
- in, out := in.ResourceFieldRef, &out.ResourceFieldRef
- *out = new(ResourceFieldSelector)
- if err := DeepCopy_v1_ResourceFieldSelector(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.ResourceFieldRef = nil
- }
- if in.ConfigMapKeyRef != nil {
- in, out := in.ConfigMapKeyRef, &out.ConfigMapKeyRef
- *out = new(ConfigMapKeySelector)
- **out = *in
- } else {
- out.ConfigMapKeyRef = nil
- }
- if in.SecretKeyRef != nil {
- in, out := in.SecretKeyRef, &out.SecretKeyRef
- *out = new(SecretKeySelector)
- **out = *in
- } else {
- out.SecretKeyRef = nil
- }
- return nil
-}
-
-func DeepCopy_v1_Event(in Event, out *Event, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- out.InvolvedObject = in.InvolvedObject
- out.Reason = in.Reason
- out.Message = in.Message
- out.Source = in.Source
- out.FirstTimestamp = in.FirstTimestamp.DeepCopy()
- out.LastTimestamp = in.LastTimestamp.DeepCopy()
- out.Count = in.Count
- out.Type = in.Type
- return nil
-}
-
-func DeepCopy_v1_EventList(in EventList, out *EventList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Event, len(in))
- for i := range in {
- if err := DeepCopy_v1_Event(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_EventSource(in EventSource, out *EventSource, c *conversion.Cloner) error {
- out.Component = in.Component
- out.Host = in.Host
- return nil
-}
-
-func DeepCopy_v1_ExecAction(in ExecAction, out *ExecAction, c *conversion.Cloner) error {
- if in.Command != nil {
- in, out := in.Command, &out.Command
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Command = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ExportOptions(in ExportOptions, out *ExportOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Export = in.Export
- out.Exact = in.Exact
- return nil
-}
-
-func DeepCopy_v1_FCVolumeSource(in FCVolumeSource, out *FCVolumeSource, c *conversion.Cloner) error {
- if in.TargetWWNs != nil {
- in, out := in.TargetWWNs, &out.TargetWWNs
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.TargetWWNs = nil
- }
- if in.Lun != nil {
- in, out := in.Lun, &out.Lun
- *out = new(int32)
- **out = *in
- } else {
- out.Lun = nil
- }
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_FlexVolumeSource(in FlexVolumeSource, out *FlexVolumeSource, c *conversion.Cloner) error {
- out.Driver = in.Driver
- out.FSType = in.FSType
- if in.SecretRef != nil {
- in, out := in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- **out = *in
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- if in.Options != nil {
- in, out := in.Options, &out.Options
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Options = nil
- }
- return nil
-}
-
-func DeepCopy_v1_FlockerVolumeSource(in FlockerVolumeSource, out *FlockerVolumeSource, c *conversion.Cloner) error {
- out.DatasetName = in.DatasetName
- return nil
-}
-
-func DeepCopy_v1_GCEPersistentDiskVolumeSource(in GCEPersistentDiskVolumeSource, out *GCEPersistentDiskVolumeSource, c *conversion.Cloner) error {
- out.PDName = in.PDName
- out.FSType = in.FSType
- out.Partition = in.Partition
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_GitRepoVolumeSource(in GitRepoVolumeSource, out *GitRepoVolumeSource, c *conversion.Cloner) error {
- out.Repository = in.Repository
- out.Revision = in.Revision
- out.Directory = in.Directory
- return nil
-}
-
-func DeepCopy_v1_GlusterfsVolumeSource(in GlusterfsVolumeSource, out *GlusterfsVolumeSource, c *conversion.Cloner) error {
- out.EndpointsName = in.EndpointsName
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_HTTPGetAction(in HTTPGetAction, out *HTTPGetAction, c *conversion.Cloner) error {
- out.Path = in.Path
- out.Port = in.Port
- out.Host = in.Host
- out.Scheme = in.Scheme
- if in.HTTPHeaders != nil {
- in, out := in.HTTPHeaders, &out.HTTPHeaders
- *out = make([]HTTPHeader, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.HTTPHeaders = nil
- }
- return nil
-}
-
-func DeepCopy_v1_HTTPHeader(in HTTPHeader, out *HTTPHeader, c *conversion.Cloner) error {
- out.Name = in.Name
- out.Value = in.Value
- return nil
-}
-
-func DeepCopy_v1_Handler(in Handler, out *Handler, c *conversion.Cloner) error {
- if in.Exec != nil {
- in, out := in.Exec, &out.Exec
- *out = new(ExecAction)
- if err := DeepCopy_v1_ExecAction(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Exec = nil
- }
- if in.HTTPGet != nil {
- in, out := in.HTTPGet, &out.HTTPGet
- *out = new(HTTPGetAction)
- if err := DeepCopy_v1_HTTPGetAction(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.HTTPGet = nil
- }
- if in.TCPSocket != nil {
- in, out := in.TCPSocket, &out.TCPSocket
- *out = new(TCPSocketAction)
- **out = *in
- } else {
- out.TCPSocket = nil
- }
- return nil
-}
-
-func DeepCopy_v1_HostPathVolumeSource(in HostPathVolumeSource, out *HostPathVolumeSource, c *conversion.Cloner) error {
- out.Path = in.Path
- return nil
-}
-
-func DeepCopy_v1_ISCSIVolumeSource(in ISCSIVolumeSource, out *ISCSIVolumeSource, c *conversion.Cloner) error {
- out.TargetPortal = in.TargetPortal
- out.IQN = in.IQN
- out.Lun = in.Lun
- out.ISCSIInterface = in.ISCSIInterface
- out.FSType = in.FSType
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_KeyToPath(in KeyToPath, out *KeyToPath, c *conversion.Cloner) error {
- out.Key = in.Key
- out.Path = in.Path
- return nil
-}
-
-func DeepCopy_v1_Lifecycle(in Lifecycle, out *Lifecycle, c *conversion.Cloner) error {
- if in.PostStart != nil {
- in, out := in.PostStart, &out.PostStart
- *out = new(Handler)
- if err := DeepCopy_v1_Handler(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.PostStart = nil
- }
- if in.PreStop != nil {
- in, out := in.PreStop, &out.PreStop
- *out = new(Handler)
- if err := DeepCopy_v1_Handler(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.PreStop = nil
- }
- return nil
-}
-
-func DeepCopy_v1_LimitRange(in LimitRange, out *LimitRange, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_LimitRangeSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_LimitRangeItem(in LimitRangeItem, out *LimitRangeItem, c *conversion.Cloner) error {
- out.Type = in.Type
- if in.Max != nil {
- in, out := in.Max, &out.Max
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Max = nil
- }
- if in.Min != nil {
- in, out := in.Min, &out.Min
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Min = nil
- }
- if in.Default != nil {
- in, out := in.Default, &out.Default
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Default = nil
- }
- if in.DefaultRequest != nil {
- in, out := in.DefaultRequest, &out.DefaultRequest
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.DefaultRequest = nil
- }
- if in.MaxLimitRequestRatio != nil {
- in, out := in.MaxLimitRequestRatio, &out.MaxLimitRequestRatio
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.MaxLimitRequestRatio = nil
- }
- return nil
-}
-
-func DeepCopy_v1_LimitRangeList(in LimitRangeList, out *LimitRangeList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]LimitRange, len(in))
- for i := range in {
- if err := DeepCopy_v1_LimitRange(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_LimitRangeSpec(in LimitRangeSpec, out *LimitRangeSpec, c *conversion.Cloner) error {
- if in.Limits != nil {
- in, out := in.Limits, &out.Limits
- *out = make([]LimitRangeItem, len(in))
- for i := range in {
- if err := DeepCopy_v1_LimitRangeItem(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Limits = nil
- }
- return nil
-}
-
-func DeepCopy_v1_List(in List, out *List, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]runtime.RawExtension, len(in))
- for i := range in {
- if err := runtime.DeepCopy_runtime_RawExtension(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ListOptions(in ListOptions, out *ListOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.LabelSelector = in.LabelSelector
- out.FieldSelector = in.FieldSelector
- out.Watch = in.Watch
- out.ResourceVersion = in.ResourceVersion
- if in.TimeoutSeconds != nil {
- in, out := in.TimeoutSeconds, &out.TimeoutSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.TimeoutSeconds = nil
- }
- return nil
-}
-
-func DeepCopy_v1_LoadBalancerIngress(in LoadBalancerIngress, out *LoadBalancerIngress, c *conversion.Cloner) error {
- out.IP = in.IP
- out.Hostname = in.Hostname
- return nil
-}
-
-func DeepCopy_v1_LoadBalancerStatus(in LoadBalancerStatus, out *LoadBalancerStatus, c *conversion.Cloner) error {
- if in.Ingress != nil {
- in, out := in.Ingress, &out.Ingress
- *out = make([]LoadBalancerIngress, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Ingress = nil
- }
- return nil
-}
-
-func DeepCopy_v1_LocalObjectReference(in LocalObjectReference, out *LocalObjectReference, c *conversion.Cloner) error {
- out.Name = in.Name
- return nil
-}
-
-func DeepCopy_v1_NFSVolumeSource(in NFSVolumeSource, out *NFSVolumeSource, c *conversion.Cloner) error {
- out.Server = in.Server
- out.Path = in.Path
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_Namespace(in Namespace, out *Namespace, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_NamespaceSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- out.Status = in.Status
- return nil
-}
-
-func DeepCopy_v1_NamespaceList(in NamespaceList, out *NamespaceList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Namespace, len(in))
- for i := range in {
- if err := DeepCopy_v1_Namespace(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NamespaceSpec(in NamespaceSpec, out *NamespaceSpec, c *conversion.Cloner) error {
- if in.Finalizers != nil {
- in, out := in.Finalizers, &out.Finalizers
- *out = make([]FinalizerName, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Finalizers = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NamespaceStatus(in NamespaceStatus, out *NamespaceStatus, c *conversion.Cloner) error {
- out.Phase = in.Phase
- return nil
-}
-
-func DeepCopy_v1_Node(in Node, out *Node, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- out.Spec = in.Spec
- if err := DeepCopy_v1_NodeStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_NodeAddress(in NodeAddress, out *NodeAddress, c *conversion.Cloner) error {
- out.Type = in.Type
- out.Address = in.Address
- return nil
-}
-
-func DeepCopy_v1_NodeAffinity(in NodeAffinity, out *NodeAffinity, c *conversion.Cloner) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = new(NodeSelector)
- if err := DeepCopy_v1_NodeSelector(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]PreferredSchedulingTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_PreferredSchedulingTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeCondition(in NodeCondition, out *NodeCondition, c *conversion.Cloner) error {
- out.Type = in.Type
- out.Status = in.Status
- out.LastHeartbeatTime = in.LastHeartbeatTime.DeepCopy()
- out.LastTransitionTime = in.LastTransitionTime.DeepCopy()
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func DeepCopy_v1_NodeDaemonEndpoints(in NodeDaemonEndpoints, out *NodeDaemonEndpoints, c *conversion.Cloner) error {
- out.KubeletEndpoint = in.KubeletEndpoint
- return nil
-}
-
-func DeepCopy_v1_NodeList(in NodeList, out *NodeList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Node, len(in))
- for i := range in {
- if err := DeepCopy_v1_Node(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeProxyOptions(in NodeProxyOptions, out *NodeProxyOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Path = in.Path
- return nil
-}
-
-func DeepCopy_v1_NodeSelector(in NodeSelector, out *NodeSelector, c *conversion.Cloner) error {
- if in.NodeSelectorTerms != nil {
- in, out := in.NodeSelectorTerms, &out.NodeSelectorTerms
- *out = make([]NodeSelectorTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_NodeSelectorTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.NodeSelectorTerms = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeSelectorRequirement(in NodeSelectorRequirement, out *NodeSelectorRequirement, c *conversion.Cloner) error {
- out.Key = in.Key
- out.Operator = in.Operator
- if in.Values != nil {
- in, out := in.Values, &out.Values
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Values = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeSelectorTerm(in NodeSelectorTerm, out *NodeSelectorTerm, c *conversion.Cloner) error {
- if in.MatchExpressions != nil {
- in, out := in.MatchExpressions, &out.MatchExpressions
- *out = make([]NodeSelectorRequirement, len(in))
- for i := range in {
- if err := DeepCopy_v1_NodeSelectorRequirement(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.MatchExpressions = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeSpec(in NodeSpec, out *NodeSpec, c *conversion.Cloner) error {
- out.PodCIDR = in.PodCIDR
- out.ExternalID = in.ExternalID
- out.ProviderID = in.ProviderID
- out.Unschedulable = in.Unschedulable
- return nil
-}
-
-func DeepCopy_v1_NodeStatus(in NodeStatus, out *NodeStatus, c *conversion.Cloner) error {
- if in.Capacity != nil {
- in, out := in.Capacity, &out.Capacity
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Capacity = nil
- }
- if in.Allocatable != nil {
- in, out := in.Allocatable, &out.Allocatable
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Allocatable = nil
- }
- out.Phase = in.Phase
- if in.Conditions != nil {
- in, out := in.Conditions, &out.Conditions
- *out = make([]NodeCondition, len(in))
- for i := range in {
- if err := DeepCopy_v1_NodeCondition(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- if in.Addresses != nil {
- in, out := in.Addresses, &out.Addresses
- *out = make([]NodeAddress, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Addresses = nil
- }
- out.DaemonEndpoints = in.DaemonEndpoints
- out.NodeInfo = in.NodeInfo
- if in.Images != nil {
- in, out := in.Images, &out.Images
- *out = make([]ContainerImage, len(in))
- for i := range in {
- if err := DeepCopy_v1_ContainerImage(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Images = nil
- }
- if in.VolumesInUse != nil {
- in, out := in.VolumesInUse, &out.VolumesInUse
- *out = make([]UniqueVolumeName, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.VolumesInUse = nil
- }
- if in.VolumesAttached != nil {
- in, out := in.VolumesAttached, &out.VolumesAttached
- *out = make([]AttachedVolume, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.VolumesAttached = nil
- }
- return nil
-}
-
-func DeepCopy_v1_NodeSystemInfo(in NodeSystemInfo, out *NodeSystemInfo, c *conversion.Cloner) error {
- out.MachineID = in.MachineID
- out.SystemUUID = in.SystemUUID
- out.BootID = in.BootID
- out.KernelVersion = in.KernelVersion
- out.OSImage = in.OSImage
- out.ContainerRuntimeVersion = in.ContainerRuntimeVersion
- out.KubeletVersion = in.KubeletVersion
- out.KubeProxyVersion = in.KubeProxyVersion
- out.OperatingSystem = in.OperatingSystem
- out.Architecture = in.Architecture
- return nil
-}
-
-func DeepCopy_v1_ObjectFieldSelector(in ObjectFieldSelector, out *ObjectFieldSelector, c *conversion.Cloner) error {
- out.APIVersion = in.APIVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func DeepCopy_v1_ObjectMeta(in ObjectMeta, out *ObjectMeta, c *conversion.Cloner) error {
- out.Name = in.Name
- out.GenerateName = in.GenerateName
- out.Namespace = in.Namespace
- out.SelfLink = in.SelfLink
- out.UID = in.UID
- out.ResourceVersion = in.ResourceVersion
- out.Generation = in.Generation
- out.CreationTimestamp = in.CreationTimestamp.DeepCopy()
- if in.DeletionTimestamp != nil {
- in, out := in.DeletionTimestamp, &out.DeletionTimestamp
- *out = new(unversioned.Time)
- **out = in.DeepCopy()
- } else {
- out.DeletionTimestamp = nil
- }
- if in.DeletionGracePeriodSeconds != nil {
- in, out := in.DeletionGracePeriodSeconds, &out.DeletionGracePeriodSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.DeletionGracePeriodSeconds = nil
- }
- if in.Labels != nil {
- in, out := in.Labels, &out.Labels
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Labels = nil
- }
- if in.Annotations != nil {
- in, out := in.Annotations, &out.Annotations
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Annotations = nil
- }
- if in.OwnerReferences != nil {
- in, out := in.OwnerReferences, &out.OwnerReferences
- *out = make([]OwnerReference, len(in))
- for i := range in {
- if err := DeepCopy_v1_OwnerReference(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.OwnerReferences = nil
- }
- if in.Finalizers != nil {
- in, out := in.Finalizers, &out.Finalizers
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Finalizers = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ObjectReference(in ObjectReference, out *ObjectReference, c *conversion.Cloner) error {
- out.Kind = in.Kind
- out.Namespace = in.Namespace
- out.Name = in.Name
- out.UID = in.UID
- out.APIVersion = in.APIVersion
- out.ResourceVersion = in.ResourceVersion
- out.FieldPath = in.FieldPath
- return nil
-}
-
-func DeepCopy_v1_OwnerReference(in OwnerReference, out *OwnerReference, c *conversion.Cloner) error {
- out.APIVersion = in.APIVersion
- out.Kind = in.Kind
- out.Name = in.Name
- out.UID = in.UID
- if in.Controller != nil {
- in, out := in.Controller, &out.Controller
- *out = new(bool)
- **out = *in
- } else {
- out.Controller = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolume(in PersistentVolume, out *PersistentVolume, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PersistentVolumeSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- out.Status = in.Status
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeClaim(in PersistentVolumeClaim, out *PersistentVolumeClaim, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PersistentVolumeClaimSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PersistentVolumeClaimStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeClaimList(in PersistentVolumeClaimList, out *PersistentVolumeClaimList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]PersistentVolumeClaim, len(in))
- for i := range in {
- if err := DeepCopy_v1_PersistentVolumeClaim(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeClaimSpec(in PersistentVolumeClaimSpec, out *PersistentVolumeClaimSpec, c *conversion.Cloner) error {
- if in.AccessModes != nil {
- in, out := in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.AccessModes = nil
- }
- if in.Selector != nil {
- in, out := in.Selector, &out.Selector
- *out = new(unversioned.LabelSelector)
- if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Selector = nil
- }
- if err := DeepCopy_v1_ResourceRequirements(in.Resources, &out.Resources, c); err != nil {
- return err
- }
- out.VolumeName = in.VolumeName
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeClaimStatus(in PersistentVolumeClaimStatus, out *PersistentVolumeClaimStatus, c *conversion.Cloner) error {
- out.Phase = in.Phase
- if in.AccessModes != nil {
- in, out := in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.AccessModes = nil
- }
- if in.Capacity != nil {
- in, out := in.Capacity, &out.Capacity
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Capacity = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeClaimVolumeSource(in PersistentVolumeClaimVolumeSource, out *PersistentVolumeClaimVolumeSource, c *conversion.Cloner) error {
- out.ClaimName = in.ClaimName
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeList(in PersistentVolumeList, out *PersistentVolumeList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]PersistentVolume, len(in))
- for i := range in {
- if err := DeepCopy_v1_PersistentVolume(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeSource(in PersistentVolumeSource, out *PersistentVolumeSource, c *conversion.Cloner) error {
- if in.GCEPersistentDisk != nil {
- in, out := in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(GCEPersistentDiskVolumeSource)
- **out = *in
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(AWSElasticBlockStoreVolumeSource)
- **out = *in
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.HostPath != nil {
- in, out := in.HostPath, &out.HostPath
- *out = new(HostPathVolumeSource)
- **out = *in
- } else {
- out.HostPath = nil
- }
- if in.Glusterfs != nil {
- in, out := in.Glusterfs, &out.Glusterfs
- *out = new(GlusterfsVolumeSource)
- **out = *in
- } else {
- out.Glusterfs = nil
- }
- if in.NFS != nil {
- in, out := in.NFS, &out.NFS
- *out = new(NFSVolumeSource)
- **out = *in
- } else {
- out.NFS = nil
- }
- if in.RBD != nil {
- in, out := in.RBD, &out.RBD
- *out = new(RBDVolumeSource)
- if err := DeepCopy_v1_RBDVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.ISCSI != nil {
- in, out := in.ISCSI, &out.ISCSI
- *out = new(ISCSIVolumeSource)
- **out = *in
- } else {
- out.ISCSI = nil
- }
- if in.Cinder != nil {
- in, out := in.Cinder, &out.Cinder
- *out = new(CinderVolumeSource)
- **out = *in
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := in.CephFS, &out.CephFS
- *out = new(CephFSVolumeSource)
- if err := DeepCopy_v1_CephFSVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.FC != nil {
- in, out := in.FC, &out.FC
- *out = new(FCVolumeSource)
- if err := DeepCopy_v1_FCVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.Flocker != nil {
- in, out := in.Flocker, &out.Flocker
- *out = new(FlockerVolumeSource)
- **out = *in
- } else {
- out.Flocker = nil
- }
- if in.FlexVolume != nil {
- in, out := in.FlexVolume, &out.FlexVolume
- *out = new(FlexVolumeSource)
- if err := DeepCopy_v1_FlexVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.AzureFile != nil {
- in, out := in.AzureFile, &out.AzureFile
- *out = new(AzureFileVolumeSource)
- **out = *in
- } else {
- out.AzureFile = nil
- }
- if in.VsphereVolume != nil {
- in, out := in.VsphereVolume, &out.VsphereVolume
- *out = new(VsphereVirtualDiskVolumeSource)
- **out = *in
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeSpec(in PersistentVolumeSpec, out *PersistentVolumeSpec, c *conversion.Cloner) error {
- if in.Capacity != nil {
- in, out := in.Capacity, &out.Capacity
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Capacity = nil
- }
- if err := DeepCopy_v1_PersistentVolumeSource(in.PersistentVolumeSource, &out.PersistentVolumeSource, c); err != nil {
- return err
- }
- if in.AccessModes != nil {
- in, out := in.AccessModes, &out.AccessModes
- *out = make([]PersistentVolumeAccessMode, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.AccessModes = nil
- }
- if in.ClaimRef != nil {
- in, out := in.ClaimRef, &out.ClaimRef
- *out = new(ObjectReference)
- **out = *in
- } else {
- out.ClaimRef = nil
- }
- out.PersistentVolumeReclaimPolicy = in.PersistentVolumeReclaimPolicy
- return nil
-}
-
-func DeepCopy_v1_PersistentVolumeStatus(in PersistentVolumeStatus, out *PersistentVolumeStatus, c *conversion.Cloner) error {
- out.Phase = in.Phase
- out.Message = in.Message
- out.Reason = in.Reason
- return nil
-}
-
-func DeepCopy_v1_Pod(in Pod, out *Pod, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PodSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PodStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_PodAffinity(in PodAffinity, out *PodAffinity, c *conversion.Cloner) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]PodAffinityTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_PodAffinityTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]WeightedPodAffinityTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_WeightedPodAffinityTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodAffinityTerm(in PodAffinityTerm, out *PodAffinityTerm, c *conversion.Cloner) error {
- if in.LabelSelector != nil {
- in, out := in.LabelSelector, &out.LabelSelector
- *out = new(unversioned.LabelSelector)
- if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.LabelSelector = nil
- }
- if in.Namespaces != nil {
- in, out := in.Namespaces, &out.Namespaces
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Namespaces = nil
- }
- out.TopologyKey = in.TopologyKey
- return nil
-}
-
-func DeepCopy_v1_PodAntiAffinity(in PodAntiAffinity, out *PodAntiAffinity, c *conversion.Cloner) error {
- if in.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution
- *out = make([]PodAffinityTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_PodAffinityTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- if in.PreferredDuringSchedulingIgnoredDuringExecution != nil {
- in, out := in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution
- *out = make([]WeightedPodAffinityTerm, len(in))
- for i := range in {
- if err := DeepCopy_v1_WeightedPodAffinityTerm(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.PreferredDuringSchedulingIgnoredDuringExecution = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodAttachOptions(in PodAttachOptions, out *PodAttachOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- return nil
-}
-
-func DeepCopy_v1_PodCondition(in PodCondition, out *PodCondition, c *conversion.Cloner) error {
- out.Type = in.Type
- out.Status = in.Status
- out.LastProbeTime = in.LastProbeTime.DeepCopy()
- out.LastTransitionTime = in.LastTransitionTime.DeepCopy()
- out.Reason = in.Reason
- out.Message = in.Message
- return nil
-}
-
-func DeepCopy_v1_PodExecOptions(in PodExecOptions, out *PodExecOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Stdin = in.Stdin
- out.Stdout = in.Stdout
- out.Stderr = in.Stderr
- out.TTY = in.TTY
- out.Container = in.Container
- if in.Command != nil {
- in, out := in.Command, &out.Command
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.Command = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodList(in PodList, out *PodList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Pod, len(in))
- for i := range in {
- if err := DeepCopy_v1_Pod(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodLogOptions(in PodLogOptions, out *PodLogOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Container = in.Container
- out.Follow = in.Follow
- out.Previous = in.Previous
- if in.SinceSeconds != nil {
- in, out := in.SinceSeconds, &out.SinceSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.SinceSeconds = nil
- }
- if in.SinceTime != nil {
- in, out := in.SinceTime, &out.SinceTime
- *out = new(unversioned.Time)
- **out = in.DeepCopy()
- } else {
- out.SinceTime = nil
- }
- out.Timestamps = in.Timestamps
- if in.TailLines != nil {
- in, out := in.TailLines, &out.TailLines
- *out = new(int64)
- **out = *in
- } else {
- out.TailLines = nil
- }
- if in.LimitBytes != nil {
- in, out := in.LimitBytes, &out.LimitBytes
- *out = new(int64)
- **out = *in
- } else {
- out.LimitBytes = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodProxyOptions(in PodProxyOptions, out *PodProxyOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Path = in.Path
- return nil
-}
-
-func DeepCopy_v1_PodSecurityContext(in PodSecurityContext, out *PodSecurityContext, c *conversion.Cloner) error {
- if in.SELinuxOptions != nil {
- in, out := in.SELinuxOptions, &out.SELinuxOptions
- *out = new(SELinuxOptions)
- **out = *in
- } else {
- out.SELinuxOptions = nil
- }
- if in.RunAsUser != nil {
- in, out := in.RunAsUser, &out.RunAsUser
- *out = new(int64)
- **out = *in
- } else {
- out.RunAsUser = nil
- }
- if in.RunAsNonRoot != nil {
- in, out := in.RunAsNonRoot, &out.RunAsNonRoot
- *out = new(bool)
- **out = *in
- } else {
- out.RunAsNonRoot = nil
- }
- if in.SupplementalGroups != nil {
- in, out := in.SupplementalGroups, &out.SupplementalGroups
- *out = make([]int64, len(in))
- copy(*out, in)
- } else {
- out.SupplementalGroups = nil
- }
- if in.FSGroup != nil {
- in, out := in.FSGroup, &out.FSGroup
- *out = new(int64)
- **out = *in
- } else {
- out.FSGroup = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodSpec(in PodSpec, out *PodSpec, c *conversion.Cloner) error {
- if in.Volumes != nil {
- in, out := in.Volumes, &out.Volumes
- *out = make([]Volume, len(in))
- for i := range in {
- if err := DeepCopy_v1_Volume(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Volumes = nil
- }
- if in.InitContainers != nil {
- in, out := in.InitContainers, &out.InitContainers
- *out = make([]Container, len(in))
- for i := range in {
- if err := DeepCopy_v1_Container(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.InitContainers = nil
- }
- if in.Containers != nil {
- in, out := in.Containers, &out.Containers
- *out = make([]Container, len(in))
- for i := range in {
- if err := DeepCopy_v1_Container(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Containers = nil
- }
- out.RestartPolicy = in.RestartPolicy
- if in.TerminationGracePeriodSeconds != nil {
- in, out := in.TerminationGracePeriodSeconds, &out.TerminationGracePeriodSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.TerminationGracePeriodSeconds = nil
- }
- if in.ActiveDeadlineSeconds != nil {
- in, out := in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds
- *out = new(int64)
- **out = *in
- } else {
- out.ActiveDeadlineSeconds = nil
- }
- out.DNSPolicy = in.DNSPolicy
- if in.NodeSelector != nil {
- in, out := in.NodeSelector, &out.NodeSelector
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.NodeSelector = nil
- }
- out.ServiceAccountName = in.ServiceAccountName
- out.DeprecatedServiceAccount = in.DeprecatedServiceAccount
- out.NodeName = in.NodeName
- out.HostNetwork = in.HostNetwork
- out.HostPID = in.HostPID
- out.HostIPC = in.HostIPC
- if in.SecurityContext != nil {
- in, out := in.SecurityContext, &out.SecurityContext
- *out = new(PodSecurityContext)
- if err := DeepCopy_v1_PodSecurityContext(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.SecurityContext = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]LocalObjectReference, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.ImagePullSecrets = nil
- }
- out.Hostname = in.Hostname
- out.Subdomain = in.Subdomain
- return nil
-}
-
-func DeepCopy_v1_PodStatus(in PodStatus, out *PodStatus, c *conversion.Cloner) error {
- out.Phase = in.Phase
- if in.Conditions != nil {
- in, out := in.Conditions, &out.Conditions
- *out = make([]PodCondition, len(in))
- for i := range in {
- if err := DeepCopy_v1_PodCondition(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Conditions = nil
- }
- out.Message = in.Message
- out.Reason = in.Reason
- out.HostIP = in.HostIP
- out.PodIP = in.PodIP
- if in.StartTime != nil {
- in, out := in.StartTime, &out.StartTime
- *out = new(unversioned.Time)
- **out = in.DeepCopy()
- } else {
- out.StartTime = nil
- }
- if in.InitContainerStatuses != nil {
- in, out := in.InitContainerStatuses, &out.InitContainerStatuses
- *out = make([]ContainerStatus, len(in))
- for i := range in {
- if err := DeepCopy_v1_ContainerStatus(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.InitContainerStatuses = nil
- }
- if in.ContainerStatuses != nil {
- in, out := in.ContainerStatuses, &out.ContainerStatuses
- *out = make([]ContainerStatus, len(in))
- for i := range in {
- if err := DeepCopy_v1_ContainerStatus(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.ContainerStatuses = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodStatusResult(in PodStatusResult, out *PodStatusResult, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PodStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_PodTemplate(in PodTemplate, out *PodTemplate, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PodTemplateSpec(in.Template, &out.Template, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_PodTemplateList(in PodTemplateList, out *PodTemplateList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]PodTemplate, len(in))
- for i := range in {
- if err := DeepCopy_v1_PodTemplate(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PodTemplateSpec(in PodTemplateSpec, out *PodTemplateSpec, c *conversion.Cloner) error {
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_PodSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_Preconditions(in Preconditions, out *Preconditions, c *conversion.Cloner) error {
- if in.UID != nil {
- in, out := in.UID, &out.UID
- *out = new(types.UID)
- **out = *in
- } else {
- out.UID = nil
- }
- return nil
-}
-
-func DeepCopy_v1_PreferredSchedulingTerm(in PreferredSchedulingTerm, out *PreferredSchedulingTerm, c *conversion.Cloner) error {
- out.Weight = in.Weight
- if err := DeepCopy_v1_NodeSelectorTerm(in.Preference, &out.Preference, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_Probe(in Probe, out *Probe, c *conversion.Cloner) error {
- if err := DeepCopy_v1_Handler(in.Handler, &out.Handler, c); err != nil {
- return err
- }
- out.InitialDelaySeconds = in.InitialDelaySeconds
- out.TimeoutSeconds = in.TimeoutSeconds
- out.PeriodSeconds = in.PeriodSeconds
- out.SuccessThreshold = in.SuccessThreshold
- out.FailureThreshold = in.FailureThreshold
- return nil
-}
-
-func DeepCopy_v1_RBDVolumeSource(in RBDVolumeSource, out *RBDVolumeSource, c *conversion.Cloner) error {
- if in.CephMonitors != nil {
- in, out := in.CephMonitors, &out.CephMonitors
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.CephMonitors = nil
- }
- out.RBDImage = in.RBDImage
- out.FSType = in.FSType
- out.RBDPool = in.RBDPool
- out.RadosUser = in.RadosUser
- out.Keyring = in.Keyring
- if in.SecretRef != nil {
- in, out := in.SecretRef, &out.SecretRef
- *out = new(LocalObjectReference)
- **out = *in
- } else {
- out.SecretRef = nil
- }
- out.ReadOnly = in.ReadOnly
- return nil
-}
-
-func DeepCopy_v1_RangeAllocation(in RangeAllocation, out *RangeAllocation, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- out.Range = in.Range
- if in.Data != nil {
- in, out := in.Data, &out.Data
- *out = make([]byte, len(in))
- copy(*out, in)
- } else {
- out.Data = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ReplicationController(in ReplicationController, out *ReplicationController, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ReplicationControllerSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- out.Status = in.Status
- return nil
-}
-
-func DeepCopy_v1_ReplicationControllerList(in ReplicationControllerList, out *ReplicationControllerList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]ReplicationController, len(in))
- for i := range in {
- if err := DeepCopy_v1_ReplicationController(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ReplicationControllerSpec(in ReplicationControllerSpec, out *ReplicationControllerSpec, c *conversion.Cloner) error {
- if in.Replicas != nil {
- in, out := in.Replicas, &out.Replicas
- *out = new(int32)
- **out = *in
- } else {
- out.Replicas = nil
- }
- if in.Selector != nil {
- in, out := in.Selector, &out.Selector
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Selector = nil
- }
- if in.Template != nil {
- in, out := in.Template, &out.Template
- *out = new(PodTemplateSpec)
- if err := DeepCopy_v1_PodTemplateSpec(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Template = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ReplicationControllerStatus(in ReplicationControllerStatus, out *ReplicationControllerStatus, c *conversion.Cloner) error {
- out.Replicas = in.Replicas
- out.FullyLabeledReplicas = in.FullyLabeledReplicas
- out.ObservedGeneration = in.ObservedGeneration
- return nil
-}
-
-func DeepCopy_v1_ResourceFieldSelector(in ResourceFieldSelector, out *ResourceFieldSelector, c *conversion.Cloner) error {
- out.ContainerName = in.ContainerName
- out.Resource = in.Resource
- out.Divisor = in.Divisor.DeepCopy()
- return nil
-}
-
-func DeepCopy_v1_ResourceQuota(in ResourceQuota, out *ResourceQuota, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ResourceQuotaSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ResourceQuotaStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_ResourceQuotaList(in ResourceQuotaList, out *ResourceQuotaList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]ResourceQuota, len(in))
- for i := range in {
- if err := DeepCopy_v1_ResourceQuota(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ResourceQuotaSpec(in ResourceQuotaSpec, out *ResourceQuotaSpec, c *conversion.Cloner) error {
- if in.Hard != nil {
- in, out := in.Hard, &out.Hard
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Hard = nil
- }
- if in.Scopes != nil {
- in, out := in.Scopes, &out.Scopes
- *out = make([]ResourceQuotaScope, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Scopes = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ResourceQuotaStatus(in ResourceQuotaStatus, out *ResourceQuotaStatus, c *conversion.Cloner) error {
- if in.Hard != nil {
- in, out := in.Hard, &out.Hard
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Hard = nil
- }
- if in.Used != nil {
- in, out := in.Used, &out.Used
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Used = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ResourceRequirements(in ResourceRequirements, out *ResourceRequirements, c *conversion.Cloner) error {
- if in.Limits != nil {
- in, out := in.Limits, &out.Limits
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Limits = nil
- }
- if in.Requests != nil {
- in, out := in.Requests, &out.Requests
- *out = make(ResourceList)
- for key, val := range in {
- (*out)[key] = val.DeepCopy()
- }
- } else {
- out.Requests = nil
- }
- return nil
-}
-
-func DeepCopy_v1_SELinuxOptions(in SELinuxOptions, out *SELinuxOptions, c *conversion.Cloner) error {
- out.User = in.User
- out.Role = in.Role
- out.Type = in.Type
- out.Level = in.Level
- return nil
-}
-
-func DeepCopy_v1_Secret(in Secret, out *Secret, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if in.Data != nil {
- in, out := in.Data, &out.Data
- *out = make(map[string][]byte)
- for key, val := range in {
- if newVal, err := c.DeepCopy(val); err != nil {
- return err
- } else {
- (*out)[key] = newVal.([]byte)
- }
- }
- } else {
- out.Data = nil
- }
- if in.StringData != nil {
- in, out := in.StringData, &out.StringData
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.StringData = nil
- }
- out.Type = in.Type
- return nil
-}
-
-func DeepCopy_v1_SecretKeySelector(in SecretKeySelector, out *SecretKeySelector, c *conversion.Cloner) error {
- out.LocalObjectReference = in.LocalObjectReference
- out.Key = in.Key
- return nil
-}
-
-func DeepCopy_v1_SecretList(in SecretList, out *SecretList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Secret, len(in))
- for i := range in {
- if err := DeepCopy_v1_Secret(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_SecretVolumeSource(in SecretVolumeSource, out *SecretVolumeSource, c *conversion.Cloner) error {
- out.SecretName = in.SecretName
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]KeyToPath, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_SecurityContext(in SecurityContext, out *SecurityContext, c *conversion.Cloner) error {
- if in.Capabilities != nil {
- in, out := in.Capabilities, &out.Capabilities
- *out = new(Capabilities)
- if err := DeepCopy_v1_Capabilities(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Capabilities = nil
- }
- if in.Privileged != nil {
- in, out := in.Privileged, &out.Privileged
- *out = new(bool)
- **out = *in
- } else {
- out.Privileged = nil
- }
- if in.SELinuxOptions != nil {
- in, out := in.SELinuxOptions, &out.SELinuxOptions
- *out = new(SELinuxOptions)
- **out = *in
- } else {
- out.SELinuxOptions = nil
- }
- if in.RunAsUser != nil {
- in, out := in.RunAsUser, &out.RunAsUser
- *out = new(int64)
- **out = *in
- } else {
- out.RunAsUser = nil
- }
- if in.RunAsNonRoot != nil {
- in, out := in.RunAsNonRoot, &out.RunAsNonRoot
- *out = new(bool)
- **out = *in
- } else {
- out.RunAsNonRoot = nil
- }
- if in.ReadOnlyRootFilesystem != nil {
- in, out := in.ReadOnlyRootFilesystem, &out.ReadOnlyRootFilesystem
- *out = new(bool)
- **out = *in
- } else {
- out.ReadOnlyRootFilesystem = nil
- }
- return nil
-}
-
-func DeepCopy_v1_SerializedReference(in SerializedReference, out *SerializedReference, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Reference = in.Reference
- return nil
-}
-
-func DeepCopy_v1_Service(in Service, out *Service, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ServiceSpec(in.Spec, &out.Spec, c); err != nil {
- return err
- }
- if err := DeepCopy_v1_ServiceStatus(in.Status, &out.Status, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_ServiceAccount(in ServiceAccount, out *ServiceAccount, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- if err := DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
- return err
- }
- if in.Secrets != nil {
- in, out := in.Secrets, &out.Secrets
- *out = make([]ObjectReference, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Secrets = nil
- }
- if in.ImagePullSecrets != nil {
- in, out := in.ImagePullSecrets, &out.ImagePullSecrets
- *out = make([]LocalObjectReference, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.ImagePullSecrets = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ServiceAccountList(in ServiceAccountList, out *ServiceAccountList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]ServiceAccount, len(in))
- for i := range in {
- if err := DeepCopy_v1_ServiceAccount(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ServiceList(in ServiceList, out *ServiceList, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.ListMeta = in.ListMeta
- if in.Items != nil {
- in, out := in.Items, &out.Items
- *out = make([]Service, len(in))
- for i := range in {
- if err := DeepCopy_v1_Service(in[i], &(*out)[i], c); err != nil {
- return err
- }
- }
- } else {
- out.Items = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ServicePort(in ServicePort, out *ServicePort, c *conversion.Cloner) error {
- out.Name = in.Name
- out.Protocol = in.Protocol
- out.Port = in.Port
- out.TargetPort = in.TargetPort
- out.NodePort = in.NodePort
- return nil
-}
-
-func DeepCopy_v1_ServiceProxyOptions(in ServiceProxyOptions, out *ServiceProxyOptions, c *conversion.Cloner) error {
- out.TypeMeta = in.TypeMeta
- out.Path = in.Path
- return nil
-}
-
-func DeepCopy_v1_ServiceSpec(in ServiceSpec, out *ServiceSpec, c *conversion.Cloner) error {
- if in.Ports != nil {
- in, out := in.Ports, &out.Ports
- *out = make([]ServicePort, len(in))
- for i := range in {
- (*out)[i] = in[i]
- }
- } else {
- out.Ports = nil
- }
- if in.Selector != nil {
- in, out := in.Selector, &out.Selector
- *out = make(map[string]string)
- for key, val := range in {
- (*out)[key] = val
- }
- } else {
- out.Selector = nil
- }
- out.ClusterIP = in.ClusterIP
- out.Type = in.Type
- if in.ExternalIPs != nil {
- in, out := in.ExternalIPs, &out.ExternalIPs
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.ExternalIPs = nil
- }
- if in.DeprecatedPublicIPs != nil {
- in, out := in.DeprecatedPublicIPs, &out.DeprecatedPublicIPs
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.DeprecatedPublicIPs = nil
- }
- out.SessionAffinity = in.SessionAffinity
- out.LoadBalancerIP = in.LoadBalancerIP
- if in.LoadBalancerSourceRanges != nil {
- in, out := in.LoadBalancerSourceRanges, &out.LoadBalancerSourceRanges
- *out = make([]string, len(in))
- copy(*out, in)
- } else {
- out.LoadBalancerSourceRanges = nil
- }
- return nil
-}
-
-func DeepCopy_v1_ServiceStatus(in ServiceStatus, out *ServiceStatus, c *conversion.Cloner) error {
- if err := DeepCopy_v1_LoadBalancerStatus(in.LoadBalancer, &out.LoadBalancer, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_TCPSocketAction(in TCPSocketAction, out *TCPSocketAction, c *conversion.Cloner) error {
- out.Port = in.Port
- return nil
-}
-
-func DeepCopy_v1_Taint(in Taint, out *Taint, c *conversion.Cloner) error {
- out.Key = in.Key
- out.Value = in.Value
- out.Effect = in.Effect
- return nil
-}
-
-func DeepCopy_v1_Toleration(in Toleration, out *Toleration, c *conversion.Cloner) error {
- out.Key = in.Key
- out.Operator = in.Operator
- out.Value = in.Value
- out.Effect = in.Effect
- return nil
-}
-
-func DeepCopy_v1_Volume(in Volume, out *Volume, c *conversion.Cloner) error {
- out.Name = in.Name
- if err := DeepCopy_v1_VolumeSource(in.VolumeSource, &out.VolumeSource, c); err != nil {
- return err
- }
- return nil
-}
-
-func DeepCopy_v1_VolumeMount(in VolumeMount, out *VolumeMount, c *conversion.Cloner) error {
- out.Name = in.Name
- out.ReadOnly = in.ReadOnly
- out.MountPath = in.MountPath
- out.SubPath = in.SubPath
- return nil
-}
-
-func DeepCopy_v1_VolumeSource(in VolumeSource, out *VolumeSource, c *conversion.Cloner) error {
- if in.HostPath != nil {
- in, out := in.HostPath, &out.HostPath
- *out = new(HostPathVolumeSource)
- **out = *in
- } else {
- out.HostPath = nil
- }
- if in.EmptyDir != nil {
- in, out := in.EmptyDir, &out.EmptyDir
- *out = new(EmptyDirVolumeSource)
- **out = *in
- } else {
- out.EmptyDir = nil
- }
- if in.GCEPersistentDisk != nil {
- in, out := in.GCEPersistentDisk, &out.GCEPersistentDisk
- *out = new(GCEPersistentDiskVolumeSource)
- **out = *in
- } else {
- out.GCEPersistentDisk = nil
- }
- if in.AWSElasticBlockStore != nil {
- in, out := in.AWSElasticBlockStore, &out.AWSElasticBlockStore
- *out = new(AWSElasticBlockStoreVolumeSource)
- **out = *in
- } else {
- out.AWSElasticBlockStore = nil
- }
- if in.GitRepo != nil {
- in, out := in.GitRepo, &out.GitRepo
- *out = new(GitRepoVolumeSource)
- **out = *in
- } else {
- out.GitRepo = nil
- }
- if in.Secret != nil {
- in, out := in.Secret, &out.Secret
- *out = new(SecretVolumeSource)
- if err := DeepCopy_v1_SecretVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.Secret = nil
- }
- if in.NFS != nil {
- in, out := in.NFS, &out.NFS
- *out = new(NFSVolumeSource)
- **out = *in
- } else {
- out.NFS = nil
- }
- if in.ISCSI != nil {
- in, out := in.ISCSI, &out.ISCSI
- *out = new(ISCSIVolumeSource)
- **out = *in
- } else {
- out.ISCSI = nil
- }
- if in.Glusterfs != nil {
- in, out := in.Glusterfs, &out.Glusterfs
- *out = new(GlusterfsVolumeSource)
- **out = *in
- } else {
- out.Glusterfs = nil
- }
- if in.PersistentVolumeClaim != nil {
- in, out := in.PersistentVolumeClaim, &out.PersistentVolumeClaim
- *out = new(PersistentVolumeClaimVolumeSource)
- **out = *in
- } else {
- out.PersistentVolumeClaim = nil
- }
- if in.RBD != nil {
- in, out := in.RBD, &out.RBD
- *out = new(RBDVolumeSource)
- if err := DeepCopy_v1_RBDVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.RBD = nil
- }
- if in.FlexVolume != nil {
- in, out := in.FlexVolume, &out.FlexVolume
- *out = new(FlexVolumeSource)
- if err := DeepCopy_v1_FlexVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.FlexVolume = nil
- }
- if in.Cinder != nil {
- in, out := in.Cinder, &out.Cinder
- *out = new(CinderVolumeSource)
- **out = *in
- } else {
- out.Cinder = nil
- }
- if in.CephFS != nil {
- in, out := in.CephFS, &out.CephFS
- *out = new(CephFSVolumeSource)
- if err := DeepCopy_v1_CephFSVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.CephFS = nil
- }
- if in.Flocker != nil {
- in, out := in.Flocker, &out.Flocker
- *out = new(FlockerVolumeSource)
- **out = *in
- } else {
- out.Flocker = nil
- }
- if in.DownwardAPI != nil {
- in, out := in.DownwardAPI, &out.DownwardAPI
- *out = new(DownwardAPIVolumeSource)
- if err := DeepCopy_v1_DownwardAPIVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.DownwardAPI = nil
- }
- if in.FC != nil {
- in, out := in.FC, &out.FC
- *out = new(FCVolumeSource)
- if err := DeepCopy_v1_FCVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.FC = nil
- }
- if in.AzureFile != nil {
- in, out := in.AzureFile, &out.AzureFile
- *out = new(AzureFileVolumeSource)
- **out = *in
- } else {
- out.AzureFile = nil
- }
- if in.ConfigMap != nil {
- in, out := in.ConfigMap, &out.ConfigMap
- *out = new(ConfigMapVolumeSource)
- if err := DeepCopy_v1_ConfigMapVolumeSource(*in, *out, c); err != nil {
- return err
- }
- } else {
- out.ConfigMap = nil
- }
- if in.VsphereVolume != nil {
- in, out := in.VsphereVolume, &out.VsphereVolume
- *out = new(VsphereVirtualDiskVolumeSource)
- **out = *in
- } else {
- out.VsphereVolume = nil
- }
- return nil
-}
-
-func DeepCopy_v1_VsphereVirtualDiskVolumeSource(in VsphereVirtualDiskVolumeSource, out *VsphereVirtualDiskVolumeSource, c *conversion.Cloner) error {
- out.VolumePath = in.VolumePath
- out.FSType = in.FSType
- return nil
-}
-
-func DeepCopy_v1_WeightedPodAffinityTerm(in WeightedPodAffinityTerm, out *WeightedPodAffinityTerm, c *conversion.Cloner) error {
- out.Weight = in.Weight
- if err := DeepCopy_v1_PodAffinityTerm(in.PodAffinityTerm, &out.PodAffinityTerm, c); err != nil {
- return err
- }
- return nil
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/defaults.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/defaults.go
deleted file mode 100644
index 5d6323f..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/defaults.go
+++ /dev/null
@@ -1,301 +0,0 @@
-/*
-Copyright 2015 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.
-*/
-
-package v1
-
-import (
- "k8s.io/kubernetes/pkg/runtime"
- "k8s.io/kubernetes/pkg/util"
- "k8s.io/kubernetes/pkg/util/intstr"
- "k8s.io/kubernetes/pkg/util/parsers"
-)
-
-func addDefaultingFuncs(scheme *runtime.Scheme) {
- scheme.AddDefaultingFuncs(
- SetDefaults_PodExecOptions,
- SetDefaults_PodAttachOptions,
- SetDefaults_ReplicationController,
- SetDefaults_Volume,
- SetDefaults_ContainerPort,
- SetDefaults_Container,
- SetDefaults_ServiceSpec,
- SetDefaults_Pod,
- SetDefaults_PodSpec,
- SetDefaults_Probe,
- SetDefaults_Secret,
- SetDefaults_PersistentVolume,
- SetDefaults_PersistentVolumeClaim,
- SetDefaults_ISCSIVolumeSource,
- SetDefaults_Endpoints,
- SetDefaults_HTTPGetAction,
- SetDefaults_NamespaceStatus,
- SetDefaults_Node,
- SetDefaults_NodeStatus,
- SetDefaults_ObjectFieldSelector,
- SetDefaults_LimitRangeItem,
- SetDefaults_ConfigMap,
- SetDefaults_RBDVolumeSource,
- )
-}
-
-func SetDefaults_PodExecOptions(obj *PodExecOptions) {
- obj.Stdout = true
- obj.Stderr = true
-}
-func SetDefaults_PodAttachOptions(obj *PodAttachOptions) {
- obj.Stdout = true
- obj.Stderr = true
-}
-func SetDefaults_ReplicationController(obj *ReplicationController) {
- var labels map[string]string
- if obj.Spec.Template != nil {
- labels = obj.Spec.Template.Labels
- }
- // TODO: support templates defined elsewhere when we support them in the API
- if labels != nil {
- if len(obj.Spec.Selector) == 0 {
- obj.Spec.Selector = labels
- }
- if len(obj.Labels) == 0 {
- obj.Labels = labels
- }
- }
- if obj.Spec.Replicas == nil {
- obj.Spec.Replicas = new(int32)
- *obj.Spec.Replicas = 1
- }
-}
-func SetDefaults_Volume(obj *Volume) {
- if util.AllPtrFieldsNil(&obj.VolumeSource) {
- obj.VolumeSource = VolumeSource{
- EmptyDir: &EmptyDirVolumeSource{},
- }
- }
-}
-func SetDefaults_ContainerPort(obj *ContainerPort) {
- if obj.Protocol == "" {
- obj.Protocol = ProtocolTCP
- }
-}
-func SetDefaults_Container(obj *Container) {
- if obj.ImagePullPolicy == "" {
- // Ignore error and assume it has been validated elsewhere
- _, tag, _, _ := parsers.ParseImageName(obj.Image)
-
- // Check image tag
-
- if tag == "latest" {
- obj.ImagePullPolicy = PullAlways
- } else {
- obj.ImagePullPolicy = PullIfNotPresent
- }
- }
- if obj.TerminationMessagePath == "" {
- obj.TerminationMessagePath = TerminationMessagePathDefault
- }
-}
-func SetDefaults_ServiceSpec(obj *ServiceSpec) {
- if obj.SessionAffinity == "" {
- obj.SessionAffinity = ServiceAffinityNone
- }
- if obj.Type == "" {
- obj.Type = ServiceTypeClusterIP
- }
- for i := range obj.Ports {
- sp := &obj.Ports[i]
- if sp.Protocol == "" {
- sp.Protocol = ProtocolTCP
- }
- if sp.TargetPort == intstr.FromInt(0) || sp.TargetPort == intstr.FromString("") {
- sp.TargetPort = intstr.FromInt(int(sp.Port))
- }
- }
-}
-func SetDefaults_Pod(obj *Pod) {
- // If limits are specified, but requests are not, default requests to limits
- // This is done here rather than a more specific defaulting pass on ResourceRequirements
- // because we only want this defaulting semantic to take place on a Pod and not a PodTemplate
- for i := range obj.Spec.Containers {
- // set requests to limits if requests are not specified, but limits are
- if obj.Spec.Containers[i].Resources.Limits != nil {
- if obj.Spec.Containers[i].Resources.Requests == nil {
- obj.Spec.Containers[i].Resources.Requests = make(ResourceList)
- }
- for key, value := range obj.Spec.Containers[i].Resources.Limits {
- if _, exists := obj.Spec.Containers[i].Resources.Requests[key]; !exists {
- obj.Spec.Containers[i].Resources.Requests[key] = *(value.Copy())
- }
- }
- }
- }
-}
-func SetDefaults_PodSpec(obj *PodSpec) {
- if obj.DNSPolicy == "" {
- obj.DNSPolicy = DNSClusterFirst
- }
- if obj.RestartPolicy == "" {
- obj.RestartPolicy = RestartPolicyAlways
- }
- if obj.HostNetwork {
- defaultHostNetworkPorts(&obj.Containers)
- }
- if obj.SecurityContext == nil {
- obj.SecurityContext = &PodSecurityContext{}
- }
- if obj.TerminationGracePeriodSeconds == nil {
- period := int64(DefaultTerminationGracePeriodSeconds)
- obj.TerminationGracePeriodSeconds = &period
- }
-}
-func SetDefaults_Probe(obj *Probe) {
- if obj.TimeoutSeconds == 0 {
- obj.TimeoutSeconds = 1
- }
- if obj.PeriodSeconds == 0 {
- obj.PeriodSeconds = 10
- }
- if obj.SuccessThreshold == 0 {
- obj.SuccessThreshold = 1
- }
- if obj.FailureThreshold == 0 {
- obj.FailureThreshold = 3
- }
-}
-func SetDefaults_Secret(obj *Secret) {
- if obj.Type == "" {
- obj.Type = SecretTypeOpaque
- }
-}
-func SetDefaults_PersistentVolume(obj *PersistentVolume) {
- if obj.Status.Phase == "" {
- obj.Status.Phase = VolumePending
- }
- if obj.Spec.PersistentVolumeReclaimPolicy == "" {
- obj.Spec.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimRetain
- }
-}
-func SetDefaults_PersistentVolumeClaim(obj *PersistentVolumeClaim) {
- if obj.Status.Phase == "" {
- obj.Status.Phase = ClaimPending
- }
-}
-func SetDefaults_ISCSIVolumeSource(obj *ISCSIVolumeSource) {
- if obj.ISCSIInterface == "" {
- obj.ISCSIInterface = "default"
- }
-}
-func SetDefaults_Endpoints(obj *Endpoints) {
- for i := range obj.Subsets {
- ss := &obj.Subsets[i]
- for i := range ss.Ports {
- ep := &ss.Ports[i]
- if ep.Protocol == "" {
- ep.Protocol = ProtocolTCP
- }
- }
- }
-}
-func SetDefaults_HTTPGetAction(obj *HTTPGetAction) {
- if obj.Path == "" {
- obj.Path = "/"
- }
- if obj.Scheme == "" {
- obj.Scheme = URISchemeHTTP
- }
-}
-func SetDefaults_NamespaceStatus(obj *NamespaceStatus) {
- if obj.Phase == "" {
- obj.Phase = NamespaceActive
- }
-}
-func SetDefaults_Node(obj *Node) {
- if obj.Spec.ExternalID == "" {
- obj.Spec.ExternalID = obj.Name
- }
-}
-func SetDefaults_NodeStatus(obj *NodeStatus) {
- if obj.Allocatable == nil && obj.Capacity != nil {
- obj.Allocatable = make(ResourceList, len(obj.Capacity))
- for key, value := range obj.Capacity {
- obj.Allocatable[key] = *(value.Copy())
- }
- obj.Allocatable = obj.Capacity
- }
-}
-func SetDefaults_ObjectFieldSelector(obj *ObjectFieldSelector) {
- if obj.APIVersion == "" {
- obj.APIVersion = "v1"
- }
-}
-func SetDefaults_LimitRangeItem(obj *LimitRangeItem) {
- // for container limits, we apply default values
- if obj.Type == LimitTypeContainer {
-
- if obj.Default == nil {
- obj.Default = make(ResourceList)
- }
- if obj.DefaultRequest == nil {
- obj.DefaultRequest = make(ResourceList)
- }
-
- // If a default limit is unspecified, but the max is specified, default the limit to the max
- for key, value := range obj.Max {
- if _, exists := obj.Default[key]; !exists {
- obj.Default[key] = *(value.Copy())
- }
- }
- // If a default limit is specified, but the default request is not, default request to limit
- for key, value := range obj.Default {
- if _, exists := obj.DefaultRequest[key]; !exists {
- obj.DefaultRequest[key] = *(value.Copy())
- }
- }
- // If a default request is not specified, but the min is provided, default request to the min
- for key, value := range obj.Min {
- if _, exists := obj.DefaultRequest[key]; !exists {
- obj.DefaultRequest[key] = *(value.Copy())
- }
- }
- }
-}
-func SetDefaults_ConfigMap(obj *ConfigMap) {
- if obj.Data == nil {
- obj.Data = make(map[string]string)
- }
-}
-
-// With host networking default all container ports to host ports.
-func defaultHostNetworkPorts(containers *[]Container) {
- for i := range *containers {
- for j := range (*containers)[i].Ports {
- if (*containers)[i].Ports[j].HostPort == 0 {
- (*containers)[i].Ports[j].HostPort = (*containers)[i].Ports[j].ContainerPort
- }
- }
- }
-}
-
-func SetDefaults_RBDVolumeSource(obj *RBDVolumeSource) {
- if obj.RBDPool == "" {
- obj.RBDPool = "rbd"
- }
- if obj.RadosUser == "" {
- obj.RadosUser = "admin"
- }
- if obj.Keyring == "" {
- obj.Keyring = "/etc/ceph/keyring"
- }
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/doc.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/doc.go
deleted file mode 100644
index 8849ee1..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/doc.go
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
-Copyright 2015 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.
-*/
-
-// +k8s:deepcopy-gen=package,register
-// +k8s:conversion-gen=k8s.io/kubernetes/pkg/api
-
-// Package v1 is the v1 version of the API.
-package v1
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.pb.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.pb.go
deleted file mode 100644
index 16ac125..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.pb.go
+++ /dev/null
@@ -1,34797 +0,0 @@
-/*
-Copyright 2016 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 protoc-gen-gogo.
-// source: k8s.io/kubernetes/pkg/api/v1/generated.proto
-// DO NOT EDIT!
-
-/*
- Package v1 is a generated protocol buffer package.
-
- It is generated from these files:
- k8s.io/kubernetes/pkg/api/v1/generated.proto
-
- It has these top-level messages:
- AWSElasticBlockStoreVolumeSource
- Affinity
- AttachedVolume
- AzureFileVolumeSource
- Binding
- Capabilities
- CephFSVolumeSource
- CinderVolumeSource
- ComponentCondition
- ComponentStatus
- ComponentStatusList
- ConfigMap
- ConfigMapKeySelector
- ConfigMapList
- ConfigMapVolumeSource
- Container
- ContainerImage
- ContainerPort
- ContainerState
- ContainerStateRunning
- ContainerStateTerminated
- ContainerStateWaiting
- ContainerStatus
- DaemonEndpoint
- DeleteOptions
- DownwardAPIVolumeFile
- DownwardAPIVolumeSource
- EmptyDirVolumeSource
- EndpointAddress
- EndpointPort
- EndpointSubset
- Endpoints
- EndpointsList
- EnvVar
- EnvVarSource
- Event
- EventList
- EventSource
- ExecAction
- ExportOptions
- FCVolumeSource
- FlexVolumeSource
- FlockerVolumeSource
- GCEPersistentDiskVolumeSource
- GitRepoVolumeSource
- GlusterfsVolumeSource
- HTTPGetAction
- HTTPHeader
- Handler
- HostPathVolumeSource
- ISCSIVolumeSource
- KeyToPath
- Lifecycle
- LimitRange
- LimitRangeItem
- LimitRangeList
- LimitRangeSpec
- List
- ListOptions
- LoadBalancerIngress
- LoadBalancerStatus
- LocalObjectReference
- NFSVolumeSource
- Namespace
- NamespaceList
- NamespaceSpec
- NamespaceStatus
- Node
- NodeAddress
- NodeAffinity
- NodeCondition
- NodeDaemonEndpoints
- NodeList
- NodeProxyOptions
- NodeSelector
- NodeSelectorRequirement
- NodeSelectorTerm
- NodeSpec
- NodeStatus
- NodeSystemInfo
- ObjectFieldSelector
- ObjectMeta
- ObjectReference
- OwnerReference
- PersistentVolume
- PersistentVolumeClaim
- PersistentVolumeClaimList
- PersistentVolumeClaimSpec
- PersistentVolumeClaimStatus
- PersistentVolumeClaimVolumeSource
- PersistentVolumeList
- PersistentVolumeSource
- PersistentVolumeSpec
- PersistentVolumeStatus
- Pod
- PodAffinity
- PodAffinityTerm
- PodAntiAffinity
- PodAttachOptions
- PodCondition
- PodExecOptions
- PodList
- PodLogOptions
- PodProxyOptions
- PodSecurityContext
- PodSpec
- PodStatus
- PodStatusResult
- PodTemplate
- PodTemplateList
- PodTemplateSpec
- Preconditions
- PreferredSchedulingTerm
- Probe
- RBDVolumeSource
- RangeAllocation
- ReplicationController
- ReplicationControllerList
- ReplicationControllerSpec
- ReplicationControllerStatus
- ResourceFieldSelector
- ResourceQuota
- ResourceQuotaList
- ResourceQuotaSpec
- ResourceQuotaStatus
- ResourceRequirements
- SELinuxOptions
- Secret
- SecretKeySelector
- SecretList
- SecretVolumeSource
- SecurityContext
- SerializedReference
- Service
- ServiceAccount
- ServiceAccountList
- ServiceList
- ServicePort
- ServiceProxyOptions
- ServiceSpec
- ServiceStatus
- TCPSocketAction
- Taint
- Toleration
- Volume
- VolumeMount
- VolumeSource
- VsphereVirtualDiskVolumeSource
- WeightedPodAffinityTerm
-*/
-package v1
-
-import proto "github.com/gogo/protobuf/proto"
-import fmt "fmt"
-import math "math"
-
-import k8s_io_kubernetes_pkg_api_resource "k8s.io/kubernetes/pkg/api/resource"
-import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/kubernetes/pkg/api/unversioned"
-import k8s_io_kubernetes_pkg_runtime "k8s.io/kubernetes/pkg/runtime"
-
-import k8s_io_kubernetes_pkg_types "k8s.io/kubernetes/pkg/types"
-
-import io "io"
-
-// Reference imports to suppress errors if they are not otherwise used.
-var _ = proto.Marshal
-var _ = fmt.Errorf
-var _ = math.Inf
-
-func (m *AWSElasticBlockStoreVolumeSource) Reset() { *m = AWSElasticBlockStoreVolumeSource{} }
-func (m *AWSElasticBlockStoreVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*AWSElasticBlockStoreVolumeSource) ProtoMessage() {}
-
-func (m *Affinity) Reset() { *m = Affinity{} }
-func (m *Affinity) String() string { return proto.CompactTextString(m) }
-func (*Affinity) ProtoMessage() {}
-
-func (m *AttachedVolume) Reset() { *m = AttachedVolume{} }
-func (m *AttachedVolume) String() string { return proto.CompactTextString(m) }
-func (*AttachedVolume) ProtoMessage() {}
-
-func (m *AzureFileVolumeSource) Reset() { *m = AzureFileVolumeSource{} }
-func (m *AzureFileVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*AzureFileVolumeSource) ProtoMessage() {}
-
-func (m *Binding) Reset() { *m = Binding{} }
-func (m *Binding) String() string { return proto.CompactTextString(m) }
-func (*Binding) ProtoMessage() {}
-
-func (m *Capabilities) Reset() { *m = Capabilities{} }
-func (m *Capabilities) String() string { return proto.CompactTextString(m) }
-func (*Capabilities) ProtoMessage() {}
-
-func (m *CephFSVolumeSource) Reset() { *m = CephFSVolumeSource{} }
-func (m *CephFSVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*CephFSVolumeSource) ProtoMessage() {}
-
-func (m *CinderVolumeSource) Reset() { *m = CinderVolumeSource{} }
-func (m *CinderVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*CinderVolumeSource) ProtoMessage() {}
-
-func (m *ComponentCondition) Reset() { *m = ComponentCondition{} }
-func (m *ComponentCondition) String() string { return proto.CompactTextString(m) }
-func (*ComponentCondition) ProtoMessage() {}
-
-func (m *ComponentStatus) Reset() { *m = ComponentStatus{} }
-func (m *ComponentStatus) String() string { return proto.CompactTextString(m) }
-func (*ComponentStatus) ProtoMessage() {}
-
-func (m *ComponentStatusList) Reset() { *m = ComponentStatusList{} }
-func (m *ComponentStatusList) String() string { return proto.CompactTextString(m) }
-func (*ComponentStatusList) ProtoMessage() {}
-
-func (m *ConfigMap) Reset() { *m = ConfigMap{} }
-func (m *ConfigMap) String() string { return proto.CompactTextString(m) }
-func (*ConfigMap) ProtoMessage() {}
-
-func (m *ConfigMapKeySelector) Reset() { *m = ConfigMapKeySelector{} }
-func (m *ConfigMapKeySelector) String() string { return proto.CompactTextString(m) }
-func (*ConfigMapKeySelector) ProtoMessage() {}
-
-func (m *ConfigMapList) Reset() { *m = ConfigMapList{} }
-func (m *ConfigMapList) String() string { return proto.CompactTextString(m) }
-func (*ConfigMapList) ProtoMessage() {}
-
-func (m *ConfigMapVolumeSource) Reset() { *m = ConfigMapVolumeSource{} }
-func (m *ConfigMapVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*ConfigMapVolumeSource) ProtoMessage() {}
-
-func (m *Container) Reset() { *m = Container{} }
-func (m *Container) String() string { return proto.CompactTextString(m) }
-func (*Container) ProtoMessage() {}
-
-func (m *ContainerImage) Reset() { *m = ContainerImage{} }
-func (m *ContainerImage) String() string { return proto.CompactTextString(m) }
-func (*ContainerImage) ProtoMessage() {}
-
-func (m *ContainerPort) Reset() { *m = ContainerPort{} }
-func (m *ContainerPort) String() string { return proto.CompactTextString(m) }
-func (*ContainerPort) ProtoMessage() {}
-
-func (m *ContainerState) Reset() { *m = ContainerState{} }
-func (m *ContainerState) String() string { return proto.CompactTextString(m) }
-func (*ContainerState) ProtoMessage() {}
-
-func (m *ContainerStateRunning) Reset() { *m = ContainerStateRunning{} }
-func (m *ContainerStateRunning) String() string { return proto.CompactTextString(m) }
-func (*ContainerStateRunning) ProtoMessage() {}
-
-func (m *ContainerStateTerminated) Reset() { *m = ContainerStateTerminated{} }
-func (m *ContainerStateTerminated) String() string { return proto.CompactTextString(m) }
-func (*ContainerStateTerminated) ProtoMessage() {}
-
-func (m *ContainerStateWaiting) Reset() { *m = ContainerStateWaiting{} }
-func (m *ContainerStateWaiting) String() string { return proto.CompactTextString(m) }
-func (*ContainerStateWaiting) ProtoMessage() {}
-
-func (m *ContainerStatus) Reset() { *m = ContainerStatus{} }
-func (m *ContainerStatus) String() string { return proto.CompactTextString(m) }
-func (*ContainerStatus) ProtoMessage() {}
-
-func (m *DaemonEndpoint) Reset() { *m = DaemonEndpoint{} }
-func (m *DaemonEndpoint) String() string { return proto.CompactTextString(m) }
-func (*DaemonEndpoint) ProtoMessage() {}
-
-func (m *DeleteOptions) Reset() { *m = DeleteOptions{} }
-func (m *DeleteOptions) String() string { return proto.CompactTextString(m) }
-func (*DeleteOptions) ProtoMessage() {}
-
-func (m *DownwardAPIVolumeFile) Reset() { *m = DownwardAPIVolumeFile{} }
-func (m *DownwardAPIVolumeFile) String() string { return proto.CompactTextString(m) }
-func (*DownwardAPIVolumeFile) ProtoMessage() {}
-
-func (m *DownwardAPIVolumeSource) Reset() { *m = DownwardAPIVolumeSource{} }
-func (m *DownwardAPIVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*DownwardAPIVolumeSource) ProtoMessage() {}
-
-func (m *EmptyDirVolumeSource) Reset() { *m = EmptyDirVolumeSource{} }
-func (m *EmptyDirVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*EmptyDirVolumeSource) ProtoMessage() {}
-
-func (m *EndpointAddress) Reset() { *m = EndpointAddress{} }
-func (m *EndpointAddress) String() string { return proto.CompactTextString(m) }
-func (*EndpointAddress) ProtoMessage() {}
-
-func (m *EndpointPort) Reset() { *m = EndpointPort{} }
-func (m *EndpointPort) String() string { return proto.CompactTextString(m) }
-func (*EndpointPort) ProtoMessage() {}
-
-func (m *EndpointSubset) Reset() { *m = EndpointSubset{} }
-func (m *EndpointSubset) String() string { return proto.CompactTextString(m) }
-func (*EndpointSubset) ProtoMessage() {}
-
-func (m *Endpoints) Reset() { *m = Endpoints{} }
-func (m *Endpoints) String() string { return proto.CompactTextString(m) }
-func (*Endpoints) ProtoMessage() {}
-
-func (m *EndpointsList) Reset() { *m = EndpointsList{} }
-func (m *EndpointsList) String() string { return proto.CompactTextString(m) }
-func (*EndpointsList) ProtoMessage() {}
-
-func (m *EnvVar) Reset() { *m = EnvVar{} }
-func (m *EnvVar) String() string { return proto.CompactTextString(m) }
-func (*EnvVar) ProtoMessage() {}
-
-func (m *EnvVarSource) Reset() { *m = EnvVarSource{} }
-func (m *EnvVarSource) String() string { return proto.CompactTextString(m) }
-func (*EnvVarSource) ProtoMessage() {}
-
-func (m *Event) Reset() { *m = Event{} }
-func (m *Event) String() string { return proto.CompactTextString(m) }
-func (*Event) ProtoMessage() {}
-
-func (m *EventList) Reset() { *m = EventList{} }
-func (m *EventList) String() string { return proto.CompactTextString(m) }
-func (*EventList) ProtoMessage() {}
-
-func (m *EventSource) Reset() { *m = EventSource{} }
-func (m *EventSource) String() string { return proto.CompactTextString(m) }
-func (*EventSource) ProtoMessage() {}
-
-func (m *ExecAction) Reset() { *m = ExecAction{} }
-func (m *ExecAction) String() string { return proto.CompactTextString(m) }
-func (*ExecAction) ProtoMessage() {}
-
-func (m *ExportOptions) Reset() { *m = ExportOptions{} }
-func (m *ExportOptions) String() string { return proto.CompactTextString(m) }
-func (*ExportOptions) ProtoMessage() {}
-
-func (m *FCVolumeSource) Reset() { *m = FCVolumeSource{} }
-func (m *FCVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*FCVolumeSource) ProtoMessage() {}
-
-func (m *FlexVolumeSource) Reset() { *m = FlexVolumeSource{} }
-func (m *FlexVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*FlexVolumeSource) ProtoMessage() {}
-
-func (m *FlockerVolumeSource) Reset() { *m = FlockerVolumeSource{} }
-func (m *FlockerVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*FlockerVolumeSource) ProtoMessage() {}
-
-func (m *GCEPersistentDiskVolumeSource) Reset() { *m = GCEPersistentDiskVolumeSource{} }
-func (m *GCEPersistentDiskVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*GCEPersistentDiskVolumeSource) ProtoMessage() {}
-
-func (m *GitRepoVolumeSource) Reset() { *m = GitRepoVolumeSource{} }
-func (m *GitRepoVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*GitRepoVolumeSource) ProtoMessage() {}
-
-func (m *GlusterfsVolumeSource) Reset() { *m = GlusterfsVolumeSource{} }
-func (m *GlusterfsVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*GlusterfsVolumeSource) ProtoMessage() {}
-
-func (m *HTTPGetAction) Reset() { *m = HTTPGetAction{} }
-func (m *HTTPGetAction) String() string { return proto.CompactTextString(m) }
-func (*HTTPGetAction) ProtoMessage() {}
-
-func (m *HTTPHeader) Reset() { *m = HTTPHeader{} }
-func (m *HTTPHeader) String() string { return proto.CompactTextString(m) }
-func (*HTTPHeader) ProtoMessage() {}
-
-func (m *Handler) Reset() { *m = Handler{} }
-func (m *Handler) String() string { return proto.CompactTextString(m) }
-func (*Handler) ProtoMessage() {}
-
-func (m *HostPathVolumeSource) Reset() { *m = HostPathVolumeSource{} }
-func (m *HostPathVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*HostPathVolumeSource) ProtoMessage() {}
-
-func (m *ISCSIVolumeSource) Reset() { *m = ISCSIVolumeSource{} }
-func (m *ISCSIVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*ISCSIVolumeSource) ProtoMessage() {}
-
-func (m *KeyToPath) Reset() { *m = KeyToPath{} }
-func (m *KeyToPath) String() string { return proto.CompactTextString(m) }
-func (*KeyToPath) ProtoMessage() {}
-
-func (m *Lifecycle) Reset() { *m = Lifecycle{} }
-func (m *Lifecycle) String() string { return proto.CompactTextString(m) }
-func (*Lifecycle) ProtoMessage() {}
-
-func (m *LimitRange) Reset() { *m = LimitRange{} }
-func (m *LimitRange) String() string { return proto.CompactTextString(m) }
-func (*LimitRange) ProtoMessage() {}
-
-func (m *LimitRangeItem) Reset() { *m = LimitRangeItem{} }
-func (m *LimitRangeItem) String() string { return proto.CompactTextString(m) }
-func (*LimitRangeItem) ProtoMessage() {}
-
-func (m *LimitRangeList) Reset() { *m = LimitRangeList{} }
-func (m *LimitRangeList) String() string { return proto.CompactTextString(m) }
-func (*LimitRangeList) ProtoMessage() {}
-
-func (m *LimitRangeSpec) Reset() { *m = LimitRangeSpec{} }
-func (m *LimitRangeSpec) String() string { return proto.CompactTextString(m) }
-func (*LimitRangeSpec) ProtoMessage() {}
-
-func (m *List) Reset() { *m = List{} }
-func (m *List) String() string { return proto.CompactTextString(m) }
-func (*List) ProtoMessage() {}
-
-func (m *ListOptions) Reset() { *m = ListOptions{} }
-func (m *ListOptions) String() string { return proto.CompactTextString(m) }
-func (*ListOptions) ProtoMessage() {}
-
-func (m *LoadBalancerIngress) Reset() { *m = LoadBalancerIngress{} }
-func (m *LoadBalancerIngress) String() string { return proto.CompactTextString(m) }
-func (*LoadBalancerIngress) ProtoMessage() {}
-
-func (m *LoadBalancerStatus) Reset() { *m = LoadBalancerStatus{} }
-func (m *LoadBalancerStatus) String() string { return proto.CompactTextString(m) }
-func (*LoadBalancerStatus) ProtoMessage() {}
-
-func (m *LocalObjectReference) Reset() { *m = LocalObjectReference{} }
-func (m *LocalObjectReference) String() string { return proto.CompactTextString(m) }
-func (*LocalObjectReference) ProtoMessage() {}
-
-func (m *NFSVolumeSource) Reset() { *m = NFSVolumeSource{} }
-func (m *NFSVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*NFSVolumeSource) ProtoMessage() {}
-
-func (m *Namespace) Reset() { *m = Namespace{} }
-func (m *Namespace) String() string { return proto.CompactTextString(m) }
-func (*Namespace) ProtoMessage() {}
-
-func (m *NamespaceList) Reset() { *m = NamespaceList{} }
-func (m *NamespaceList) String() string { return proto.CompactTextString(m) }
-func (*NamespaceList) ProtoMessage() {}
-
-func (m *NamespaceSpec) Reset() { *m = NamespaceSpec{} }
-func (m *NamespaceSpec) String() string { return proto.CompactTextString(m) }
-func (*NamespaceSpec) ProtoMessage() {}
-
-func (m *NamespaceStatus) Reset() { *m = NamespaceStatus{} }
-func (m *NamespaceStatus) String() string { return proto.CompactTextString(m) }
-func (*NamespaceStatus) ProtoMessage() {}
-
-func (m *Node) Reset() { *m = Node{} }
-func (m *Node) String() string { return proto.CompactTextString(m) }
-func (*Node) ProtoMessage() {}
-
-func (m *NodeAddress) Reset() { *m = NodeAddress{} }
-func (m *NodeAddress) String() string { return proto.CompactTextString(m) }
-func (*NodeAddress) ProtoMessage() {}
-
-func (m *NodeAffinity) Reset() { *m = NodeAffinity{} }
-func (m *NodeAffinity) String() string { return proto.CompactTextString(m) }
-func (*NodeAffinity) ProtoMessage() {}
-
-func (m *NodeCondition) Reset() { *m = NodeCondition{} }
-func (m *NodeCondition) String() string { return proto.CompactTextString(m) }
-func (*NodeCondition) ProtoMessage() {}
-
-func (m *NodeDaemonEndpoints) Reset() { *m = NodeDaemonEndpoints{} }
-func (m *NodeDaemonEndpoints) String() string { return proto.CompactTextString(m) }
-func (*NodeDaemonEndpoints) ProtoMessage() {}
-
-func (m *NodeList) Reset() { *m = NodeList{} }
-func (m *NodeList) String() string { return proto.CompactTextString(m) }
-func (*NodeList) ProtoMessage() {}
-
-func (m *NodeProxyOptions) Reset() { *m = NodeProxyOptions{} }
-func (m *NodeProxyOptions) String() string { return proto.CompactTextString(m) }
-func (*NodeProxyOptions) ProtoMessage() {}
-
-func (m *NodeSelector) Reset() { *m = NodeSelector{} }
-func (m *NodeSelector) String() string { return proto.CompactTextString(m) }
-func (*NodeSelector) ProtoMessage() {}
-
-func (m *NodeSelectorRequirement) Reset() { *m = NodeSelectorRequirement{} }
-func (m *NodeSelectorRequirement) String() string { return proto.CompactTextString(m) }
-func (*NodeSelectorRequirement) ProtoMessage() {}
-
-func (m *NodeSelectorTerm) Reset() { *m = NodeSelectorTerm{} }
-func (m *NodeSelectorTerm) String() string { return proto.CompactTextString(m) }
-func (*NodeSelectorTerm) ProtoMessage() {}
-
-func (m *NodeSpec) Reset() { *m = NodeSpec{} }
-func (m *NodeSpec) String() string { return proto.CompactTextString(m) }
-func (*NodeSpec) ProtoMessage() {}
-
-func (m *NodeStatus) Reset() { *m = NodeStatus{} }
-func (m *NodeStatus) String() string { return proto.CompactTextString(m) }
-func (*NodeStatus) ProtoMessage() {}
-
-func (m *NodeSystemInfo) Reset() { *m = NodeSystemInfo{} }
-func (m *NodeSystemInfo) String() string { return proto.CompactTextString(m) }
-func (*NodeSystemInfo) ProtoMessage() {}
-
-func (m *ObjectFieldSelector) Reset() { *m = ObjectFieldSelector{} }
-func (m *ObjectFieldSelector) String() string { return proto.CompactTextString(m) }
-func (*ObjectFieldSelector) ProtoMessage() {}
-
-func (m *ObjectMeta) Reset() { *m = ObjectMeta{} }
-func (m *ObjectMeta) String() string { return proto.CompactTextString(m) }
-func (*ObjectMeta) ProtoMessage() {}
-
-func (m *ObjectReference) Reset() { *m = ObjectReference{} }
-func (m *ObjectReference) String() string { return proto.CompactTextString(m) }
-func (*ObjectReference) ProtoMessage() {}
-
-func (m *OwnerReference) Reset() { *m = OwnerReference{} }
-func (m *OwnerReference) String() string { return proto.CompactTextString(m) }
-func (*OwnerReference) ProtoMessage() {}
-
-func (m *PersistentVolume) Reset() { *m = PersistentVolume{} }
-func (m *PersistentVolume) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolume) ProtoMessage() {}
-
-func (m *PersistentVolumeClaim) Reset() { *m = PersistentVolumeClaim{} }
-func (m *PersistentVolumeClaim) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeClaim) ProtoMessage() {}
-
-func (m *PersistentVolumeClaimList) Reset() { *m = PersistentVolumeClaimList{} }
-func (m *PersistentVolumeClaimList) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeClaimList) ProtoMessage() {}
-
-func (m *PersistentVolumeClaimSpec) Reset() { *m = PersistentVolumeClaimSpec{} }
-func (m *PersistentVolumeClaimSpec) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeClaimSpec) ProtoMessage() {}
-
-func (m *PersistentVolumeClaimStatus) Reset() { *m = PersistentVolumeClaimStatus{} }
-func (m *PersistentVolumeClaimStatus) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeClaimStatus) ProtoMessage() {}
-
-func (m *PersistentVolumeClaimVolumeSource) Reset() { *m = PersistentVolumeClaimVolumeSource{} }
-func (m *PersistentVolumeClaimVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeClaimVolumeSource) ProtoMessage() {}
-
-func (m *PersistentVolumeList) Reset() { *m = PersistentVolumeList{} }
-func (m *PersistentVolumeList) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeList) ProtoMessage() {}
-
-func (m *PersistentVolumeSource) Reset() { *m = PersistentVolumeSource{} }
-func (m *PersistentVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeSource) ProtoMessage() {}
-
-func (m *PersistentVolumeSpec) Reset() { *m = PersistentVolumeSpec{} }
-func (m *PersistentVolumeSpec) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeSpec) ProtoMessage() {}
-
-func (m *PersistentVolumeStatus) Reset() { *m = PersistentVolumeStatus{} }
-func (m *PersistentVolumeStatus) String() string { return proto.CompactTextString(m) }
-func (*PersistentVolumeStatus) ProtoMessage() {}
-
-func (m *Pod) Reset() { *m = Pod{} }
-func (m *Pod) String() string { return proto.CompactTextString(m) }
-func (*Pod) ProtoMessage() {}
-
-func (m *PodAffinity) Reset() { *m = PodAffinity{} }
-func (m *PodAffinity) String() string { return proto.CompactTextString(m) }
-func (*PodAffinity) ProtoMessage() {}
-
-func (m *PodAffinityTerm) Reset() { *m = PodAffinityTerm{} }
-func (m *PodAffinityTerm) String() string { return proto.CompactTextString(m) }
-func (*PodAffinityTerm) ProtoMessage() {}
-
-func (m *PodAntiAffinity) Reset() { *m = PodAntiAffinity{} }
-func (m *PodAntiAffinity) String() string { return proto.CompactTextString(m) }
-func (*PodAntiAffinity) ProtoMessage() {}
-
-func (m *PodAttachOptions) Reset() { *m = PodAttachOptions{} }
-func (m *PodAttachOptions) String() string { return proto.CompactTextString(m) }
-func (*PodAttachOptions) ProtoMessage() {}
-
-func (m *PodCondition) Reset() { *m = PodCondition{} }
-func (m *PodCondition) String() string { return proto.CompactTextString(m) }
-func (*PodCondition) ProtoMessage() {}
-
-func (m *PodExecOptions) Reset() { *m = PodExecOptions{} }
-func (m *PodExecOptions) String() string { return proto.CompactTextString(m) }
-func (*PodExecOptions) ProtoMessage() {}
-
-func (m *PodList) Reset() { *m = PodList{} }
-func (m *PodList) String() string { return proto.CompactTextString(m) }
-func (*PodList) ProtoMessage() {}
-
-func (m *PodLogOptions) Reset() { *m = PodLogOptions{} }
-func (m *PodLogOptions) String() string { return proto.CompactTextString(m) }
-func (*PodLogOptions) ProtoMessage() {}
-
-func (m *PodProxyOptions) Reset() { *m = PodProxyOptions{} }
-func (m *PodProxyOptions) String() string { return proto.CompactTextString(m) }
-func (*PodProxyOptions) ProtoMessage() {}
-
-func (m *PodSecurityContext) Reset() { *m = PodSecurityContext{} }
-func (m *PodSecurityContext) String() string { return proto.CompactTextString(m) }
-func (*PodSecurityContext) ProtoMessage() {}
-
-func (m *PodSpec) Reset() { *m = PodSpec{} }
-func (m *PodSpec) String() string { return proto.CompactTextString(m) }
-func (*PodSpec) ProtoMessage() {}
-
-func (m *PodStatus) Reset() { *m = PodStatus{} }
-func (m *PodStatus) String() string { return proto.CompactTextString(m) }
-func (*PodStatus) ProtoMessage() {}
-
-func (m *PodStatusResult) Reset() { *m = PodStatusResult{} }
-func (m *PodStatusResult) String() string { return proto.CompactTextString(m) }
-func (*PodStatusResult) ProtoMessage() {}
-
-func (m *PodTemplate) Reset() { *m = PodTemplate{} }
-func (m *PodTemplate) String() string { return proto.CompactTextString(m) }
-func (*PodTemplate) ProtoMessage() {}
-
-func (m *PodTemplateList) Reset() { *m = PodTemplateList{} }
-func (m *PodTemplateList) String() string { return proto.CompactTextString(m) }
-func (*PodTemplateList) ProtoMessage() {}
-
-func (m *PodTemplateSpec) Reset() { *m = PodTemplateSpec{} }
-func (m *PodTemplateSpec) String() string { return proto.CompactTextString(m) }
-func (*PodTemplateSpec) ProtoMessage() {}
-
-func (m *Preconditions) Reset() { *m = Preconditions{} }
-func (m *Preconditions) String() string { return proto.CompactTextString(m) }
-func (*Preconditions) ProtoMessage() {}
-
-func (m *PreferredSchedulingTerm) Reset() { *m = PreferredSchedulingTerm{} }
-func (m *PreferredSchedulingTerm) String() string { return proto.CompactTextString(m) }
-func (*PreferredSchedulingTerm) ProtoMessage() {}
-
-func (m *Probe) Reset() { *m = Probe{} }
-func (m *Probe) String() string { return proto.CompactTextString(m) }
-func (*Probe) ProtoMessage() {}
-
-func (m *RBDVolumeSource) Reset() { *m = RBDVolumeSource{} }
-func (m *RBDVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*RBDVolumeSource) ProtoMessage() {}
-
-func (m *RangeAllocation) Reset() { *m = RangeAllocation{} }
-func (m *RangeAllocation) String() string { return proto.CompactTextString(m) }
-func (*RangeAllocation) ProtoMessage() {}
-
-func (m *ReplicationController) Reset() { *m = ReplicationController{} }
-func (m *ReplicationController) String() string { return proto.CompactTextString(m) }
-func (*ReplicationController) ProtoMessage() {}
-
-func (m *ReplicationControllerList) Reset() { *m = ReplicationControllerList{} }
-func (m *ReplicationControllerList) String() string { return proto.CompactTextString(m) }
-func (*ReplicationControllerList) ProtoMessage() {}
-
-func (m *ReplicationControllerSpec) Reset() { *m = ReplicationControllerSpec{} }
-func (m *ReplicationControllerSpec) String() string { return proto.CompactTextString(m) }
-func (*ReplicationControllerSpec) ProtoMessage() {}
-
-func (m *ReplicationControllerStatus) Reset() { *m = ReplicationControllerStatus{} }
-func (m *ReplicationControllerStatus) String() string { return proto.CompactTextString(m) }
-func (*ReplicationControllerStatus) ProtoMessage() {}
-
-func (m *ResourceFieldSelector) Reset() { *m = ResourceFieldSelector{} }
-func (m *ResourceFieldSelector) String() string { return proto.CompactTextString(m) }
-func (*ResourceFieldSelector) ProtoMessage() {}
-
-func (m *ResourceQuota) Reset() { *m = ResourceQuota{} }
-func (m *ResourceQuota) String() string { return proto.CompactTextString(m) }
-func (*ResourceQuota) ProtoMessage() {}
-
-func (m *ResourceQuotaList) Reset() { *m = ResourceQuotaList{} }
-func (m *ResourceQuotaList) String() string { return proto.CompactTextString(m) }
-func (*ResourceQuotaList) ProtoMessage() {}
-
-func (m *ResourceQuotaSpec) Reset() { *m = ResourceQuotaSpec{} }
-func (m *ResourceQuotaSpec) String() string { return proto.CompactTextString(m) }
-func (*ResourceQuotaSpec) ProtoMessage() {}
-
-func (m *ResourceQuotaStatus) Reset() { *m = ResourceQuotaStatus{} }
-func (m *ResourceQuotaStatus) String() string { return proto.CompactTextString(m) }
-func (*ResourceQuotaStatus) ProtoMessage() {}
-
-func (m *ResourceRequirements) Reset() { *m = ResourceRequirements{} }
-func (m *ResourceRequirements) String() string { return proto.CompactTextString(m) }
-func (*ResourceRequirements) ProtoMessage() {}
-
-func (m *SELinuxOptions) Reset() { *m = SELinuxOptions{} }
-func (m *SELinuxOptions) String() string { return proto.CompactTextString(m) }
-func (*SELinuxOptions) ProtoMessage() {}
-
-func (m *Secret) Reset() { *m = Secret{} }
-func (m *Secret) String() string { return proto.CompactTextString(m) }
-func (*Secret) ProtoMessage() {}
-
-func (m *SecretKeySelector) Reset() { *m = SecretKeySelector{} }
-func (m *SecretKeySelector) String() string { return proto.CompactTextString(m) }
-func (*SecretKeySelector) ProtoMessage() {}
-
-func (m *SecretList) Reset() { *m = SecretList{} }
-func (m *SecretList) String() string { return proto.CompactTextString(m) }
-func (*SecretList) ProtoMessage() {}
-
-func (m *SecretVolumeSource) Reset() { *m = SecretVolumeSource{} }
-func (m *SecretVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*SecretVolumeSource) ProtoMessage() {}
-
-func (m *SecurityContext) Reset() { *m = SecurityContext{} }
-func (m *SecurityContext) String() string { return proto.CompactTextString(m) }
-func (*SecurityContext) ProtoMessage() {}
-
-func (m *SerializedReference) Reset() { *m = SerializedReference{} }
-func (m *SerializedReference) String() string { return proto.CompactTextString(m) }
-func (*SerializedReference) ProtoMessage() {}
-
-func (m *Service) Reset() { *m = Service{} }
-func (m *Service) String() string { return proto.CompactTextString(m) }
-func (*Service) ProtoMessage() {}
-
-func (m *ServiceAccount) Reset() { *m = ServiceAccount{} }
-func (m *ServiceAccount) String() string { return proto.CompactTextString(m) }
-func (*ServiceAccount) ProtoMessage() {}
-
-func (m *ServiceAccountList) Reset() { *m = ServiceAccountList{} }
-func (m *ServiceAccountList) String() string { return proto.CompactTextString(m) }
-func (*ServiceAccountList) ProtoMessage() {}
-
-func (m *ServiceList) Reset() { *m = ServiceList{} }
-func (m *ServiceList) String() string { return proto.CompactTextString(m) }
-func (*ServiceList) ProtoMessage() {}
-
-func (m *ServicePort) Reset() { *m = ServicePort{} }
-func (m *ServicePort) String() string { return proto.CompactTextString(m) }
-func (*ServicePort) ProtoMessage() {}
-
-func (m *ServiceProxyOptions) Reset() { *m = ServiceProxyOptions{} }
-func (m *ServiceProxyOptions) String() string { return proto.CompactTextString(m) }
-func (*ServiceProxyOptions) ProtoMessage() {}
-
-func (m *ServiceSpec) Reset() { *m = ServiceSpec{} }
-func (m *ServiceSpec) String() string { return proto.CompactTextString(m) }
-func (*ServiceSpec) ProtoMessage() {}
-
-func (m *ServiceStatus) Reset() { *m = ServiceStatus{} }
-func (m *ServiceStatus) String() string { return proto.CompactTextString(m) }
-func (*ServiceStatus) ProtoMessage() {}
-
-func (m *TCPSocketAction) Reset() { *m = TCPSocketAction{} }
-func (m *TCPSocketAction) String() string { return proto.CompactTextString(m) }
-func (*TCPSocketAction) ProtoMessage() {}
-
-func (m *Taint) Reset() { *m = Taint{} }
-func (m *Taint) String() string { return proto.CompactTextString(m) }
-func (*Taint) ProtoMessage() {}
-
-func (m *Toleration) Reset() { *m = Toleration{} }
-func (m *Toleration) String() string { return proto.CompactTextString(m) }
-func (*Toleration) ProtoMessage() {}
-
-func (m *Volume) Reset() { *m = Volume{} }
-func (m *Volume) String() string { return proto.CompactTextString(m) }
-func (*Volume) ProtoMessage() {}
-
-func (m *VolumeMount) Reset() { *m = VolumeMount{} }
-func (m *VolumeMount) String() string { return proto.CompactTextString(m) }
-func (*VolumeMount) ProtoMessage() {}
-
-func (m *VolumeSource) Reset() { *m = VolumeSource{} }
-func (m *VolumeSource) String() string { return proto.CompactTextString(m) }
-func (*VolumeSource) ProtoMessage() {}
-
-func (m *VsphereVirtualDiskVolumeSource) Reset() { *m = VsphereVirtualDiskVolumeSource{} }
-func (m *VsphereVirtualDiskVolumeSource) String() string { return proto.CompactTextString(m) }
-func (*VsphereVirtualDiskVolumeSource) ProtoMessage() {}
-
-func (m *WeightedPodAffinityTerm) Reset() { *m = WeightedPodAffinityTerm{} }
-func (m *WeightedPodAffinityTerm) String() string { return proto.CompactTextString(m) }
-func (*WeightedPodAffinityTerm) ProtoMessage() {}
-
-func init() {
- proto.RegisterType((*AWSElasticBlockStoreVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.AWSElasticBlockStoreVolumeSource")
- proto.RegisterType((*Affinity)(nil), "k8s.io.kubernetes.pkg.api.v1.Affinity")
- proto.RegisterType((*AttachedVolume)(nil), "k8s.io.kubernetes.pkg.api.v1.AttachedVolume")
- proto.RegisterType((*AzureFileVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.AzureFileVolumeSource")
- proto.RegisterType((*Binding)(nil), "k8s.io.kubernetes.pkg.api.v1.Binding")
- proto.RegisterType((*Capabilities)(nil), "k8s.io.kubernetes.pkg.api.v1.Capabilities")
- proto.RegisterType((*CephFSVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.CephFSVolumeSource")
- proto.RegisterType((*CinderVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.CinderVolumeSource")
- proto.RegisterType((*ComponentCondition)(nil), "k8s.io.kubernetes.pkg.api.v1.ComponentCondition")
- proto.RegisterType((*ComponentStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.ComponentStatus")
- proto.RegisterType((*ComponentStatusList)(nil), "k8s.io.kubernetes.pkg.api.v1.ComponentStatusList")
- proto.RegisterType((*ConfigMap)(nil), "k8s.io.kubernetes.pkg.api.v1.ConfigMap")
- proto.RegisterType((*ConfigMapKeySelector)(nil), "k8s.io.kubernetes.pkg.api.v1.ConfigMapKeySelector")
- proto.RegisterType((*ConfigMapList)(nil), "k8s.io.kubernetes.pkg.api.v1.ConfigMapList")
- proto.RegisterType((*ConfigMapVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.ConfigMapVolumeSource")
- proto.RegisterType((*Container)(nil), "k8s.io.kubernetes.pkg.api.v1.Container")
- proto.RegisterType((*ContainerImage)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerImage")
- proto.RegisterType((*ContainerPort)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerPort")
- proto.RegisterType((*ContainerState)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerState")
- proto.RegisterType((*ContainerStateRunning)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerStateRunning")
- proto.RegisterType((*ContainerStateTerminated)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerStateTerminated")
- proto.RegisterType((*ContainerStateWaiting)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerStateWaiting")
- proto.RegisterType((*ContainerStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.ContainerStatus")
- proto.RegisterType((*DaemonEndpoint)(nil), "k8s.io.kubernetes.pkg.api.v1.DaemonEndpoint")
- proto.RegisterType((*DeleteOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.DeleteOptions")
- proto.RegisterType((*DownwardAPIVolumeFile)(nil), "k8s.io.kubernetes.pkg.api.v1.DownwardAPIVolumeFile")
- proto.RegisterType((*DownwardAPIVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.DownwardAPIVolumeSource")
- proto.RegisterType((*EmptyDirVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.EmptyDirVolumeSource")
- proto.RegisterType((*EndpointAddress)(nil), "k8s.io.kubernetes.pkg.api.v1.EndpointAddress")
- proto.RegisterType((*EndpointPort)(nil), "k8s.io.kubernetes.pkg.api.v1.EndpointPort")
- proto.RegisterType((*EndpointSubset)(nil), "k8s.io.kubernetes.pkg.api.v1.EndpointSubset")
- proto.RegisterType((*Endpoints)(nil), "k8s.io.kubernetes.pkg.api.v1.Endpoints")
- proto.RegisterType((*EndpointsList)(nil), "k8s.io.kubernetes.pkg.api.v1.EndpointsList")
- proto.RegisterType((*EnvVar)(nil), "k8s.io.kubernetes.pkg.api.v1.EnvVar")
- proto.RegisterType((*EnvVarSource)(nil), "k8s.io.kubernetes.pkg.api.v1.EnvVarSource")
- proto.RegisterType((*Event)(nil), "k8s.io.kubernetes.pkg.api.v1.Event")
- proto.RegisterType((*EventList)(nil), "k8s.io.kubernetes.pkg.api.v1.EventList")
- proto.RegisterType((*EventSource)(nil), "k8s.io.kubernetes.pkg.api.v1.EventSource")
- proto.RegisterType((*ExecAction)(nil), "k8s.io.kubernetes.pkg.api.v1.ExecAction")
- proto.RegisterType((*ExportOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.ExportOptions")
- proto.RegisterType((*FCVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.FCVolumeSource")
- proto.RegisterType((*FlexVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.FlexVolumeSource")
- proto.RegisterType((*FlockerVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.FlockerVolumeSource")
- proto.RegisterType((*GCEPersistentDiskVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.GCEPersistentDiskVolumeSource")
- proto.RegisterType((*GitRepoVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.GitRepoVolumeSource")
- proto.RegisterType((*GlusterfsVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.GlusterfsVolumeSource")
- proto.RegisterType((*HTTPGetAction)(nil), "k8s.io.kubernetes.pkg.api.v1.HTTPGetAction")
- proto.RegisterType((*HTTPHeader)(nil), "k8s.io.kubernetes.pkg.api.v1.HTTPHeader")
- proto.RegisterType((*Handler)(nil), "k8s.io.kubernetes.pkg.api.v1.Handler")
- proto.RegisterType((*HostPathVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.HostPathVolumeSource")
- proto.RegisterType((*ISCSIVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.ISCSIVolumeSource")
- proto.RegisterType((*KeyToPath)(nil), "k8s.io.kubernetes.pkg.api.v1.KeyToPath")
- proto.RegisterType((*Lifecycle)(nil), "k8s.io.kubernetes.pkg.api.v1.Lifecycle")
- proto.RegisterType((*LimitRange)(nil), "k8s.io.kubernetes.pkg.api.v1.LimitRange")
- proto.RegisterType((*LimitRangeItem)(nil), "k8s.io.kubernetes.pkg.api.v1.LimitRangeItem")
- proto.RegisterType((*LimitRangeList)(nil), "k8s.io.kubernetes.pkg.api.v1.LimitRangeList")
- proto.RegisterType((*LimitRangeSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.LimitRangeSpec")
- proto.RegisterType((*List)(nil), "k8s.io.kubernetes.pkg.api.v1.List")
- proto.RegisterType((*ListOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.ListOptions")
- proto.RegisterType((*LoadBalancerIngress)(nil), "k8s.io.kubernetes.pkg.api.v1.LoadBalancerIngress")
- proto.RegisterType((*LoadBalancerStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.LoadBalancerStatus")
- proto.RegisterType((*LocalObjectReference)(nil), "k8s.io.kubernetes.pkg.api.v1.LocalObjectReference")
- proto.RegisterType((*NFSVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.NFSVolumeSource")
- proto.RegisterType((*Namespace)(nil), "k8s.io.kubernetes.pkg.api.v1.Namespace")
- proto.RegisterType((*NamespaceList)(nil), "k8s.io.kubernetes.pkg.api.v1.NamespaceList")
- proto.RegisterType((*NamespaceSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.NamespaceSpec")
- proto.RegisterType((*NamespaceStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.NamespaceStatus")
- proto.RegisterType((*Node)(nil), "k8s.io.kubernetes.pkg.api.v1.Node")
- proto.RegisterType((*NodeAddress)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeAddress")
- proto.RegisterType((*NodeAffinity)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeAffinity")
- proto.RegisterType((*NodeCondition)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeCondition")
- proto.RegisterType((*NodeDaemonEndpoints)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeDaemonEndpoints")
- proto.RegisterType((*NodeList)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeList")
- proto.RegisterType((*NodeProxyOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeProxyOptions")
- proto.RegisterType((*NodeSelector)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeSelector")
- proto.RegisterType((*NodeSelectorRequirement)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeSelectorRequirement")
- proto.RegisterType((*NodeSelectorTerm)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeSelectorTerm")
- proto.RegisterType((*NodeSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeSpec")
- proto.RegisterType((*NodeStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeStatus")
- proto.RegisterType((*NodeSystemInfo)(nil), "k8s.io.kubernetes.pkg.api.v1.NodeSystemInfo")
- proto.RegisterType((*ObjectFieldSelector)(nil), "k8s.io.kubernetes.pkg.api.v1.ObjectFieldSelector")
- proto.RegisterType((*ObjectMeta)(nil), "k8s.io.kubernetes.pkg.api.v1.ObjectMeta")
- proto.RegisterType((*ObjectReference)(nil), "k8s.io.kubernetes.pkg.api.v1.ObjectReference")
- proto.RegisterType((*OwnerReference)(nil), "k8s.io.kubernetes.pkg.api.v1.OwnerReference")
- proto.RegisterType((*PersistentVolume)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolume")
- proto.RegisterType((*PersistentVolumeClaim)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaim")
- proto.RegisterType((*PersistentVolumeClaimList)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaimList")
- proto.RegisterType((*PersistentVolumeClaimSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaimSpec")
- proto.RegisterType((*PersistentVolumeClaimStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaimStatus")
- proto.RegisterType((*PersistentVolumeClaimVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaimVolumeSource")
- proto.RegisterType((*PersistentVolumeList)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeList")
- proto.RegisterType((*PersistentVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeSource")
- proto.RegisterType((*PersistentVolumeSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeSpec")
- proto.RegisterType((*PersistentVolumeStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.PersistentVolumeStatus")
- proto.RegisterType((*Pod)(nil), "k8s.io.kubernetes.pkg.api.v1.Pod")
- proto.RegisterType((*PodAffinity)(nil), "k8s.io.kubernetes.pkg.api.v1.PodAffinity")
- proto.RegisterType((*PodAffinityTerm)(nil), "k8s.io.kubernetes.pkg.api.v1.PodAffinityTerm")
- proto.RegisterType((*PodAntiAffinity)(nil), "k8s.io.kubernetes.pkg.api.v1.PodAntiAffinity")
- proto.RegisterType((*PodAttachOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.PodAttachOptions")
- proto.RegisterType((*PodCondition)(nil), "k8s.io.kubernetes.pkg.api.v1.PodCondition")
- proto.RegisterType((*PodExecOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.PodExecOptions")
- proto.RegisterType((*PodList)(nil), "k8s.io.kubernetes.pkg.api.v1.PodList")
- proto.RegisterType((*PodLogOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.PodLogOptions")
- proto.RegisterType((*PodProxyOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.PodProxyOptions")
- proto.RegisterType((*PodSecurityContext)(nil), "k8s.io.kubernetes.pkg.api.v1.PodSecurityContext")
- proto.RegisterType((*PodSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.PodSpec")
- proto.RegisterType((*PodStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.PodStatus")
- proto.RegisterType((*PodStatusResult)(nil), "k8s.io.kubernetes.pkg.api.v1.PodStatusResult")
- proto.RegisterType((*PodTemplate)(nil), "k8s.io.kubernetes.pkg.api.v1.PodTemplate")
- proto.RegisterType((*PodTemplateList)(nil), "k8s.io.kubernetes.pkg.api.v1.PodTemplateList")
- proto.RegisterType((*PodTemplateSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec")
- proto.RegisterType((*Preconditions)(nil), "k8s.io.kubernetes.pkg.api.v1.Preconditions")
- proto.RegisterType((*PreferredSchedulingTerm)(nil), "k8s.io.kubernetes.pkg.api.v1.PreferredSchedulingTerm")
- proto.RegisterType((*Probe)(nil), "k8s.io.kubernetes.pkg.api.v1.Probe")
- proto.RegisterType((*RBDVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.RBDVolumeSource")
- proto.RegisterType((*RangeAllocation)(nil), "k8s.io.kubernetes.pkg.api.v1.RangeAllocation")
- proto.RegisterType((*ReplicationController)(nil), "k8s.io.kubernetes.pkg.api.v1.ReplicationController")
- proto.RegisterType((*ReplicationControllerList)(nil), "k8s.io.kubernetes.pkg.api.v1.ReplicationControllerList")
- proto.RegisterType((*ReplicationControllerSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.ReplicationControllerSpec")
- proto.RegisterType((*ReplicationControllerStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.ReplicationControllerStatus")
- proto.RegisterType((*ResourceFieldSelector)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceFieldSelector")
- proto.RegisterType((*ResourceQuota)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceQuota")
- proto.RegisterType((*ResourceQuotaList)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceQuotaList")
- proto.RegisterType((*ResourceQuotaSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceQuotaSpec")
- proto.RegisterType((*ResourceQuotaStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceQuotaStatus")
- proto.RegisterType((*ResourceRequirements)(nil), "k8s.io.kubernetes.pkg.api.v1.ResourceRequirements")
- proto.RegisterType((*SELinuxOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.SELinuxOptions")
- proto.RegisterType((*Secret)(nil), "k8s.io.kubernetes.pkg.api.v1.Secret")
- proto.RegisterType((*SecretKeySelector)(nil), "k8s.io.kubernetes.pkg.api.v1.SecretKeySelector")
- proto.RegisterType((*SecretList)(nil), "k8s.io.kubernetes.pkg.api.v1.SecretList")
- proto.RegisterType((*SecretVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.SecretVolumeSource")
- proto.RegisterType((*SecurityContext)(nil), "k8s.io.kubernetes.pkg.api.v1.SecurityContext")
- proto.RegisterType((*SerializedReference)(nil), "k8s.io.kubernetes.pkg.api.v1.SerializedReference")
- proto.RegisterType((*Service)(nil), "k8s.io.kubernetes.pkg.api.v1.Service")
- proto.RegisterType((*ServiceAccount)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceAccount")
- proto.RegisterType((*ServiceAccountList)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceAccountList")
- proto.RegisterType((*ServiceList)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceList")
- proto.RegisterType((*ServicePort)(nil), "k8s.io.kubernetes.pkg.api.v1.ServicePort")
- proto.RegisterType((*ServiceProxyOptions)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceProxyOptions")
- proto.RegisterType((*ServiceSpec)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceSpec")
- proto.RegisterType((*ServiceStatus)(nil), "k8s.io.kubernetes.pkg.api.v1.ServiceStatus")
- proto.RegisterType((*TCPSocketAction)(nil), "k8s.io.kubernetes.pkg.api.v1.TCPSocketAction")
- proto.RegisterType((*Taint)(nil), "k8s.io.kubernetes.pkg.api.v1.Taint")
- proto.RegisterType((*Toleration)(nil), "k8s.io.kubernetes.pkg.api.v1.Toleration")
- proto.RegisterType((*Volume)(nil), "k8s.io.kubernetes.pkg.api.v1.Volume")
- proto.RegisterType((*VolumeMount)(nil), "k8s.io.kubernetes.pkg.api.v1.VolumeMount")
- proto.RegisterType((*VolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.VolumeSource")
- proto.RegisterType((*VsphereVirtualDiskVolumeSource)(nil), "k8s.io.kubernetes.pkg.api.v1.VsphereVirtualDiskVolumeSource")
- proto.RegisterType((*WeightedPodAffinityTerm)(nil), "k8s.io.kubernetes.pkg.api.v1.WeightedPodAffinityTerm")
-}
-func (m *AWSElasticBlockStoreVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *AWSElasticBlockStoreVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.VolumeID)))
- i += copy(data[i:], m.VolumeID)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Partition))
- data[i] = 0x20
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *Affinity) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Affinity) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.NodeAffinity != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.NodeAffinity.Size()))
- n1, err := m.NodeAffinity.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n1
- }
- if m.PodAffinity != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PodAffinity.Size()))
- n2, err := m.PodAffinity.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n2
- }
- if m.PodAntiAffinity != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PodAntiAffinity.Size()))
- n3, err := m.PodAntiAffinity.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n3
- }
- return i, nil
-}
-
-func (m *AttachedVolume) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *AttachedVolume) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.DevicePath)))
- i += copy(data[i:], m.DevicePath)
- return i, nil
-}
-
-func (m *AzureFileVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *AzureFileVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SecretName)))
- i += copy(data[i:], m.SecretName)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ShareName)))
- i += copy(data[i:], m.ShareName)
- data[i] = 0x18
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *Binding) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Binding) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n4, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n4
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Target.Size()))
- n5, err := m.Target.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n5
- return i, nil
-}
-
-func (m *Capabilities) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Capabilities) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Add) > 0 {
- for _, s := range m.Add {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if len(m.Drop) > 0 {
- for _, s := range m.Drop {
- data[i] = 0x12
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *CephFSVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *CephFSVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Monitors) > 0 {
- for _, s := range m.Monitors {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.User)))
- i += copy(data[i:], m.User)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SecretFile)))
- i += copy(data[i:], m.SecretFile)
- if m.SecretRef != nil {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size()))
- n6, err := m.SecretRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n6
- }
- data[i] = 0x30
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *CinderVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *CinderVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.VolumeID)))
- i += copy(data[i:], m.VolumeID)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x18
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *ComponentCondition) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ComponentCondition) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Status)))
- i += copy(data[i:], m.Status)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Error)))
- i += copy(data[i:], m.Error)
- return i, nil
-}
-
-func (m *ComponentStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ComponentStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n7, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n7
- if len(m.Conditions) > 0 {
- for _, msg := range m.Conditions {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ComponentStatusList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ComponentStatusList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n8, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n8
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ConfigMap) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ConfigMap) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n9, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n9
- if len(m.Data) > 0 {
- for k := range m.Data {
- data[i] = 0x12
- i++
- v := m.Data[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- return i, nil
-}
-
-func (m *ConfigMapKeySelector) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ConfigMapKeySelector) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size()))
- n10, err := m.LocalObjectReference.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n10
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- return i, nil
-}
-
-func (m *ConfigMapList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ConfigMapList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n11, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n11
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ConfigMapVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ConfigMapVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size()))
- n12, err := m.LocalObjectReference.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n12
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *Container) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Container) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Image)))
- i += copy(data[i:], m.Image)
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- data[i] = 0x1a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if len(m.Args) > 0 {
- for _, s := range m.Args {
- data[i] = 0x22
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.WorkingDir)))
- i += copy(data[i:], m.WorkingDir)
- if len(m.Ports) > 0 {
- for _, msg := range m.Ports {
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Env) > 0 {
- for _, msg := range m.Env {
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Resources.Size()))
- n13, err := m.Resources.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n13
- if len(m.VolumeMounts) > 0 {
- for _, msg := range m.VolumeMounts {
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if m.LivenessProbe != nil {
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LivenessProbe.Size()))
- n14, err := m.LivenessProbe.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n14
- }
- if m.ReadinessProbe != nil {
- data[i] = 0x5a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ReadinessProbe.Size()))
- n15, err := m.ReadinessProbe.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n15
- }
- if m.Lifecycle != nil {
- data[i] = 0x62
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Lifecycle.Size()))
- n16, err := m.Lifecycle.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n16
- }
- data[i] = 0x6a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.TerminationMessagePath)))
- i += copy(data[i:], m.TerminationMessagePath)
- data[i] = 0x72
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ImagePullPolicy)))
- i += copy(data[i:], m.ImagePullPolicy)
- if m.SecurityContext != nil {
- data[i] = 0x7a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecurityContext.Size()))
- n17, err := m.SecurityContext.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n17
- }
- data[i] = 0x80
- i++
- data[i] = 0x1
- i++
- if m.Stdin {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x88
- i++
- data[i] = 0x1
- i++
- if m.StdinOnce {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x90
- i++
- data[i] = 0x1
- i++
- if m.TTY {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *ContainerImage) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerImage) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Names) > 0 {
- for _, s := range m.Names {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SizeBytes))
- return i, nil
-}
-
-func (m *ContainerPort) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerPort) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.HostPort))
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ContainerPort))
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Protocol)))
- i += copy(data[i:], m.Protocol)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.HostIP)))
- i += copy(data[i:], m.HostIP)
- return i, nil
-}
-
-func (m *ContainerState) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerState) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.Waiting != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Waiting.Size()))
- n18, err := m.Waiting.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n18
- }
- if m.Running != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Running.Size()))
- n19, err := m.Running.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n19
- }
- if m.Terminated != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Terminated.Size()))
- n20, err := m.Terminated.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n20
- }
- return i, nil
-}
-
-func (m *ContainerStateRunning) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerStateRunning) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.StartedAt.Size()))
- n21, err := m.StartedAt.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n21
- return i, nil
-}
-
-func (m *ContainerStateTerminated) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerStateTerminated) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ExitCode))
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Signal))
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.StartedAt.Size()))
- n22, err := m.StartedAt.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n22
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FinishedAt.Size()))
- n23, err := m.FinishedAt.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n23
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ContainerID)))
- i += copy(data[i:], m.ContainerID)
- return i, nil
-}
-
-func (m *ContainerStateWaiting) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerStateWaiting) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- return i, nil
-}
-
-func (m *ContainerStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ContainerStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.State.Size()))
- n24, err := m.State.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n24
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastTerminationState.Size()))
- n25, err := m.LastTerminationState.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n25
- data[i] = 0x20
- i++
- if m.Ready {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(m.RestartCount))
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Image)))
- i += copy(data[i:], m.Image)
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ImageID)))
- i += copy(data[i:], m.ImageID)
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ContainerID)))
- i += copy(data[i:], m.ContainerID)
- return i, nil
-}
-
-func (m *DaemonEndpoint) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *DaemonEndpoint) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Port))
- return i, nil
-}
-
-func (m *DeleteOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *DeleteOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.GracePeriodSeconds != nil {
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.GracePeriodSeconds))
- }
- if m.Preconditions != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Preconditions.Size()))
- n26, err := m.Preconditions.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n26
- }
- if m.OrphanDependents != nil {
- data[i] = 0x18
- i++
- if *m.OrphanDependents {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- return i, nil
-}
-
-func (m *DownwardAPIVolumeFile) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *DownwardAPIVolumeFile) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- if m.FieldRef != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FieldRef.Size()))
- n27, err := m.FieldRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n27
- }
- if m.ResourceFieldRef != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ResourceFieldRef.Size()))
- n28, err := m.ResourceFieldRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n28
- }
- return i, nil
-}
-
-func (m *DownwardAPIVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *DownwardAPIVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *EmptyDirVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EmptyDirVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Medium)))
- i += copy(data[i:], m.Medium)
- return i, nil
-}
-
-func (m *EndpointAddress) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EndpointAddress) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.IP)))
- i += copy(data[i:], m.IP)
- if m.TargetRef != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.TargetRef.Size()))
- n29, err := m.TargetRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n29
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Hostname)))
- i += copy(data[i:], m.Hostname)
- return i, nil
-}
-
-func (m *EndpointPort) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EndpointPort) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Port))
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Protocol)))
- i += copy(data[i:], m.Protocol)
- return i, nil
-}
-
-func (m *EndpointSubset) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EndpointSubset) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Addresses) > 0 {
- for _, msg := range m.Addresses {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.NotReadyAddresses) > 0 {
- for _, msg := range m.NotReadyAddresses {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Ports) > 0 {
- for _, msg := range m.Ports {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *Endpoints) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Endpoints) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n30, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n30
- if len(m.Subsets) > 0 {
- for _, msg := range m.Subsets {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *EndpointsList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EndpointsList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n31, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n31
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *EnvVar) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EnvVar) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Value)))
- i += copy(data[i:], m.Value)
- if m.ValueFrom != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ValueFrom.Size()))
- n32, err := m.ValueFrom.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n32
- }
- return i, nil
-}
-
-func (m *EnvVarSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EnvVarSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.FieldRef != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FieldRef.Size()))
- n33, err := m.FieldRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n33
- }
- if m.ResourceFieldRef != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ResourceFieldRef.Size()))
- n34, err := m.ResourceFieldRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n34
- }
- if m.ConfigMapKeyRef != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ConfigMapKeyRef.Size()))
- n35, err := m.ConfigMapKeyRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n35
- }
- if m.SecretKeyRef != nil {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecretKeyRef.Size()))
- n36, err := m.SecretKeyRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n36
- }
- return i, nil
-}
-
-func (m *Event) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Event) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n37, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n37
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.InvolvedObject.Size()))
- n38, err := m.InvolvedObject.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n38
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Source.Size()))
- n39, err := m.Source.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n39
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FirstTimestamp.Size()))
- n40, err := m.FirstTimestamp.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n40
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastTimestamp.Size()))
- n41, err := m.LastTimestamp.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n41
- data[i] = 0x40
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Count))
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- return i, nil
-}
-
-func (m *EventList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EventList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n42, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n42
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *EventSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *EventSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Component)))
- i += copy(data[i:], m.Component)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Host)))
- i += copy(data[i:], m.Host)
- return i, nil
-}
-
-func (m *ExecAction) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ExecAction) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *ExportOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ExportOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- if m.Export {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x10
- i++
- if m.Exact {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *FCVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *FCVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.TargetWWNs) > 0 {
- for _, s := range m.TargetWWNs {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if m.Lun != nil {
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.Lun))
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x20
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *FlexVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *FlexVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Driver)))
- i += copy(data[i:], m.Driver)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- if m.SecretRef != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size()))
- n43, err := m.SecretRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n43
- }
- data[i] = 0x20
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- if len(m.Options) > 0 {
- for k := range m.Options {
- data[i] = 0x2a
- i++
- v := m.Options[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- return i, nil
-}
-
-func (m *FlockerVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *FlockerVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.DatasetName)))
- i += copy(data[i:], m.DatasetName)
- return i, nil
-}
-
-func (m *GCEPersistentDiskVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *GCEPersistentDiskVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.PDName)))
- i += copy(data[i:], m.PDName)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Partition))
- data[i] = 0x20
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *GitRepoVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *GitRepoVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Repository)))
- i += copy(data[i:], m.Repository)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Revision)))
- i += copy(data[i:], m.Revision)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Directory)))
- i += copy(data[i:], m.Directory)
- return i, nil
-}
-
-func (m *GlusterfsVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *GlusterfsVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.EndpointsName)))
- i += copy(data[i:], m.EndpointsName)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- data[i] = 0x18
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *HTTPGetAction) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *HTTPGetAction) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Port.Size()))
- n44, err := m.Port.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n44
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Host)))
- i += copy(data[i:], m.Host)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Scheme)))
- i += copy(data[i:], m.Scheme)
- if len(m.HTTPHeaders) > 0 {
- for _, msg := range m.HTTPHeaders {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *HTTPHeader) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *HTTPHeader) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Value)))
- i += copy(data[i:], m.Value)
- return i, nil
-}
-
-func (m *Handler) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Handler) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.Exec != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Exec.Size()))
- n45, err := m.Exec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n45
- }
- if m.HTTPGet != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.HTTPGet.Size()))
- n46, err := m.HTTPGet.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n46
- }
- if m.TCPSocket != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.TCPSocket.Size()))
- n47, err := m.TCPSocket.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n47
- }
- return i, nil
-}
-
-func (m *HostPathVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *HostPathVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- return i, nil
-}
-
-func (m *ISCSIVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ISCSIVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.TargetPortal)))
- i += copy(data[i:], m.TargetPortal)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.IQN)))
- i += copy(data[i:], m.IQN)
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Lun))
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ISCSIInterface)))
- i += copy(data[i:], m.ISCSIInterface)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x30
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *KeyToPath) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *KeyToPath) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- return i, nil
-}
-
-func (m *Lifecycle) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Lifecycle) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.PostStart != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PostStart.Size()))
- n48, err := m.PostStart.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n48
- }
- if m.PreStop != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PreStop.Size()))
- n49, err := m.PreStop.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n49
- }
- return i, nil
-}
-
-func (m *LimitRange) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LimitRange) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n50, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n50
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n51, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n51
- return i, nil
-}
-
-func (m *LimitRangeItem) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LimitRangeItem) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- if len(m.Max) > 0 {
- for k := range m.Max {
- data[i] = 0x12
- i++
- v := m.Max[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n52, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n52
- }
- }
- if len(m.Min) > 0 {
- for k := range m.Min {
- data[i] = 0x1a
- i++
- v := m.Min[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n53, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n53
- }
- }
- if len(m.Default) > 0 {
- for k := range m.Default {
- data[i] = 0x22
- i++
- v := m.Default[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n54, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n54
- }
- }
- if len(m.DefaultRequest) > 0 {
- for k := range m.DefaultRequest {
- data[i] = 0x2a
- i++
- v := m.DefaultRequest[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n55, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n55
- }
- }
- if len(m.MaxLimitRequestRatio) > 0 {
- for k := range m.MaxLimitRequestRatio {
- data[i] = 0x32
- i++
- v := m.MaxLimitRequestRatio[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n56, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n56
- }
- }
- return i, nil
-}
-
-func (m *LimitRangeList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LimitRangeList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n57, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n57
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *LimitRangeSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LimitRangeSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Limits) > 0 {
- for _, msg := range m.Limits {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *List) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *List) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n58, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n58
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ListOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ListOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.LabelSelector)))
- i += copy(data[i:], m.LabelSelector)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FieldSelector)))
- i += copy(data[i:], m.FieldSelector)
- data[i] = 0x18
- i++
- if m.Watch {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion)))
- i += copy(data[i:], m.ResourceVersion)
- if m.TimeoutSeconds != nil {
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.TimeoutSeconds))
- }
- return i, nil
-}
-
-func (m *LoadBalancerIngress) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LoadBalancerIngress) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.IP)))
- i += copy(data[i:], m.IP)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Hostname)))
- i += copy(data[i:], m.Hostname)
- return i, nil
-}
-
-func (m *LoadBalancerStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LoadBalancerStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Ingress) > 0 {
- for _, msg := range m.Ingress {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *LocalObjectReference) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *LocalObjectReference) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- return i, nil
-}
-
-func (m *NFSVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NFSVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Server)))
- i += copy(data[i:], m.Server)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- data[i] = 0x18
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *Namespace) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Namespace) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n59, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n59
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n60, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n60
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n61, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n61
- return i, nil
-}
-
-func (m *NamespaceList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NamespaceList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n62, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n62
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NamespaceSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NamespaceSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Finalizers) > 0 {
- for _, s := range m.Finalizers {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *NamespaceStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NamespaceStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Phase)))
- i += copy(data[i:], m.Phase)
- return i, nil
-}
-
-func (m *Node) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Node) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n63, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n63
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n64, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n64
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n65, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n65
- return i, nil
-}
-
-func (m *NodeAddress) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeAddress) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Address)))
- i += copy(data[i:], m.Address)
- return i, nil
-}
-
-func (m *NodeAffinity) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeAffinity) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.RequiredDuringSchedulingIgnoredDuringExecution.Size()))
- n66, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n66
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NodeCondition) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeCondition) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Status)))
- i += copy(data[i:], m.Status)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastHeartbeatTime.Size()))
- n67, err := m.LastHeartbeatTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n67
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size()))
- n68, err := m.LastTransitionTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n68
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- return i, nil
-}
-
-func (m *NodeDaemonEndpoints) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeDaemonEndpoints) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.KubeletEndpoint.Size()))
- n69, err := m.KubeletEndpoint.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n69
- return i, nil
-}
-
-func (m *NodeList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n70, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n70
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NodeProxyOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeProxyOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- return i, nil
-}
-
-func (m *NodeSelector) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeSelector) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.NodeSelectorTerms) > 0 {
- for _, msg := range m.NodeSelectorTerms {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NodeSelectorRequirement) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeSelectorRequirement) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Operator)))
- i += copy(data[i:], m.Operator)
- if len(m.Values) > 0 {
- for _, s := range m.Values {
- data[i] = 0x1a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *NodeSelectorTerm) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeSelectorTerm) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.MatchExpressions) > 0 {
- for _, msg := range m.MatchExpressions {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NodeSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.PodCIDR)))
- i += copy(data[i:], m.PodCIDR)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ExternalID)))
- i += copy(data[i:], m.ExternalID)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ProviderID)))
- i += copy(data[i:], m.ProviderID)
- data[i] = 0x20
- i++
- if m.Unschedulable {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *NodeStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Capacity) > 0 {
- for k := range m.Capacity {
- data[i] = 0xa
- i++
- v := m.Capacity[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n71, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n71
- }
- }
- if len(m.Allocatable) > 0 {
- for k := range m.Allocatable {
- data[i] = 0x12
- i++
- v := m.Allocatable[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n72, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n72
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Phase)))
- i += copy(data[i:], m.Phase)
- if len(m.Conditions) > 0 {
- for _, msg := range m.Conditions {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Addresses) > 0 {
- for _, msg := range m.Addresses {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(m.DaemonEndpoints.Size()))
- n73, err := m.DaemonEndpoints.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n73
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.NodeInfo.Size()))
- n74, err := m.NodeInfo.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n74
- if len(m.Images) > 0 {
- for _, msg := range m.Images {
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.VolumesInUse) > 0 {
- for _, s := range m.VolumesInUse {
- data[i] = 0x4a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if len(m.VolumesAttached) > 0 {
- for _, msg := range m.VolumesAttached {
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *NodeSystemInfo) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *NodeSystemInfo) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.MachineID)))
- i += copy(data[i:], m.MachineID)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SystemUUID)))
- i += copy(data[i:], m.SystemUUID)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.BootID)))
- i += copy(data[i:], m.BootID)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.KernelVersion)))
- i += copy(data[i:], m.KernelVersion)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.OSImage)))
- i += copy(data[i:], m.OSImage)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ContainerRuntimeVersion)))
- i += copy(data[i:], m.ContainerRuntimeVersion)
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.KubeletVersion)))
- i += copy(data[i:], m.KubeletVersion)
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.KubeProxyVersion)))
- i += copy(data[i:], m.KubeProxyVersion)
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.OperatingSystem)))
- i += copy(data[i:], m.OperatingSystem)
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Architecture)))
- i += copy(data[i:], m.Architecture)
- return i, nil
-}
-
-func (m *ObjectFieldSelector) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ObjectFieldSelector) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion)))
- i += copy(data[i:], m.APIVersion)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FieldPath)))
- i += copy(data[i:], m.FieldPath)
- return i, nil
-}
-
-func (m *ObjectMeta) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ObjectMeta) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.GenerateName)))
- i += copy(data[i:], m.GenerateName)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Namespace)))
- i += copy(data[i:], m.Namespace)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SelfLink)))
- i += copy(data[i:], m.SelfLink)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.UID)))
- i += copy(data[i:], m.UID)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion)))
- i += copy(data[i:], m.ResourceVersion)
- data[i] = 0x38
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Generation))
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(m.CreationTimestamp.Size()))
- n75, err := m.CreationTimestamp.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n75
- if m.DeletionTimestamp != nil {
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.DeletionTimestamp.Size()))
- n76, err := m.DeletionTimestamp.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n76
- }
- if m.DeletionGracePeriodSeconds != nil {
- data[i] = 0x50
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.DeletionGracePeriodSeconds))
- }
- if len(m.Labels) > 0 {
- for k := range m.Labels {
- data[i] = 0x5a
- i++
- v := m.Labels[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- if len(m.Annotations) > 0 {
- for k := range m.Annotations {
- data[i] = 0x62
- i++
- v := m.Annotations[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- if len(m.OwnerReferences) > 0 {
- for _, msg := range m.OwnerReferences {
- data[i] = 0x6a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Finalizers) > 0 {
- for _, s := range m.Finalizers {
- data[i] = 0x72
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *ObjectReference) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ObjectReference) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Kind)))
- i += copy(data[i:], m.Kind)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Namespace)))
- i += copy(data[i:], m.Namespace)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.UID)))
- i += copy(data[i:], m.UID)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion)))
- i += copy(data[i:], m.APIVersion)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion)))
- i += copy(data[i:], m.ResourceVersion)
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FieldPath)))
- i += copy(data[i:], m.FieldPath)
- return i, nil
-}
-
-func (m *OwnerReference) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *OwnerReference) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Kind)))
- i += copy(data[i:], m.Kind)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.UID)))
- i += copy(data[i:], m.UID)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion)))
- i += copy(data[i:], m.APIVersion)
- if m.Controller != nil {
- data[i] = 0x30
- i++
- if *m.Controller {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- return i, nil
-}
-
-func (m *PersistentVolume) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolume) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n77, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n77
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n78, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n78
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n79, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n79
- return i, nil
-}
-
-func (m *PersistentVolumeClaim) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeClaim) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n80, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n80
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n81, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n81
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n82, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n82
- return i, nil
-}
-
-func (m *PersistentVolumeClaimList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeClaimList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n83, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n83
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PersistentVolumeClaimSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeClaimSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Resources.Size()))
- n84, err := m.Resources.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n84
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.VolumeName)))
- i += copy(data[i:], m.VolumeName)
- if m.Selector != nil {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Selector.Size()))
- n85, err := m.Selector.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n85
- }
- return i, nil
-}
-
-func (m *PersistentVolumeClaimStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeClaimStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Phase)))
- i += copy(data[i:], m.Phase)
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- data[i] = 0x12
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if len(m.Capacity) > 0 {
- for k := range m.Capacity {
- data[i] = 0x1a
- i++
- v := m.Capacity[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n86, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n86
- }
- }
- return i, nil
-}
-
-func (m *PersistentVolumeClaimVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeClaimVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ClaimName)))
- i += copy(data[i:], m.ClaimName)
- data[i] = 0x10
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *PersistentVolumeList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n87, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n87
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PersistentVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.GCEPersistentDisk != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.GCEPersistentDisk.Size()))
- n88, err := m.GCEPersistentDisk.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n88
- }
- if m.AWSElasticBlockStore != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.AWSElasticBlockStore.Size()))
- n89, err := m.AWSElasticBlockStore.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n89
- }
- if m.HostPath != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.HostPath.Size()))
- n90, err := m.HostPath.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n90
- }
- if m.Glusterfs != nil {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Glusterfs.Size()))
- n91, err := m.Glusterfs.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n91
- }
- if m.NFS != nil {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.NFS.Size()))
- n92, err := m.NFS.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n92
- }
- if m.RBD != nil {
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(m.RBD.Size()))
- n93, err := m.RBD.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n93
- }
- if m.ISCSI != nil {
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ISCSI.Size()))
- n94, err := m.ISCSI.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n94
- }
- if m.Cinder != nil {
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Cinder.Size()))
- n95, err := m.Cinder.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n95
- }
- if m.CephFS != nil {
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.CephFS.Size()))
- n96, err := m.CephFS.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n96
- }
- if m.FC != nil {
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FC.Size()))
- n97, err := m.FC.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n97
- }
- if m.Flocker != nil {
- data[i] = 0x5a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Flocker.Size()))
- n98, err := m.Flocker.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n98
- }
- if m.FlexVolume != nil {
- data[i] = 0x62
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FlexVolume.Size()))
- n99, err := m.FlexVolume.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n99
- }
- if m.AzureFile != nil {
- data[i] = 0x6a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.AzureFile.Size()))
- n100, err := m.AzureFile.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n100
- }
- if m.VsphereVolume != nil {
- data[i] = 0x72
- i++
- i = encodeVarintGenerated(data, i, uint64(m.VsphereVolume.Size()))
- n101, err := m.VsphereVolume.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n101
- }
- return i, nil
-}
-
-func (m *PersistentVolumeSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Capacity) > 0 {
- for k := range m.Capacity {
- data[i] = 0xa
- i++
- v := m.Capacity[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n102, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n102
- }
- }
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PersistentVolumeSource.Size()))
- n103, err := m.PersistentVolumeSource.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n103
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- data[i] = 0x1a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if m.ClaimRef != nil {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ClaimRef.Size()))
- n104, err := m.ClaimRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n104
- }
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.PersistentVolumeReclaimPolicy)))
- i += copy(data[i:], m.PersistentVolumeReclaimPolicy)
- return i, nil
-}
-
-func (m *PersistentVolumeStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PersistentVolumeStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Phase)))
- i += copy(data[i:], m.Phase)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- return i, nil
-}
-
-func (m *Pod) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Pod) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n105, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n105
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n106, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n106
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n107, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n107
- return i, nil
-}
-
-func (m *PodAffinity) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodAffinity) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, msg := range m.RequiredDuringSchedulingIgnoredDuringExecution {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PodAffinityTerm) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodAffinityTerm) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.LabelSelector != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LabelSelector.Size()))
- n108, err := m.LabelSelector.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n108
- }
- if len(m.Namespaces) > 0 {
- for _, s := range m.Namespaces {
- data[i] = 0x12
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.TopologyKey)))
- i += copy(data[i:], m.TopologyKey)
- return i, nil
-}
-
-func (m *PodAntiAffinity) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodAntiAffinity) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, msg := range m.RequiredDuringSchedulingIgnoredDuringExecution {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PodAttachOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodAttachOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- if m.Stdin {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x10
- i++
- if m.Stdout {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x18
- i++
- if m.Stderr {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x20
- i++
- if m.TTY {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Container)))
- i += copy(data[i:], m.Container)
- return i, nil
-}
-
-func (m *PodCondition) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodCondition) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Status)))
- i += copy(data[i:], m.Status)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastProbeTime.Size()))
- n109, err := m.LastProbeTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n109
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size()))
- n110, err := m.LastTransitionTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n110
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- return i, nil
-}
-
-func (m *PodExecOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodExecOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- if m.Stdin {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x10
- i++
- if m.Stdout {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x18
- i++
- if m.Stderr {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x20
- i++
- if m.TTY {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Container)))
- i += copy(data[i:], m.Container)
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- data[i] = 0x32
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *PodList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n111, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n111
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PodLogOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodLogOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Container)))
- i += copy(data[i:], m.Container)
- data[i] = 0x10
- i++
- if m.Follow {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x18
- i++
- if m.Previous {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- if m.SinceSeconds != nil {
- data[i] = 0x20
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.SinceSeconds))
- }
- if m.SinceTime != nil {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SinceTime.Size()))
- n112, err := m.SinceTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n112
- }
- data[i] = 0x30
- i++
- if m.Timestamps {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- if m.TailLines != nil {
- data[i] = 0x38
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.TailLines))
- }
- if m.LimitBytes != nil {
- data[i] = 0x40
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.LimitBytes))
- }
- return i, nil
-}
-
-func (m *PodProxyOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodProxyOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- return i, nil
-}
-
-func (m *PodSecurityContext) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodSecurityContext) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.SELinuxOptions != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SELinuxOptions.Size()))
- n113, err := m.SELinuxOptions.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n113
- }
- if m.RunAsUser != nil {
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.RunAsUser))
- }
- if m.RunAsNonRoot != nil {
- data[i] = 0x18
- i++
- if *m.RunAsNonRoot {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- if len(m.SupplementalGroups) > 0 {
- for _, num := range m.SupplementalGroups {
- data[i] = 0x20
- i++
- i = encodeVarintGenerated(data, i, uint64(num))
- }
- }
- if m.FSGroup != nil {
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.FSGroup))
- }
- return i, nil
-}
-
-func (m *PodSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Volumes) > 0 {
- for _, msg := range m.Volumes {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Containers) > 0 {
- for _, msg := range m.Containers {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.RestartPolicy)))
- i += copy(data[i:], m.RestartPolicy)
- if m.TerminationGracePeriodSeconds != nil {
- data[i] = 0x20
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.TerminationGracePeriodSeconds))
- }
- if m.ActiveDeadlineSeconds != nil {
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.ActiveDeadlineSeconds))
- }
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.DNSPolicy)))
- i += copy(data[i:], m.DNSPolicy)
- if len(m.NodeSelector) > 0 {
- for k := range m.NodeSelector {
- data[i] = 0x3a
- i++
- v := m.NodeSelector[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ServiceAccountName)))
- i += copy(data[i:], m.ServiceAccountName)
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.DeprecatedServiceAccount)))
- i += copy(data[i:], m.DeprecatedServiceAccount)
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.NodeName)))
- i += copy(data[i:], m.NodeName)
- data[i] = 0x58
- i++
- if m.HostNetwork {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x60
- i++
- if m.HostPID {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x68
- i++
- if m.HostIPC {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- if m.SecurityContext != nil {
- data[i] = 0x72
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecurityContext.Size()))
- n114, err := m.SecurityContext.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n114
- }
- if len(m.ImagePullSecrets) > 0 {
- for _, msg := range m.ImagePullSecrets {
- data[i] = 0x7a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- data[i] = 0x82
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Hostname)))
- i += copy(data[i:], m.Hostname)
- data[i] = 0x8a
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Subdomain)))
- i += copy(data[i:], m.Subdomain)
- return i, nil
-}
-
-func (m *PodStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Phase)))
- i += copy(data[i:], m.Phase)
- if len(m.Conditions) > 0 {
- for _, msg := range m.Conditions {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Message)))
- i += copy(data[i:], m.Message)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Reason)))
- i += copy(data[i:], m.Reason)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.HostIP)))
- i += copy(data[i:], m.HostIP)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.PodIP)))
- i += copy(data[i:], m.PodIP)
- if m.StartTime != nil {
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.StartTime.Size()))
- n115, err := m.StartTime.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n115
- }
- if len(m.ContainerStatuses) > 0 {
- for _, msg := range m.ContainerStatuses {
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PodStatusResult) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodStatusResult) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n116, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n116
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n117, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n117
- return i, nil
-}
-
-func (m *PodTemplate) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodTemplate) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n118, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n118
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Template.Size()))
- n119, err := m.Template.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n119
- return i, nil
-}
-
-func (m *PodTemplateList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodTemplateList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n120, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n120
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *PodTemplateSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PodTemplateSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n121, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n121
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n122, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n122
- return i, nil
-}
-
-func (m *Preconditions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Preconditions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.UID != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(*m.UID)))
- i += copy(data[i:], *m.UID)
- }
- return i, nil
-}
-
-func (m *PreferredSchedulingTerm) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *PreferredSchedulingTerm) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Weight))
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Preference.Size()))
- n123, err := m.Preference.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n123
- return i, nil
-}
-
-func (m *Probe) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Probe) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Handler.Size()))
- n124, err := m.Handler.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n124
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.InitialDelaySeconds))
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.TimeoutSeconds))
- data[i] = 0x20
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PeriodSeconds))
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SuccessThreshold))
- data[i] = 0x30
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FailureThreshold))
- return i, nil
-}
-
-func (m *RBDVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *RBDVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.CephMonitors) > 0 {
- for _, s := range m.CephMonitors {
- data[i] = 0xa
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.RBDImage)))
- i += copy(data[i:], m.RBDImage)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.RBDPool)))
- i += copy(data[i:], m.RBDPool)
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.RadosUser)))
- i += copy(data[i:], m.RadosUser)
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Keyring)))
- i += copy(data[i:], m.Keyring)
- if m.SecretRef != nil {
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size()))
- n125, err := m.SecretRef.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n125
- }
- data[i] = 0x40
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- return i, nil
-}
-
-func (m *RangeAllocation) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *RangeAllocation) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n126, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n126
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Range)))
- i += copy(data[i:], m.Range)
- if m.Data != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Data)))
- i += copy(data[i:], m.Data)
- }
- return i, nil
-}
-
-func (m *ReplicationController) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ReplicationController) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n127, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n127
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n128, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n128
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n129, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n129
- return i, nil
-}
-
-func (m *ReplicationControllerList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ReplicationControllerList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n130, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n130
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ReplicationControllerSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ReplicationControllerSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.Replicas != nil {
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.Replicas))
- }
- if len(m.Selector) > 0 {
- for k := range m.Selector {
- data[i] = 0x12
- i++
- v := m.Selector[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- if m.Template != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Template.Size()))
- n131, err := m.Template.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n131
- }
- return i, nil
-}
-
-func (m *ReplicationControllerStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ReplicationControllerStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Replicas))
- data[i] = 0x10
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FullyLabeledReplicas))
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObservedGeneration))
- return i, nil
-}
-
-func (m *ResourceFieldSelector) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceFieldSelector) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ContainerName)))
- i += copy(data[i:], m.ContainerName)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Resource)))
- i += copy(data[i:], m.Resource)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Divisor.Size()))
- n132, err := m.Divisor.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n132
- return i, nil
-}
-
-func (m *ResourceQuota) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceQuota) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n133, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n133
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n134, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n134
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n135, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n135
- return i, nil
-}
-
-func (m *ResourceQuotaList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceQuotaList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n136, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n136
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ResourceQuotaSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceQuotaSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Hard) > 0 {
- for k := range m.Hard {
- data[i] = 0xa
- i++
- v := m.Hard[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n137, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n137
- }
- }
- if len(m.Scopes) > 0 {
- for _, s := range m.Scopes {
- data[i] = 0x12
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *ResourceQuotaStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceQuotaStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Hard) > 0 {
- for k := range m.Hard {
- data[i] = 0xa
- i++
- v := m.Hard[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n138, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n138
- }
- }
- if len(m.Used) > 0 {
- for k := range m.Used {
- data[i] = 0x12
- i++
- v := m.Used[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n139, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n139
- }
- }
- return i, nil
-}
-
-func (m *ResourceRequirements) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ResourceRequirements) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Limits) > 0 {
- for k := range m.Limits {
- data[i] = 0xa
- i++
- v := m.Limits[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n140, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n140
- }
- }
- if len(m.Requests) > 0 {
- for k := range m.Requests {
- data[i] = 0x12
- i++
- v := m.Requests[k]
- msgSize := (&v).Size()
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64((&v).Size()))
- n141, err := (&v).MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n141
- }
- }
- return i, nil
-}
-
-func (m *SELinuxOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SELinuxOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.User)))
- i += copy(data[i:], m.User)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Role)))
- i += copy(data[i:], m.Role)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Level)))
- i += copy(data[i:], m.Level)
- return i, nil
-}
-
-func (m *Secret) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Secret) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n142, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n142
- if len(m.Data) > 0 {
- for k := range m.Data {
- data[i] = 0x12
- i++
- v := m.Data[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- if len(m.StringData) > 0 {
- for k := range m.StringData {
- data[i] = 0x22
- i++
- v := m.StringData[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- return i, nil
-}
-
-func (m *SecretKeySelector) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SecretKeySelector) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size()))
- n143, err := m.LocalObjectReference.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n143
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- return i, nil
-}
-
-func (m *SecretList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SecretList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n144, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n144
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *SecretVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SecretVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SecretName)))
- i += copy(data[i:], m.SecretName)
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *SecurityContext) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SecurityContext) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.Capabilities != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Capabilities.Size()))
- n145, err := m.Capabilities.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n145
- }
- if m.Privileged != nil {
- data[i] = 0x10
- i++
- if *m.Privileged {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- if m.SELinuxOptions != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.SELinuxOptions.Size()))
- n146, err := m.SELinuxOptions.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n146
- }
- if m.RunAsUser != nil {
- data[i] = 0x20
- i++
- i = encodeVarintGenerated(data, i, uint64(*m.RunAsUser))
- }
- if m.RunAsNonRoot != nil {
- data[i] = 0x28
- i++
- if *m.RunAsNonRoot {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- if m.ReadOnlyRootFilesystem != nil {
- data[i] = 0x30
- i++
- if *m.ReadOnlyRootFilesystem {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- }
- return i, nil
-}
-
-func (m *SerializedReference) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *SerializedReference) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Reference.Size()))
- n147, err := m.Reference.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n147
- return i, nil
-}
-
-func (m *Service) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Service) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n148, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n148
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Spec.Size()))
- n149, err := m.Spec.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n149
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Status.Size()))
- n150, err := m.Status.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n150
- return i, nil
-}
-
-func (m *ServiceAccount) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceAccount) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size()))
- n151, err := m.ObjectMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n151
- if len(m.Secrets) > 0 {
- for _, msg := range m.Secrets {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.ImagePullSecrets) > 0 {
- for _, msg := range m.ImagePullSecrets {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ServiceAccountList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceAccountList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n152, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n152
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ServiceList) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceList) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size()))
- n153, err := m.ListMeta.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n153
- if len(m.Items) > 0 {
- for _, msg := range m.Items {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- return i, nil
-}
-
-func (m *ServicePort) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServicePort) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Protocol)))
- i += copy(data[i:], m.Protocol)
- data[i] = 0x18
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Port))
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.TargetPort.Size()))
- n154, err := m.TargetPort.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n154
- data[i] = 0x28
- i++
- i = encodeVarintGenerated(data, i, uint64(m.NodePort))
- return i, nil
-}
-
-func (m *ServiceProxyOptions) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceProxyOptions) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Path)))
- i += copy(data[i:], m.Path)
- return i, nil
-}
-
-func (m *ServiceSpec) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceSpec) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if len(m.Ports) > 0 {
- for _, msg := range m.Ports {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(msg.Size()))
- n, err := msg.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n
- }
- }
- if len(m.Selector) > 0 {
- for k := range m.Selector {
- data[i] = 0x12
- i++
- v := m.Selector[k]
- mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- i = encodeVarintGenerated(data, i, uint64(mapSize))
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(k)))
- i += copy(data[i:], k)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(v)))
- i += copy(data[i:], v)
- }
- }
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.ClusterIP)))
- i += copy(data[i:], m.ClusterIP)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
- i += copy(data[i:], m.Type)
- if len(m.ExternalIPs) > 0 {
- for _, s := range m.ExternalIPs {
- data[i] = 0x2a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- if len(m.DeprecatedPublicIPs) > 0 {
- for _, s := range m.DeprecatedPublicIPs {
- data[i] = 0x32
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SessionAffinity)))
- i += copy(data[i:], m.SessionAffinity)
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.LoadBalancerIP)))
- i += copy(data[i:], m.LoadBalancerIP)
- if len(m.LoadBalancerSourceRanges) > 0 {
- for _, s := range m.LoadBalancerSourceRanges {
- data[i] = 0x4a
- i++
- l = len(s)
- for l >= 1<<7 {
- data[i] = uint8(uint64(l)&0x7f | 0x80)
- l >>= 7
- i++
- }
- data[i] = uint8(l)
- i++
- i += copy(data[i:], s)
- }
- }
- return i, nil
-}
-
-func (m *ServiceStatus) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *ServiceStatus) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.LoadBalancer.Size()))
- n155, err := m.LoadBalancer.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n155
- return i, nil
-}
-
-func (m *TCPSocketAction) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *TCPSocketAction) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Port.Size()))
- n156, err := m.Port.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n156
- return i, nil
-}
-
-func (m *Taint) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Taint) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Value)))
- i += copy(data[i:], m.Value)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Effect)))
- i += copy(data[i:], m.Effect)
- return i, nil
-}
-
-func (m *Toleration) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Toleration) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Key)))
- i += copy(data[i:], m.Key)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Operator)))
- i += copy(data[i:], m.Operator)
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Value)))
- i += copy(data[i:], m.Value)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Effect)))
- i += copy(data[i:], m.Effect)
- return i, nil
-}
-
-func (m *Volume) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *Volume) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.VolumeSource.Size()))
- n157, err := m.VolumeSource.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n157
- return i, nil
-}
-
-func (m *VolumeMount) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *VolumeMount) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.Name)))
- i += copy(data[i:], m.Name)
- data[i] = 0x10
- i++
- if m.ReadOnly {
- data[i] = 1
- } else {
- data[i] = 0
- }
- i++
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.MountPath)))
- i += copy(data[i:], m.MountPath)
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.SubPath)))
- i += copy(data[i:], m.SubPath)
- return i, nil
-}
-
-func (m *VolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *VolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- if m.HostPath != nil {
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(m.HostPath.Size()))
- n158, err := m.HostPath.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n158
- }
- if m.EmptyDir != nil {
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.EmptyDir.Size()))
- n159, err := m.EmptyDir.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n159
- }
- if m.GCEPersistentDisk != nil {
- data[i] = 0x1a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.GCEPersistentDisk.Size()))
- n160, err := m.GCEPersistentDisk.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n160
- }
- if m.AWSElasticBlockStore != nil {
- data[i] = 0x22
- i++
- i = encodeVarintGenerated(data, i, uint64(m.AWSElasticBlockStore.Size()))
- n161, err := m.AWSElasticBlockStore.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n161
- }
- if m.GitRepo != nil {
- data[i] = 0x2a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.GitRepo.Size()))
- n162, err := m.GitRepo.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n162
- }
- if m.Secret != nil {
- data[i] = 0x32
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Secret.Size()))
- n163, err := m.Secret.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n163
- }
- if m.NFS != nil {
- data[i] = 0x3a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.NFS.Size()))
- n164, err := m.NFS.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n164
- }
- if m.ISCSI != nil {
- data[i] = 0x42
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ISCSI.Size()))
- n165, err := m.ISCSI.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n165
- }
- if m.Glusterfs != nil {
- data[i] = 0x4a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Glusterfs.Size()))
- n166, err := m.Glusterfs.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n166
- }
- if m.PersistentVolumeClaim != nil {
- data[i] = 0x52
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PersistentVolumeClaim.Size()))
- n167, err := m.PersistentVolumeClaim.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n167
- }
- if m.RBD != nil {
- data[i] = 0x5a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.RBD.Size()))
- n168, err := m.RBD.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n168
- }
- if m.FlexVolume != nil {
- data[i] = 0x62
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FlexVolume.Size()))
- n169, err := m.FlexVolume.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n169
- }
- if m.Cinder != nil {
- data[i] = 0x6a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Cinder.Size()))
- n170, err := m.Cinder.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n170
- }
- if m.CephFS != nil {
- data[i] = 0x72
- i++
- i = encodeVarintGenerated(data, i, uint64(m.CephFS.Size()))
- n171, err := m.CephFS.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n171
- }
- if m.Flocker != nil {
- data[i] = 0x7a
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Flocker.Size()))
- n172, err := m.Flocker.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n172
- }
- if m.DownwardAPI != nil {
- data[i] = 0x82
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(m.DownwardAPI.Size()))
- n173, err := m.DownwardAPI.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n173
- }
- if m.FC != nil {
- data[i] = 0x8a
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(m.FC.Size()))
- n174, err := m.FC.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n174
- }
- if m.AzureFile != nil {
- data[i] = 0x92
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(m.AzureFile.Size()))
- n175, err := m.AzureFile.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n175
- }
- if m.ConfigMap != nil {
- data[i] = 0x9a
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(m.ConfigMap.Size()))
- n176, err := m.ConfigMap.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n176
- }
- if m.VsphereVolume != nil {
- data[i] = 0xa2
- i++
- data[i] = 0x1
- i++
- i = encodeVarintGenerated(data, i, uint64(m.VsphereVolume.Size()))
- n177, err := m.VsphereVolume.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n177
- }
- return i, nil
-}
-
-func (m *VsphereVirtualDiskVolumeSource) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *VsphereVirtualDiskVolumeSource) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0xa
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.VolumePath)))
- i += copy(data[i:], m.VolumePath)
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(len(m.FSType)))
- i += copy(data[i:], m.FSType)
- return i, nil
-}
-
-func (m *WeightedPodAffinityTerm) Marshal() (data []byte, err error) {
- size := m.Size()
- data = make([]byte, size)
- n, err := m.MarshalTo(data)
- if err != nil {
- return nil, err
- }
- return data[:n], nil
-}
-
-func (m *WeightedPodAffinityTerm) MarshalTo(data []byte) (int, error) {
- var i int
- _ = i
- var l int
- _ = l
- data[i] = 0x8
- i++
- i = encodeVarintGenerated(data, i, uint64(m.Weight))
- data[i] = 0x12
- i++
- i = encodeVarintGenerated(data, i, uint64(m.PodAffinityTerm.Size()))
- n178, err := m.PodAffinityTerm.MarshalTo(data[i:])
- if err != nil {
- return 0, err
- }
- i += n178
- return i, nil
-}
-
-func encodeFixed64Generated(data []byte, offset int, v uint64) int {
- data[offset] = uint8(v)
- data[offset+1] = uint8(v >> 8)
- data[offset+2] = uint8(v >> 16)
- data[offset+3] = uint8(v >> 24)
- data[offset+4] = uint8(v >> 32)
- data[offset+5] = uint8(v >> 40)
- data[offset+6] = uint8(v >> 48)
- data[offset+7] = uint8(v >> 56)
- return offset + 8
-}
-func encodeFixed32Generated(data []byte, offset int, v uint32) int {
- data[offset] = uint8(v)
- data[offset+1] = uint8(v >> 8)
- data[offset+2] = uint8(v >> 16)
- data[offset+3] = uint8(v >> 24)
- return offset + 4
-}
-func encodeVarintGenerated(data []byte, offset int, v uint64) int {
- for v >= 1<<7 {
- data[offset] = uint8(v&0x7f | 0x80)
- v >>= 7
- offset++
- }
- data[offset] = uint8(v)
- return offset + 1
-}
-func (m *AWSElasticBlockStoreVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.VolumeID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Partition))
- n += 2
- return n
-}
-
-func (m *Affinity) Size() (n int) {
- var l int
- _ = l
- if m.NodeAffinity != nil {
- l = m.NodeAffinity.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.PodAffinity != nil {
- l = m.PodAffinity.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.PodAntiAffinity != nil {
- l = m.PodAntiAffinity.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *AttachedVolume) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.DevicePath)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *AzureFileVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.SecretName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ShareName)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *Binding) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Target.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Capabilities) Size() (n int) {
- var l int
- _ = l
- if len(m.Add) > 0 {
- for _, s := range m.Add {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Drop) > 0 {
- for _, s := range m.Drop {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *CephFSVolumeSource) Size() (n int) {
- var l int
- _ = l
- if len(m.Monitors) > 0 {
- for _, s := range m.Monitors {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.User)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.SecretFile)
- n += 1 + l + sovGenerated(uint64(l))
- if m.SecretRef != nil {
- l = m.SecretRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- n += 2
- return n
-}
-
-func (m *CinderVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.VolumeID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *ComponentCondition) Size() (n int) {
- var l int
- _ = l
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Status)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Error)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ComponentStatus) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Conditions) > 0 {
- for _, e := range m.Conditions {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ComponentStatusList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ConfigMap) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Data) > 0 {
- for k, v := range m.Data {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *ConfigMapKeySelector) Size() (n int) {
- var l int
- _ = l
- l = m.LocalObjectReference.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ConfigMapList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ConfigMapVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = m.LocalObjectReference.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *Container) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Image)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Args) > 0 {
- for _, s := range m.Args {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.WorkingDir)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Ports) > 0 {
- for _, e := range m.Ports {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Env) > 0 {
- for _, e := range m.Env {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = m.Resources.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.VolumeMounts) > 0 {
- for _, e := range m.VolumeMounts {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if m.LivenessProbe != nil {
- l = m.LivenessProbe.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ReadinessProbe != nil {
- l = m.ReadinessProbe.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Lifecycle != nil {
- l = m.Lifecycle.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- l = len(m.TerminationMessagePath)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ImagePullPolicy)
- n += 1 + l + sovGenerated(uint64(l))
- if m.SecurityContext != nil {
- l = m.SecurityContext.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- n += 3
- n += 3
- n += 3
- return n
-}
-
-func (m *ContainerImage) Size() (n int) {
- var l int
- _ = l
- if len(m.Names) > 0 {
- for _, s := range m.Names {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- n += 1 + sovGenerated(uint64(m.SizeBytes))
- return n
-}
-
-func (m *ContainerPort) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.HostPort))
- n += 1 + sovGenerated(uint64(m.ContainerPort))
- l = len(m.Protocol)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.HostIP)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ContainerState) Size() (n int) {
- var l int
- _ = l
- if m.Waiting != nil {
- l = m.Waiting.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Running != nil {
- l = m.Running.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Terminated != nil {
- l = m.Terminated.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *ContainerStateRunning) Size() (n int) {
- var l int
- _ = l
- l = m.StartedAt.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ContainerStateTerminated) Size() (n int) {
- var l int
- _ = l
- n += 1 + sovGenerated(uint64(m.ExitCode))
- n += 1 + sovGenerated(uint64(m.Signal))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.StartedAt.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.FinishedAt.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ContainerID)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ContainerStateWaiting) Size() (n int) {
- var l int
- _ = l
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ContainerStatus) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.State.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastTerminationState.Size()
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- n += 1 + sovGenerated(uint64(m.RestartCount))
- l = len(m.Image)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ImageID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ContainerID)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *DaemonEndpoint) Size() (n int) {
- var l int
- _ = l
- n += 1 + sovGenerated(uint64(m.Port))
- return n
-}
-
-func (m *DeleteOptions) Size() (n int) {
- var l int
- _ = l
- if m.GracePeriodSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.GracePeriodSeconds))
- }
- if m.Preconditions != nil {
- l = m.Preconditions.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.OrphanDependents != nil {
- n += 2
- }
- return n
-}
-
-func (m *DownwardAPIVolumeFile) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- if m.FieldRef != nil {
- l = m.FieldRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ResourceFieldRef != nil {
- l = m.ResourceFieldRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *DownwardAPIVolumeSource) Size() (n int) {
- var l int
- _ = l
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *EmptyDirVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Medium)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *EndpointAddress) Size() (n int) {
- var l int
- _ = l
- l = len(m.IP)
- n += 1 + l + sovGenerated(uint64(l))
- if m.TargetRef != nil {
- l = m.TargetRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- l = len(m.Hostname)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *EndpointPort) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Port))
- l = len(m.Protocol)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *EndpointSubset) Size() (n int) {
- var l int
- _ = l
- if len(m.Addresses) > 0 {
- for _, e := range m.Addresses {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.NotReadyAddresses) > 0 {
- for _, e := range m.NotReadyAddresses {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Ports) > 0 {
- for _, e := range m.Ports {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *Endpoints) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Subsets) > 0 {
- for _, e := range m.Subsets {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *EndpointsList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *EnvVar) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Value)
- n += 1 + l + sovGenerated(uint64(l))
- if m.ValueFrom != nil {
- l = m.ValueFrom.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *EnvVarSource) Size() (n int) {
- var l int
- _ = l
- if m.FieldRef != nil {
- l = m.FieldRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ResourceFieldRef != nil {
- l = m.ResourceFieldRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ConfigMapKeyRef != nil {
- l = m.ConfigMapKeyRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.SecretKeyRef != nil {
- l = m.SecretKeyRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *Event) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.InvolvedObject.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Source.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.FirstTimestamp.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastTimestamp.Size()
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Count))
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *EventList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *EventSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Component)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Host)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ExecAction) Size() (n int) {
- var l int
- _ = l
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ExportOptions) Size() (n int) {
- var l int
- _ = l
- n += 2
- n += 2
- return n
-}
-
-func (m *FCVolumeSource) Size() (n int) {
- var l int
- _ = l
- if len(m.TargetWWNs) > 0 {
- for _, s := range m.TargetWWNs {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if m.Lun != nil {
- n += 1 + sovGenerated(uint64(*m.Lun))
- }
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *FlexVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Driver)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- if m.SecretRef != nil {
- l = m.SecretRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- n += 2
- if len(m.Options) > 0 {
- for k, v := range m.Options {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *FlockerVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.DatasetName)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *GCEPersistentDiskVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.PDName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Partition))
- n += 2
- return n
-}
-
-func (m *GitRepoVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Repository)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Revision)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Directory)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *GlusterfsVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.EndpointsName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *HTTPGetAction) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Port.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Host)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Scheme)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.HTTPHeaders) > 0 {
- for _, e := range m.HTTPHeaders {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *HTTPHeader) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Value)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Handler) Size() (n int) {
- var l int
- _ = l
- if m.Exec != nil {
- l = m.Exec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.HTTPGet != nil {
- l = m.HTTPGet.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.TCPSocket != nil {
- l = m.TCPSocket.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *HostPathVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ISCSIVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.TargetPortal)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.IQN)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Lun))
- l = len(m.ISCSIInterface)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *KeyToPath) Size() (n int) {
- var l int
- _ = l
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Lifecycle) Size() (n int) {
- var l int
- _ = l
- if m.PostStart != nil {
- l = m.PostStart.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.PreStop != nil {
- l = m.PreStop.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *LimitRange) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *LimitRangeItem) Size() (n int) {
- var l int
- _ = l
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Max) > 0 {
- for k, v := range m.Max {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Min) > 0 {
- for k, v := range m.Min {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Default) > 0 {
- for k, v := range m.Default {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.DefaultRequest) > 0 {
- for k, v := range m.DefaultRequest {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.MaxLimitRequestRatio) > 0 {
- for k, v := range m.MaxLimitRequestRatio {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *LimitRangeList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *LimitRangeSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Limits) > 0 {
- for _, e := range m.Limits {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *List) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ListOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.LabelSelector)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FieldSelector)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- l = len(m.ResourceVersion)
- n += 1 + l + sovGenerated(uint64(l))
- if m.TimeoutSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.TimeoutSeconds))
- }
- return n
-}
-
-func (m *LoadBalancerIngress) Size() (n int) {
- var l int
- _ = l
- l = len(m.IP)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Hostname)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *LoadBalancerStatus) Size() (n int) {
- var l int
- _ = l
- if len(m.Ingress) > 0 {
- for _, e := range m.Ingress {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *LocalObjectReference) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NFSVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.Server)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *Namespace) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NamespaceList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NamespaceSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Finalizers) > 0 {
- for _, s := range m.Finalizers {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NamespaceStatus) Size() (n int) {
- var l int
- _ = l
- l = len(m.Phase)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Node) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NodeAddress) Size() (n int) {
- var l int
- _ = l
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Address)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NodeAffinity) Size() (n int) {
- var l int
- _ = l
- if m.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- l = m.RequiredDuringSchedulingIgnoredDuringExecution.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, e := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeCondition) Size() (n int) {
- var l int
- _ = l
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Status)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastHeartbeatTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastTransitionTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NodeDaemonEndpoints) Size() (n int) {
- var l int
- _ = l
- l = m.KubeletEndpoint.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NodeList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeProxyOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *NodeSelector) Size() (n int) {
- var l int
- _ = l
- if len(m.NodeSelectorTerms) > 0 {
- for _, e := range m.NodeSelectorTerms {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeSelectorRequirement) Size() (n int) {
- var l int
- _ = l
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Operator)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Values) > 0 {
- for _, s := range m.Values {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeSelectorTerm) Size() (n int) {
- var l int
- _ = l
- if len(m.MatchExpressions) > 0 {
- for _, e := range m.MatchExpressions {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeSpec) Size() (n int) {
- var l int
- _ = l
- l = len(m.PodCIDR)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ExternalID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ProviderID)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *NodeStatus) Size() (n int) {
- var l int
- _ = l
- if len(m.Capacity) > 0 {
- for k, v := range m.Capacity {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Allocatable) > 0 {
- for k, v := range m.Allocatable {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- l = len(m.Phase)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Conditions) > 0 {
- for _, e := range m.Conditions {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Addresses) > 0 {
- for _, e := range m.Addresses {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = m.DaemonEndpoints.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.NodeInfo.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Images) > 0 {
- for _, e := range m.Images {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.VolumesInUse) > 0 {
- for _, s := range m.VolumesInUse {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.VolumesAttached) > 0 {
- for _, e := range m.VolumesAttached {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *NodeSystemInfo) Size() (n int) {
- var l int
- _ = l
- l = len(m.MachineID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.SystemUUID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.BootID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.KernelVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.OSImage)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ContainerRuntimeVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.KubeletVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.KubeProxyVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.OperatingSystem)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Architecture)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ObjectFieldSelector) Size() (n int) {
- var l int
- _ = l
- l = len(m.APIVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FieldPath)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ObjectMeta) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.GenerateName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Namespace)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.SelfLink)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.UID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ResourceVersion)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Generation))
- l = m.CreationTimestamp.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if m.DeletionTimestamp != nil {
- l = m.DeletionTimestamp.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.DeletionGracePeriodSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.DeletionGracePeriodSeconds))
- }
- if len(m.Labels) > 0 {
- for k, v := range m.Labels {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Annotations) > 0 {
- for k, v := range m.Annotations {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.OwnerReferences) > 0 {
- for _, e := range m.OwnerReferences {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Finalizers) > 0 {
- for _, s := range m.Finalizers {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ObjectReference) Size() (n int) {
- var l int
- _ = l
- l = len(m.Kind)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Namespace)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.UID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.APIVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.ResourceVersion)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FieldPath)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *OwnerReference) Size() (n int) {
- var l int
- _ = l
- l = len(m.Kind)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.UID)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.APIVersion)
- n += 1 + l + sovGenerated(uint64(l))
- if m.Controller != nil {
- n += 2
- }
- return n
-}
-
-func (m *PersistentVolume) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PersistentVolumeClaim) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PersistentVolumeClaimList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PersistentVolumeClaimSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = m.Resources.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.VolumeName)
- n += 1 + l + sovGenerated(uint64(l))
- if m.Selector != nil {
- l = m.Selector.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *PersistentVolumeClaimStatus) Size() (n int) {
- var l int
- _ = l
- l = len(m.Phase)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Capacity) > 0 {
- for k, v := range m.Capacity {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *PersistentVolumeClaimVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.ClaimName)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- return n
-}
-
-func (m *PersistentVolumeList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PersistentVolumeSource) Size() (n int) {
- var l int
- _ = l
- if m.GCEPersistentDisk != nil {
- l = m.GCEPersistentDisk.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.AWSElasticBlockStore != nil {
- l = m.AWSElasticBlockStore.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.HostPath != nil {
- l = m.HostPath.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Glusterfs != nil {
- l = m.Glusterfs.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.NFS != nil {
- l = m.NFS.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.RBD != nil {
- l = m.RBD.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ISCSI != nil {
- l = m.ISCSI.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Cinder != nil {
- l = m.Cinder.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.CephFS != nil {
- l = m.CephFS.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.FC != nil {
- l = m.FC.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Flocker != nil {
- l = m.Flocker.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.FlexVolume != nil {
- l = m.FlexVolume.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.AzureFile != nil {
- l = m.AzureFile.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.VsphereVolume != nil {
- l = m.VsphereVolume.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *PersistentVolumeSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Capacity) > 0 {
- for k, v := range m.Capacity {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- l = m.PersistentVolumeSource.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.AccessModes) > 0 {
- for _, s := range m.AccessModes {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if m.ClaimRef != nil {
- l = m.ClaimRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- l = len(m.PersistentVolumeReclaimPolicy)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PersistentVolumeStatus) Size() (n int) {
- var l int
- _ = l
- l = len(m.Phase)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Pod) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodAffinity) Size() (n int) {
- var l int
- _ = l
- if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, e := range m.RequiredDuringSchedulingIgnoredDuringExecution {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, e := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodAffinityTerm) Size() (n int) {
- var l int
- _ = l
- if m.LabelSelector != nil {
- l = m.LabelSelector.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if len(m.Namespaces) > 0 {
- for _, s := range m.Namespaces {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.TopologyKey)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodAntiAffinity) Size() (n int) {
- var l int
- _ = l
- if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, e := range m.RequiredDuringSchedulingIgnoredDuringExecution {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 {
- for _, e := range m.PreferredDuringSchedulingIgnoredDuringExecution {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodAttachOptions) Size() (n int) {
- var l int
- _ = l
- n += 2
- n += 2
- n += 2
- n += 2
- l = len(m.Container)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodCondition) Size() (n int) {
- var l int
- _ = l
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Status)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastProbeTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.LastTransitionTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodExecOptions) Size() (n int) {
- var l int
- _ = l
- n += 2
- n += 2
- n += 2
- n += 2
- l = len(m.Container)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Command) > 0 {
- for _, s := range m.Command {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodLogOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.Container)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- n += 2
- if m.SinceSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.SinceSeconds))
- }
- if m.SinceTime != nil {
- l = m.SinceTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- n += 2
- if m.TailLines != nil {
- n += 1 + sovGenerated(uint64(*m.TailLines))
- }
- if m.LimitBytes != nil {
- n += 1 + sovGenerated(uint64(*m.LimitBytes))
- }
- return n
-}
-
-func (m *PodProxyOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodSecurityContext) Size() (n int) {
- var l int
- _ = l
- if m.SELinuxOptions != nil {
- l = m.SELinuxOptions.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.RunAsUser != nil {
- n += 1 + sovGenerated(uint64(*m.RunAsUser))
- }
- if m.RunAsNonRoot != nil {
- n += 2
- }
- if len(m.SupplementalGroups) > 0 {
- for _, e := range m.SupplementalGroups {
- n += 1 + sovGenerated(uint64(e))
- }
- }
- if m.FSGroup != nil {
- n += 1 + sovGenerated(uint64(*m.FSGroup))
- }
- return n
-}
-
-func (m *PodSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Volumes) > 0 {
- for _, e := range m.Volumes {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Containers) > 0 {
- for _, e := range m.Containers {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.RestartPolicy)
- n += 1 + l + sovGenerated(uint64(l))
- if m.TerminationGracePeriodSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.TerminationGracePeriodSeconds))
- }
- if m.ActiveDeadlineSeconds != nil {
- n += 1 + sovGenerated(uint64(*m.ActiveDeadlineSeconds))
- }
- l = len(m.DNSPolicy)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.NodeSelector) > 0 {
- for k, v := range m.NodeSelector {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- l = len(m.ServiceAccountName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.DeprecatedServiceAccount)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.NodeName)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- n += 2
- n += 2
- if m.SecurityContext != nil {
- l = m.SecurityContext.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if len(m.ImagePullSecrets) > 0 {
- for _, e := range m.ImagePullSecrets {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.Hostname)
- n += 2 + l + sovGenerated(uint64(l))
- l = len(m.Subdomain)
- n += 2 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodStatus) Size() (n int) {
- var l int
- _ = l
- l = len(m.Phase)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Conditions) > 0 {
- for _, e := range m.Conditions {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.Message)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Reason)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.HostIP)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.PodIP)
- n += 1 + l + sovGenerated(uint64(l))
- if m.StartTime != nil {
- l = m.StartTime.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if len(m.ContainerStatuses) > 0 {
- for _, e := range m.ContainerStatuses {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodStatusResult) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodTemplate) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Template.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *PodTemplateList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *PodTemplateSpec) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Preconditions) Size() (n int) {
- var l int
- _ = l
- if m.UID != nil {
- l = len(*m.UID)
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *PreferredSchedulingTerm) Size() (n int) {
- var l int
- _ = l
- n += 1 + sovGenerated(uint64(m.Weight))
- l = m.Preference.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Probe) Size() (n int) {
- var l int
- _ = l
- l = m.Handler.Size()
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.InitialDelaySeconds))
- n += 1 + sovGenerated(uint64(m.TimeoutSeconds))
- n += 1 + sovGenerated(uint64(m.PeriodSeconds))
- n += 1 + sovGenerated(uint64(m.SuccessThreshold))
- n += 1 + sovGenerated(uint64(m.FailureThreshold))
- return n
-}
-
-func (m *RBDVolumeSource) Size() (n int) {
- var l int
- _ = l
- if len(m.CephMonitors) > 0 {
- for _, s := range m.CephMonitors {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.RBDImage)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.RBDPool)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.RadosUser)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Keyring)
- n += 1 + l + sovGenerated(uint64(l))
- if m.SecretRef != nil {
- l = m.SecretRef.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- n += 2
- return n
-}
-
-func (m *RangeAllocation) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Range)
- n += 1 + l + sovGenerated(uint64(l))
- if m.Data != nil {
- l = len(m.Data)
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *ReplicationController) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ReplicationControllerList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ReplicationControllerSpec) Size() (n int) {
- var l int
- _ = l
- if m.Replicas != nil {
- n += 1 + sovGenerated(uint64(*m.Replicas))
- }
- if len(m.Selector) > 0 {
- for k, v := range m.Selector {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if m.Template != nil {
- l = m.Template.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *ReplicationControllerStatus) Size() (n int) {
- var l int
- _ = l
- n += 1 + sovGenerated(uint64(m.Replicas))
- n += 1 + sovGenerated(uint64(m.FullyLabeledReplicas))
- n += 1 + sovGenerated(uint64(m.ObservedGeneration))
- return n
-}
-
-func (m *ResourceFieldSelector) Size() (n int) {
- var l int
- _ = l
- l = len(m.ContainerName)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Resource)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Divisor.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ResourceQuota) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ResourceQuotaList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ResourceQuotaSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Hard) > 0 {
- for k, v := range m.Hard {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Scopes) > 0 {
- for _, s := range m.Scopes {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ResourceQuotaStatus) Size() (n int) {
- var l int
- _ = l
- if len(m.Hard) > 0 {
- for k, v := range m.Hard {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Used) > 0 {
- for k, v := range m.Used {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *ResourceRequirements) Size() (n int) {
- var l int
- _ = l
- if len(m.Limits) > 0 {
- for k, v := range m.Limits {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- if len(m.Requests) > 0 {
- for k, v := range m.Requests {
- _ = k
- _ = v
- l = v.Size()
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *SELinuxOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.User)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Role)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Level)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Secret) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Data) > 0 {
- for k, v := range m.Data {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.StringData) > 0 {
- for k, v := range m.StringData {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- return n
-}
-
-func (m *SecretKeySelector) Size() (n int) {
- var l int
- _ = l
- l = m.LocalObjectReference.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *SecretList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *SecretVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.SecretName)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *SecurityContext) Size() (n int) {
- var l int
- _ = l
- if m.Capabilities != nil {
- l = m.Capabilities.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Privileged != nil {
- n += 2
- }
- if m.SELinuxOptions != nil {
- l = m.SELinuxOptions.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.RunAsUser != nil {
- n += 1 + sovGenerated(uint64(*m.RunAsUser))
- }
- if m.RunAsNonRoot != nil {
- n += 2
- }
- if m.ReadOnlyRootFilesystem != nil {
- n += 2
- }
- return n
-}
-
-func (m *SerializedReference) Size() (n int) {
- var l int
- _ = l
- l = m.Reference.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Service) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Spec.Size()
- n += 1 + l + sovGenerated(uint64(l))
- l = m.Status.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ServiceAccount) Size() (n int) {
- var l int
- _ = l
- l = m.ObjectMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Secrets) > 0 {
- for _, e := range m.Secrets {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.ImagePullSecrets) > 0 {
- for _, e := range m.ImagePullSecrets {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ServiceAccountList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ServiceList) Size() (n int) {
- var l int
- _ = l
- l = m.ListMeta.Size()
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.Items) > 0 {
- for _, e := range m.Items {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ServicePort) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Protocol)
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.Port))
- l = m.TargetPort.Size()
- n += 1 + l + sovGenerated(uint64(l))
- n += 1 + sovGenerated(uint64(m.NodePort))
- return n
-}
-
-func (m *ServiceProxyOptions) Size() (n int) {
- var l int
- _ = l
- l = len(m.Path)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *ServiceSpec) Size() (n int) {
- var l int
- _ = l
- if len(m.Ports) > 0 {
- for _, e := range m.Ports {
- l = e.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.Selector) > 0 {
- for k, v := range m.Selector {
- _ = k
- _ = v
- mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v)))
- n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize))
- }
- }
- l = len(m.ClusterIP)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Type)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.ExternalIPs) > 0 {
- for _, s := range m.ExternalIPs {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- if len(m.DeprecatedPublicIPs) > 0 {
- for _, s := range m.DeprecatedPublicIPs {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- l = len(m.SessionAffinity)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.LoadBalancerIP)
- n += 1 + l + sovGenerated(uint64(l))
- if len(m.LoadBalancerSourceRanges) > 0 {
- for _, s := range m.LoadBalancerSourceRanges {
- l = len(s)
- n += 1 + l + sovGenerated(uint64(l))
- }
- }
- return n
-}
-
-func (m *ServiceStatus) Size() (n int) {
- var l int
- _ = l
- l = m.LoadBalancer.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *TCPSocketAction) Size() (n int) {
- var l int
- _ = l
- l = m.Port.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Taint) Size() (n int) {
- var l int
- _ = l
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Value)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Effect)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Toleration) Size() (n int) {
- var l int
- _ = l
- l = len(m.Key)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Operator)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Value)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.Effect)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *Volume) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- l = m.VolumeSource.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *VolumeMount) Size() (n int) {
- var l int
- _ = l
- l = len(m.Name)
- n += 1 + l + sovGenerated(uint64(l))
- n += 2
- l = len(m.MountPath)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.SubPath)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *VolumeSource) Size() (n int) {
- var l int
- _ = l
- if m.HostPath != nil {
- l = m.HostPath.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.EmptyDir != nil {
- l = m.EmptyDir.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.GCEPersistentDisk != nil {
- l = m.GCEPersistentDisk.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.AWSElasticBlockStore != nil {
- l = m.AWSElasticBlockStore.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.GitRepo != nil {
- l = m.GitRepo.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Secret != nil {
- l = m.Secret.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.NFS != nil {
- l = m.NFS.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.ISCSI != nil {
- l = m.ISCSI.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Glusterfs != nil {
- l = m.Glusterfs.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.PersistentVolumeClaim != nil {
- l = m.PersistentVolumeClaim.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.RBD != nil {
- l = m.RBD.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.FlexVolume != nil {
- l = m.FlexVolume.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Cinder != nil {
- l = m.Cinder.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.CephFS != nil {
- l = m.CephFS.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.Flocker != nil {
- l = m.Flocker.Size()
- n += 1 + l + sovGenerated(uint64(l))
- }
- if m.DownwardAPI != nil {
- l = m.DownwardAPI.Size()
- n += 2 + l + sovGenerated(uint64(l))
- }
- if m.FC != nil {
- l = m.FC.Size()
- n += 2 + l + sovGenerated(uint64(l))
- }
- if m.AzureFile != nil {
- l = m.AzureFile.Size()
- n += 2 + l + sovGenerated(uint64(l))
- }
- if m.ConfigMap != nil {
- l = m.ConfigMap.Size()
- n += 2 + l + sovGenerated(uint64(l))
- }
- if m.VsphereVolume != nil {
- l = m.VsphereVolume.Size()
- n += 2 + l + sovGenerated(uint64(l))
- }
- return n
-}
-
-func (m *VsphereVirtualDiskVolumeSource) Size() (n int) {
- var l int
- _ = l
- l = len(m.VolumePath)
- n += 1 + l + sovGenerated(uint64(l))
- l = len(m.FSType)
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func (m *WeightedPodAffinityTerm) Size() (n int) {
- var l int
- _ = l
- n += 1 + sovGenerated(uint64(m.Weight))
- l = m.PodAffinityTerm.Size()
- n += 1 + l + sovGenerated(uint64(l))
- return n
-}
-
-func sovGenerated(x uint64) (n int) {
- for {
- n++
- x >>= 7
- if x == 0 {
- break
- }
- }
- return n
-}
-func sozGenerated(x uint64) (n int) {
- return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
-}
-func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: AWSElasticBlockStoreVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: AWSElasticBlockStoreVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumeID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumeID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
- }
- m.Partition = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Partition |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Affinity) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Affinity: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Affinity: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodeAffinity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.NodeAffinity == nil {
- m.NodeAffinity = &NodeAffinity{}
- }
- if err := m.NodeAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PodAffinity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.PodAffinity == nil {
- m.PodAffinity = &PodAffinity{}
- }
- if err := m.PodAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PodAntiAffinity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.PodAntiAffinity == nil {
- m.PodAntiAffinity = &PodAntiAffinity{}
- }
- if err := m.PodAntiAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *AttachedVolume) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: AttachedVolume: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: AttachedVolume: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = UniqueVolumeName(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DevicePath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.DevicePath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *AzureFileVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: AzureFileVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: AzureFileVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SecretName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ShareName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ShareName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Binding) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Binding: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Binding: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Target.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Capabilities) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Capabilities: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Capabilities: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Add", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Add = append(m.Add, Capability(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Drop", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Drop = append(m.Drop, Capability(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CephFSVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CephFSVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CephFSVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Monitors", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Monitors = append(m.Monitors, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field User", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.User = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretFile", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SecretFile = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecretRef == nil {
- m.SecretRef = &LocalObjectReference{}
- }
- if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CinderVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CinderVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CinderVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumeID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumeID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ComponentCondition) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ComponentCondition: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ComponentCondition: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = ComponentConditionType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Status = ConditionStatus(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Error = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ComponentStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ComponentStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ComponentStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Conditions = append(m.Conditions, ComponentCondition{})
- if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ComponentStatusList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ComponentStatusList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ComponentStatusList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, ComponentStatus{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ConfigMap) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ConfigMap: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ConfigMap: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Data == nil {
- m.Data = make(map[string]string)
- }
- m.Data[mapkey] = mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ConfigMapKeySelector) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ConfigMapKeySelector: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ConfigMapKeySelector: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ConfigMapList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ConfigMapList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ConfigMapList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, ConfigMap{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ConfigMapVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ConfigMapVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, KeyToPath{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Container) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Container: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Container: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Image = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Command = append(m.Command, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Args", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Args = append(m.Args, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field WorkingDir", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.WorkingDir = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Ports = append(m.Ports, ContainerPort{})
- if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Env", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Env = append(m.Env, EnvVar{})
- if err := m.Env[len(m.Env)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Resources.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumeMounts", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumeMounts = append(m.VolumeMounts, VolumeMount{})
- if err := m.VolumeMounts[len(m.VolumeMounts)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LivenessProbe", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.LivenessProbe == nil {
- m.LivenessProbe = &Probe{}
- }
- if err := m.LivenessProbe.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 11:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadinessProbe", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ReadinessProbe == nil {
- m.ReadinessProbe = &Probe{}
- }
- if err := m.ReadinessProbe.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 12:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Lifecycle == nil {
- m.Lifecycle = &Lifecycle{}
- }
- if err := m.Lifecycle.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 13:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TerminationMessagePath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.TerminationMessagePath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 14:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ImagePullPolicy", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ImagePullPolicy = PullPolicy(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 15:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecurityContext == nil {
- m.SecurityContext = &SecurityContext{}
- }
- if err := m.SecurityContext.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 16:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stdin = bool(v != 0)
- case 17:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field StdinOnce", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.StdinOnce = bool(v != 0)
- case 18:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TTY", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TTY = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerImage) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerImage: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerImage: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Names = append(m.Names, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SizeBytes", wireType)
- }
- m.SizeBytes = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.SizeBytes |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerPort) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerPort: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerPort: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostPort", wireType)
- }
- m.HostPort = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.HostPort |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerPort", wireType)
- }
- m.ContainerPort = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.ContainerPort |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Protocol = Protocol(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostIP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.HostIP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerState) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerState: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerState: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Waiting", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Waiting == nil {
- m.Waiting = &ContainerStateWaiting{}
- }
- if err := m.Waiting.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Running", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Running == nil {
- m.Running = &ContainerStateRunning{}
- }
- if err := m.Running.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Terminated", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Terminated == nil {
- m.Terminated = &ContainerStateTerminated{}
- }
- if err := m.Terminated.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerStateRunning) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerStateRunning: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerStateRunning: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field StartedAt", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.StartedAt.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerStateTerminated) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerStateTerminated: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerStateTerminated: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ExitCode", wireType)
- }
- m.ExitCode = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.ExitCode |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Signal", wireType)
- }
- m.Signal = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Signal |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field StartedAt", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.StartedAt.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FinishedAt", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.FinishedAt.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ContainerID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerStateWaiting) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerStateWaiting: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerStateWaiting: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ContainerStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ContainerStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ContainerStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field State", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.State.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastTerminationState", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastTerminationState.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Ready", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Ready = bool(v != 0)
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RestartCount", wireType)
- }
- m.RestartCount = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.RestartCount |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Image = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ImageID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ImageID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ContainerID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *DaemonEndpoint) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: DaemonEndpoint: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: DaemonEndpoint: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
- }
- m.Port = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Port |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *DeleteOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: DeleteOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: DeleteOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field GracePeriodSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.GracePeriodSeconds = &v
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Preconditions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Preconditions == nil {
- m.Preconditions = &Preconditions{}
- }
- if err := m.Preconditions.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field OrphanDependents", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.OrphanDependents = &b
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: DownwardAPIVolumeFile: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: DownwardAPIVolumeFile: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FieldRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FieldRef == nil {
- m.FieldRef = &ObjectFieldSelector{}
- }
- if err := m.FieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ResourceFieldRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ResourceFieldRef == nil {
- m.ResourceFieldRef = &ResourceFieldSelector{}
- }
- if err := m.ResourceFieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: DownwardAPIVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: DownwardAPIVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, DownwardAPIVolumeFile{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EmptyDirVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EmptyDirVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Medium", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Medium = StorageMedium(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EndpointAddress) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EndpointAddress: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EndpointAddress: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TargetRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.TargetRef == nil {
- m.TargetRef = &ObjectReference{}
- }
- if err := m.TargetRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Hostname = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EndpointPort) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EndpointPort: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EndpointPort: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
- }
- m.Port = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Port |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Protocol = Protocol(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EndpointSubset) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EndpointSubset: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EndpointSubset: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Addresses", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Addresses = append(m.Addresses, EndpointAddress{})
- if err := m.Addresses[len(m.Addresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NotReadyAddresses", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.NotReadyAddresses = append(m.NotReadyAddresses, EndpointAddress{})
- if err := m.NotReadyAddresses[len(m.NotReadyAddresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Ports = append(m.Ports, EndpointPort{})
- if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Endpoints) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Endpoints: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Endpoints: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Subsets", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Subsets = append(m.Subsets, EndpointSubset{})
- if err := m.Subsets[len(m.Subsets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EndpointsList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EndpointsList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EndpointsList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Endpoints{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EnvVar) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EnvVar: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EnvVar: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Value = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ValueFrom", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ValueFrom == nil {
- m.ValueFrom = &EnvVarSource{}
- }
- if err := m.ValueFrom.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EnvVarSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EnvVarSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EnvVarSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FieldRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FieldRef == nil {
- m.FieldRef = &ObjectFieldSelector{}
- }
- if err := m.FieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ResourceFieldRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ResourceFieldRef == nil {
- m.ResourceFieldRef = &ResourceFieldSelector{}
- }
- if err := m.ResourceFieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ConfigMapKeyRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ConfigMapKeyRef == nil {
- m.ConfigMapKeyRef = &ConfigMapKeySelector{}
- }
- if err := m.ConfigMapKeyRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretKeyRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecretKeyRef == nil {
- m.SecretKeyRef = &SecretKeySelector{}
- }
- if err := m.SecretKeyRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Event) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Event: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Event: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field InvolvedObject", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.InvolvedObject.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Source.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FirstTimestamp", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.FirstTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastTimestamp", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Count", wireType)
- }
- m.Count = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Count |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EventList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EventList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EventList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Event{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *EventSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: EventSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: EventSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Component", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Component = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Host = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ExecAction) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ExecAction: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ExecAction: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Command = append(m.Command, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ExportOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ExportOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ExportOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Export", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Export = bool(v != 0)
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Exact", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Exact = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *FCVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: FCVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: FCVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TargetWWNs", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.TargetWWNs = append(m.TargetWWNs, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Lun", wireType)
- }
- var v int32
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Lun = &v
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *FlexVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: FlexVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: FlexVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Driver", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Driver = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecretRef == nil {
- m.SecretRef = &LocalObjectReference{}
- }
- if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Options == nil {
- m.Options = make(map[string]string)
- }
- m.Options[mapkey] = mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *FlockerVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: FlockerVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: FlockerVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DatasetName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.DatasetName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: GCEPersistentDiskVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: GCEPersistentDiskVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PDName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PDName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
- }
- m.Partition = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Partition |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *GitRepoVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: GitRepoVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: GitRepoVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Repository", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Repository = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Revision = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Directory", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Directory = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: GlusterfsVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: GlusterfsVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field EndpointsName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.EndpointsName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *HTTPGetAction) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: HTTPGetAction: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: HTTPGetAction: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Port.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Host = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Scheme", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Scheme = URIScheme(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HTTPHeaders", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.HTTPHeaders = append(m.HTTPHeaders, HTTPHeader{})
- if err := m.HTTPHeaders[len(m.HTTPHeaders)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *HTTPHeader) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: HTTPHeader: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: HTTPHeader: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Value = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Handler) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Handler: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Handler: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Exec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Exec == nil {
- m.Exec = &ExecAction{}
- }
- if err := m.Exec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HTTPGet", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.HTTPGet == nil {
- m.HTTPGet = &HTTPGetAction{}
- }
- if err := m.HTTPGet.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TCPSocket", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.TCPSocket == nil {
- m.TCPSocket = &TCPSocketAction{}
- }
- if err := m.TCPSocket.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *HostPathVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: HostPathVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: HostPathVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ISCSIVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ISCSIVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ISCSIVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TargetPortal", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.TargetPortal = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IQN", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IQN = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Lun", wireType)
- }
- m.Lun = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Lun |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ISCSIInterface", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ISCSIInterface = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *KeyToPath) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: KeyToPath: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: KeyToPath: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Lifecycle) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Lifecycle: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Lifecycle: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PostStart", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.PostStart == nil {
- m.PostStart = &Handler{}
- }
- if err := m.PostStart.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PreStop", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.PreStop == nil {
- m.PreStop = &Handler{}
- }
- if err := m.PreStop.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LimitRange) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LimitRange: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LimitRange: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LimitRangeItem) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LimitRangeItem: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LimitRangeItem: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = LimitType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Max == nil {
- m.Max = make(ResourceList)
- }
- m.Max[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Min == nil {
- m.Min = make(ResourceList)
- }
- m.Min[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Default", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Default == nil {
- m.Default = make(ResourceList)
- }
- m.Default[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DefaultRequest", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.DefaultRequest == nil {
- m.DefaultRequest = make(ResourceList)
- }
- m.DefaultRequest[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MaxLimitRequestRatio", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.MaxLimitRequestRatio == nil {
- m.MaxLimitRequestRatio = make(ResourceList)
- }
- m.MaxLimitRequestRatio[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LimitRangeList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LimitRangeList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LimitRangeList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, LimitRange{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LimitRangeSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LimitRangeSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LimitRangeSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limits", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Limits = append(m.Limits, LimitRangeItem{})
- if err := m.Limits[len(m.Limits)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *List) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: List: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: List: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, k8s_io_kubernetes_pkg_runtime.RawExtension{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ListOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ListOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ListOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.LabelSelector = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FieldSelector", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FieldSelector = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Watch", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Watch = bool(v != 0)
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ResourceVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TimeoutSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TimeoutSeconds = &v
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LoadBalancerIngress) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LoadBalancerIngress: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LoadBalancerIngress: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Hostname = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LoadBalancerStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LoadBalancerStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LoadBalancerStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Ingress", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Ingress = append(m.Ingress, LoadBalancerIngress{})
- if err := m.Ingress[len(m.Ingress)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *LocalObjectReference) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: LocalObjectReference: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: LocalObjectReference: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NFSVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NFSVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NFSVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Server", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Server = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Namespace) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Namespace: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Namespace: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NamespaceList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NamespaceList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NamespaceList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Namespace{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NamespaceSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NamespaceSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NamespaceSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Finalizers", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Finalizers = append(m.Finalizers, FinalizerName(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NamespaceStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NamespaceStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NamespaceStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Phase = NamespacePhase(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Node) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Node: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Node: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeAddress) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeAddress: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeAddress: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = NodeAddressType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Address = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeAffinity) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeAffinity: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeAffinity: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RequiredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- m.RequiredDuringSchedulingIgnoredDuringExecution = &NodeSelector{}
- }
- if err := m.RequiredDuringSchedulingIgnoredDuringExecution.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PreferredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, PreferredSchedulingTerm{})
- if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeCondition) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeCondition: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeCondition: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = NodeConditionType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Status = ConditionStatus(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastHeartbeatTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastHeartbeatTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeDaemonEndpoints: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeDaemonEndpoints: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field KubeletEndpoint", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.KubeletEndpoint.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Node{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeProxyOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeProxyOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeProxyOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeSelector) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeSelector: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeSelector: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodeSelectorTerms", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.NodeSelectorTerms = append(m.NodeSelectorTerms, NodeSelectorTerm{})
- if err := m.NodeSelectorTerms[len(m.NodeSelectorTerms)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeSelectorRequirement) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeSelectorRequirement: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeSelectorRequirement: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Operator = NodeSelectorOperator(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Values = append(m.Values, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeSelectorTerm) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeSelectorTerm: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeSelectorTerm: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MatchExpressions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.MatchExpressions = append(m.MatchExpressions, NodeSelectorRequirement{})
- if err := m.MatchExpressions[len(m.MatchExpressions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PodCIDR", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PodCIDR = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ExternalID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ExternalID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ProviderID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ProviderID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Unschedulable", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Unschedulable = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Capacity == nil {
- m.Capacity = make(ResourceList)
- }
- m.Capacity[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Allocatable", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Allocatable == nil {
- m.Allocatable = make(ResourceList)
- }
- m.Allocatable[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Phase = NodePhase(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Conditions = append(m.Conditions, NodeCondition{})
- if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Addresses", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Addresses = append(m.Addresses, NodeAddress{})
- if err := m.Addresses[len(m.Addresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DaemonEndpoints", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.DaemonEndpoints.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodeInfo", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.NodeInfo.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Images", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Images = append(m.Images, ContainerImage{})
- if err := m.Images[len(m.Images)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumesInUse", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumesInUse = append(m.VolumesInUse, UniqueVolumeName(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumesAttached", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumesAttached = append(m.VolumesAttached, AttachedVolume{})
- if err := m.VolumesAttached[len(m.VolumesAttached)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NodeSystemInfo) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NodeSystemInfo: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NodeSystemInfo: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MachineID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.MachineID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SystemUUID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SystemUUID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field BootID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.BootID = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field KernelVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.KernelVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field OSImage", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.OSImage = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerRuntimeVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ContainerRuntimeVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field KubeletVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.KubeletVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field KubeProxyVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.KubeProxyVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field OperatingSystem", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.OperatingSystem = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Architecture", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Architecture = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ObjectFieldSelector) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ObjectFieldSelector: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ObjectFieldSelector: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.APIVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FieldPath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FieldPath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ObjectMeta) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ObjectMeta: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ObjectMeta: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field GenerateName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.GenerateName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Namespace = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SelfLink", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SelfLink = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ResourceVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Generation", wireType)
- }
- m.Generation = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Generation |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CreationTimestamp", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.CreationTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DeletionTimestamp", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.DeletionTimestamp == nil {
- m.DeletionTimestamp = &k8s_io_kubernetes_pkg_api_unversioned.Time{}
- }
- if err := m.DeletionTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 10:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field DeletionGracePeriodSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.DeletionGracePeriodSeconds = &v
- case 11:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Labels == nil {
- m.Labels = make(map[string]string)
- }
- m.Labels[mapkey] = mapvalue
- iNdEx = postIndex
- case 12:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Annotations == nil {
- m.Annotations = make(map[string]string)
- }
- m.Annotations[mapkey] = mapvalue
- iNdEx = postIndex
- case 13:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field OwnerReferences", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.OwnerReferences = append(m.OwnerReferences, OwnerReference{})
- if err := m.OwnerReferences[len(m.OwnerReferences)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 14:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Finalizers", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Finalizers = append(m.Finalizers, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ObjectReference) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ObjectReference: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ObjectReference: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Kind = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Namespace = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.APIVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ResourceVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FieldPath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FieldPath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *OwnerReference) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: OwnerReference: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: OwnerReference: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Kind = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.APIVersion = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Controller", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.Controller = &b
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolume) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolume: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolume: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeClaim) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeClaim: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeClaim: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeClaimList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeClaimList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, PersistentVolumeClaim{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeClaimSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeClaimSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Resources.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumeName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Selector == nil {
- m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{}
- }
- if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeClaimStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeClaimStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Phase = PersistentVolumeClaimPhase(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Capacity == nil {
- m.Capacity = make(ResourceList)
- }
- m.Capacity[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeClaimVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeClaimVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ClaimName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ClaimName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, PersistentVolume{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field GCEPersistentDisk", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.GCEPersistentDisk == nil {
- m.GCEPersistentDisk = &GCEPersistentDiskVolumeSource{}
- }
- if err := m.GCEPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AWSElasticBlockStore", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.AWSElasticBlockStore == nil {
- m.AWSElasticBlockStore = &AWSElasticBlockStoreVolumeSource{}
- }
- if err := m.AWSElasticBlockStore.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.HostPath == nil {
- m.HostPath = &HostPathVolumeSource{}
- }
- if err := m.HostPath.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Glusterfs", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Glusterfs == nil {
- m.Glusterfs = &GlusterfsVolumeSource{}
- }
- if err := m.Glusterfs.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NFS", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.NFS == nil {
- m.NFS = &NFSVolumeSource{}
- }
- if err := m.NFS.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RBD", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.RBD == nil {
- m.RBD = &RBDVolumeSource{}
- }
- if err := m.RBD.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ISCSI", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ISCSI == nil {
- m.ISCSI = &ISCSIVolumeSource{}
- }
- if err := m.ISCSI.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Cinder", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Cinder == nil {
- m.Cinder = &CinderVolumeSource{}
- }
- if err := m.Cinder.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CephFS", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.CephFS == nil {
- m.CephFS = &CephFSVolumeSource{}
- }
- if err := m.CephFS.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FC", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FC == nil {
- m.FC = &FCVolumeSource{}
- }
- if err := m.FC.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 11:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Flocker", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Flocker == nil {
- m.Flocker = &FlockerVolumeSource{}
- }
- if err := m.Flocker.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 12:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FlexVolume", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FlexVolume == nil {
- m.FlexVolume = &FlexVolumeSource{}
- }
- if err := m.FlexVolume.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 13:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AzureFile", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.AzureFile == nil {
- m.AzureFile = &AzureFileVolumeSource{}
- }
- if err := m.AzureFile.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 14:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VsphereVolume", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.VsphereVolume == nil {
- m.VsphereVolume = &VsphereVirtualDiskVolumeSource{}
- }
- if err := m.VsphereVolume.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Capacity == nil {
- m.Capacity = make(ResourceList)
- }
- m.Capacity[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeSource", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.PersistentVolumeSource.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ClaimRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ClaimRef == nil {
- m.ClaimRef = &ObjectReference{}
- }
- if err := m.ClaimRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeReclaimPolicy", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PersistentVolumeStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PersistentVolumeStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PersistentVolumeStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Phase = PersistentVolumePhase(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Pod) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Pod: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Pod: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodAffinity) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodAffinity: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodAffinity: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RequiredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RequiredDuringSchedulingIgnoredDuringExecution = append(m.RequiredDuringSchedulingIgnoredDuringExecution, PodAffinityTerm{})
- if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PreferredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, WeightedPodAffinityTerm{})
- if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodAffinityTerm) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodAffinityTerm: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodAffinityTerm: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.LabelSelector == nil {
- m.LabelSelector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{}
- }
- if err := m.LabelSelector.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Namespaces", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Namespaces = append(m.Namespaces, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TopologyKey", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.TopologyKey = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodAntiAffinity) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodAntiAffinity: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodAntiAffinity: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RequiredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RequiredDuringSchedulingIgnoredDuringExecution = append(m.RequiredDuringSchedulingIgnoredDuringExecution, PodAffinityTerm{})
- if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PreferredDuringSchedulingIgnoredDuringExecution", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, WeightedPodAffinityTerm{})
- if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodAttachOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodAttachOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodAttachOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stdin = bool(v != 0)
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stdout = bool(v != 0)
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stderr = bool(v != 0)
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TTY", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TTY = bool(v != 0)
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Container", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Container = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodCondition) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodCondition: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodCondition: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = PodConditionType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Status = ConditionStatus(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastProbeTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastProbeTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodExecOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodExecOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodExecOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stdin = bool(v != 0)
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stdout = bool(v != 0)
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Stderr = bool(v != 0)
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TTY", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TTY = bool(v != 0)
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Container", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Container = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Command = append(m.Command, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Pod{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodLogOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodLogOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodLogOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Container", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Container = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Follow", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Follow = bool(v != 0)
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Previous", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Previous = bool(v != 0)
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SinceSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.SinceSeconds = &v
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SinceTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SinceTime == nil {
- m.SinceTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{}
- }
- if err := m.SinceTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Timestamps", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Timestamps = bool(v != 0)
- case 7:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TailLines", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TailLines = &v
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field LimitBytes", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.LimitBytes = &v
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodProxyOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodProxyOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodProxyOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodSecurityContext) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodSecurityContext: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodSecurityContext: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SELinuxOptions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SELinuxOptions == nil {
- m.SELinuxOptions = &SELinuxOptions{}
- }
- if err := m.SELinuxOptions.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.RunAsUser = &v
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RunAsNonRoot", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.RunAsNonRoot = &b
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.SupplementalGroups = append(m.SupplementalGroups, v)
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSGroup", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.FSGroup = &v
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Volumes", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Volumes = append(m.Volumes, Volume{})
- if err := m.Volumes[len(m.Volumes)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Containers", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Containers = append(m.Containers, Container{})
- if err := m.Containers[len(m.Containers)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RestartPolicy", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RestartPolicy = RestartPolicy(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TerminationGracePeriodSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.TerminationGracePeriodSeconds = &v
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ActiveDeadlineSeconds", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ActiveDeadlineSeconds = &v
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DNSPolicy", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.DNSPolicy = DNSPolicy(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodeSelector", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.NodeSelector == nil {
- m.NodeSelector = make(map[string]string)
- }
- m.NodeSelector[mapkey] = mapvalue
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ServiceAccountName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ServiceAccountName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DeprecatedServiceAccount", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.DeprecatedServiceAccount = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodeName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.NodeName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 11:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostNetwork", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.HostNetwork = bool(v != 0)
- case 12:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostPID", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.HostPID = bool(v != 0)
- case 13:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostIPC", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.HostIPC = bool(v != 0)
- case 14:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecurityContext", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecurityContext == nil {
- m.SecurityContext = &PodSecurityContext{}
- }
- if err := m.SecurityContext.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 15:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ImagePullSecrets", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ImagePullSecrets = append(m.ImagePullSecrets, LocalObjectReference{})
- if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 16:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Hostname = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 17:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Subdomain", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Subdomain = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Phase = PodPhase(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Conditions = append(m.Conditions, PodCondition{})
- if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Message = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Reason = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostIP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.HostIP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PodIP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.PodIP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field StartTime", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.StartTime == nil {
- m.StartTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{}
- }
- if err := m.StartTime.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerStatuses", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ContainerStatuses = append(m.ContainerStatuses, ContainerStatus{})
- if err := m.ContainerStatuses[len(m.ContainerStatuses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodStatusResult) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodStatusResult: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodStatusResult: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodTemplate) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodTemplate: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodTemplate: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodTemplateList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodTemplateList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodTemplateList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, PodTemplate{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PodTemplateSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PodTemplateSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PodTemplateSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Preconditions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Preconditions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Preconditions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- s := k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex])
- m.UID = &s
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PreferredSchedulingTerm: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PreferredSchedulingTerm: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
- }
- m.Weight = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Weight |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Preference", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Preference.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Probe) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Probe: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Probe: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Handler", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Handler.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field InitialDelaySeconds", wireType)
- }
- m.InitialDelaySeconds = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.InitialDelaySeconds |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TimeoutSeconds", wireType)
- }
- m.TimeoutSeconds = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.TimeoutSeconds |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field PeriodSeconds", wireType)
- }
- m.PeriodSeconds = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.PeriodSeconds |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SuccessThreshold", wireType)
- }
- m.SuccessThreshold = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.SuccessThreshold |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FailureThreshold", wireType)
- }
- m.FailureThreshold = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.FailureThreshold |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RBDVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RBDVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RBDVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CephMonitors", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.CephMonitors = append(m.CephMonitors, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RBDImage", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RBDImage = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RBDPool", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RBDPool = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RadosUser", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.RadosUser = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Keyring", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Keyring = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SecretRef == nil {
- m.SecretRef = &LocalObjectReference{}
- }
- if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RangeAllocation) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RangeAllocation: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RangeAllocation: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Range", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Range = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
- }
- var byteLen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- byteLen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if byteLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + byteLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Data = append(m.Data[:0], data[iNdEx:postIndex]...)
- if m.Data == nil {
- m.Data = []byte{}
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ReplicationController) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ReplicationController: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ReplicationController: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ReplicationControllerList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ReplicationControllerList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ReplicationControllerList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, ReplicationController{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ReplicationControllerSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ReplicationControllerSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ReplicationControllerSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType)
- }
- var v int32
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.Replicas = &v
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Selector == nil {
- m.Selector = make(map[string]string)
- }
- m.Selector[mapkey] = mapvalue
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Template == nil {
- m.Template = &PodTemplateSpec{}
- }
- if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ReplicationControllerStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ReplicationControllerStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ReplicationControllerStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType)
- }
- m.Replicas = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Replicas |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FullyLabeledReplicas", wireType)
- }
- m.FullyLabeledReplicas = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.FullyLabeledReplicas |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType)
- }
- m.ObservedGeneration = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.ObservedGeneration |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceFieldSelector) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceFieldSelector: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceFieldSelector: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ContainerName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ContainerName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Resource = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Divisor", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Divisor.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceQuota) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceQuota: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceQuota: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceQuotaList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceQuotaList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceQuotaList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, ResourceQuota{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceQuotaSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceQuotaSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceQuotaSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hard", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Hard == nil {
- m.Hard = make(ResourceList)
- }
- m.Hard[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Scopes", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Scopes = append(m.Scopes, ResourceQuotaScope(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceQuotaStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceQuotaStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceQuotaStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hard", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Hard == nil {
- m.Hard = make(ResourceList)
- }
- m.Hard[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Used", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Used == nil {
- m.Used = make(ResourceList)
- }
- m.Used[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ResourceRequirements) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ResourceRequirements: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ResourceRequirements: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limits", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Limits == nil {
- m.Limits = make(ResourceList)
- }
- m.Limits[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Requests", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := ResourceName(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapmsglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapmsglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postmsgIndex := iNdEx + mapmsglen
- if mapmsglen < 0 {
- return ErrInvalidLengthGenerated
- }
- if postmsgIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{}
- if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil {
- return err
- }
- iNdEx = postmsgIndex
- if m.Requests == nil {
- m.Requests = make(ResourceList)
- }
- m.Requests[ResourceName(mapkey)] = *mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SELinuxOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SELinuxOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SELinuxOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field User", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.User = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Role", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Role = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Level", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Level = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Secret) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Secret: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Secret: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var mapbyteLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- mapbyteLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intMapbyteLen := int(mapbyteLen)
- if intMapbyteLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postbytesIndex := iNdEx + intMapbyteLen
- if postbytesIndex > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := make([]byte, mapbyteLen)
- copy(mapvalue, data[iNdEx:postbytesIndex])
- iNdEx = postbytesIndex
- if m.Data == nil {
- m.Data = make(map[string][]byte)
- }
- m.Data[mapkey] = mapvalue
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = SecretType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field StringData", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.StringData == nil {
- m.StringData = make(map[string]string)
- }
- m.StringData[mapkey] = mapvalue
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SecretKeySelector) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SecretKeySelector: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SecretKeySelector: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SecretList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SecretList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SecretList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Secret{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SecretVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SecretVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SecretVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SecretName = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, KeyToPath{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SecurityContext) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SecurityContext: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SecurityContext: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Capabilities", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Capabilities == nil {
- m.Capabilities = &Capabilities{}
- }
- if err := m.Capabilities.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.Privileged = &b
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SELinuxOptions", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.SELinuxOptions == nil {
- m.SELinuxOptions = &SELinuxOptions{}
- }
- if err := m.SELinuxOptions.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType)
- }
- var v int64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.RunAsUser = &v
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RunAsNonRoot", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.RunAsNonRoot = &b
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnlyRootFilesystem", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- b := bool(v != 0)
- m.ReadOnlyRootFilesystem = &b
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *SerializedReference) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: SerializedReference: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: SerializedReference: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Reference", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Reference.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Service) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Service: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Service: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceAccount) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceAccount: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceAccount: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Secrets", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Secrets = append(m.Secrets, ObjectReference{})
- if err := m.Secrets[len(m.Secrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ImagePullSecrets", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ImagePullSecrets = append(m.ImagePullSecrets, LocalObjectReference{})
- if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceAccountList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceAccountList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceAccountList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, ServiceAccount{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceList) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceList: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceList: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Items = append(m.Items, Service{})
- if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServicePort) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServicePort: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServicePort: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Protocol = Protocol(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
- }
- m.Port = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Port |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field TargetPort", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.TargetPort.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NodePort", wireType)
- }
- m.NodePort = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.NodePort |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceProxyOptions) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceProxyOptions: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceProxyOptions: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Path = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceSpec) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceSpec: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceSpec: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Ports = append(m.Ports, ServicePort{})
- if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var keykey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- keykey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapkey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapkey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapkey := int(stringLenmapkey)
- if intStringLenmapkey < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapkey := iNdEx + intStringLenmapkey
- if postStringIndexmapkey > l {
- return io.ErrUnexpectedEOF
- }
- mapkey := string(data[iNdEx:postStringIndexmapkey])
- iNdEx = postStringIndexmapkey
- var valuekey uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- valuekey |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- var stringLenmapvalue uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLenmapvalue |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLenmapvalue := int(stringLenmapvalue)
- if intStringLenmapvalue < 0 {
- return ErrInvalidLengthGenerated
- }
- postStringIndexmapvalue := iNdEx + intStringLenmapvalue
- if postStringIndexmapvalue > l {
- return io.ErrUnexpectedEOF
- }
- mapvalue := string(data[iNdEx:postStringIndexmapvalue])
- iNdEx = postStringIndexmapvalue
- if m.Selector == nil {
- m.Selector = make(map[string]string)
- }
- m.Selector[mapkey] = mapvalue
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ClusterIP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ClusterIP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Type = ServiceType(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ExternalIPs", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.ExternalIPs = append(m.ExternalIPs, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DeprecatedPublicIPs", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.DeprecatedPublicIPs = append(m.DeprecatedPublicIPs, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SessionAffinity", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SessionAffinity = ServiceAffinity(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerIP", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.LoadBalancerIP = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerSourceRanges", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.LoadBalancerSourceRanges = append(m.LoadBalancerSourceRanges, string(data[iNdEx:postIndex]))
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *ServiceStatus) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: ServiceStatus: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: ServiceStatus: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancer", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.LoadBalancer.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *TCPSocketAction) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: TCPSocketAction: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: TCPSocketAction: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.Port.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Taint) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Taint: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Taint: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Value = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Effect", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Effect = TaintEffect(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Toleration) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Toleration: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Toleration: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Key = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Operator = TolerationOperator(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Value = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Effect", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Effect = TaintEffect(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Volume) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Volume: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Volume: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumeSource", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.VolumeSource.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *VolumeMount) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: VolumeMount: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: VolumeMount: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType)
- }
- var v int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- v |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.ReadOnly = bool(v != 0)
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MountPath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.MountPath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SubPath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SubPath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *VolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: VolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: VolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field HostPath", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.HostPath == nil {
- m.HostPath = &HostPathVolumeSource{}
- }
- if err := m.HostPath.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field EmptyDir", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.EmptyDir == nil {
- m.EmptyDir = &EmptyDirVolumeSource{}
- }
- if err := m.EmptyDir.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field GCEPersistentDisk", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.GCEPersistentDisk == nil {
- m.GCEPersistentDisk = &GCEPersistentDiskVolumeSource{}
- }
- if err := m.GCEPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AWSElasticBlockStore", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.AWSElasticBlockStore == nil {
- m.AWSElasticBlockStore = &AWSElasticBlockStoreVolumeSource{}
- }
- if err := m.AWSElasticBlockStore.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field GitRepo", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.GitRepo == nil {
- m.GitRepo = &GitRepoVolumeSource{}
- }
- if err := m.GitRepo.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Secret", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Secret == nil {
- m.Secret = &SecretVolumeSource{}
- }
- if err := m.Secret.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field NFS", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.NFS == nil {
- m.NFS = &NFSVolumeSource{}
- }
- if err := m.NFS.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ISCSI", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ISCSI == nil {
- m.ISCSI = &ISCSIVolumeSource{}
- }
- if err := m.ISCSI.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Glusterfs", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Glusterfs == nil {
- m.Glusterfs = &GlusterfsVolumeSource{}
- }
- if err := m.Glusterfs.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 10:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeClaim", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.PersistentVolumeClaim == nil {
- m.PersistentVolumeClaim = &PersistentVolumeClaimVolumeSource{}
- }
- if err := m.PersistentVolumeClaim.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 11:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field RBD", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.RBD == nil {
- m.RBD = &RBDVolumeSource{}
- }
- if err := m.RBD.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 12:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FlexVolume", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FlexVolume == nil {
- m.FlexVolume = &FlexVolumeSource{}
- }
- if err := m.FlexVolume.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 13:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Cinder", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Cinder == nil {
- m.Cinder = &CinderVolumeSource{}
- }
- if err := m.Cinder.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 14:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CephFS", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.CephFS == nil {
- m.CephFS = &CephFSVolumeSource{}
- }
- if err := m.CephFS.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 15:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Flocker", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Flocker == nil {
- m.Flocker = &FlockerVolumeSource{}
- }
- if err := m.Flocker.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 16:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field DownwardAPI", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.DownwardAPI == nil {
- m.DownwardAPI = &DownwardAPIVolumeSource{}
- }
- if err := m.DownwardAPI.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 17:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FC", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.FC == nil {
- m.FC = &FCVolumeSource{}
- }
- if err := m.FC.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 18:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field AzureFile", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.AzureFile == nil {
- m.AzureFile = &AzureFileVolumeSource{}
- }
- if err := m.AzureFile.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 19:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field ConfigMap", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.ConfigMap == nil {
- m.ConfigMap = &ConfigMapVolumeSource{}
- }
- if err := m.ConfigMap.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 20:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VsphereVolume", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.VsphereVolume == nil {
- m.VsphereVolume = &VsphereVirtualDiskVolumeSource{}
- }
- if err := m.VsphereVolume.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: VsphereVirtualDiskVolumeSource: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: VsphereVirtualDiskVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field VolumePath", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.VolumePath = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- stringLen |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + intStringLen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.FSType = string(data[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: WeightedPodAffinityTerm: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: WeightedPodAffinityTerm: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
- }
- m.Weight = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- m.Weight |= (int32(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field PodAffinityTerm", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- msglen |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthGenerated
- }
- postIndex := iNdEx + msglen
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if err := m.PodAffinityTerm.Unmarshal(data[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipGenerated(data[iNdEx:])
- if err != nil {
- return err
- }
- if skippy < 0 {
- return ErrInvalidLengthGenerated
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func skipGenerated(data []byte) (n int, err error) {
- l := len(data)
- iNdEx := 0
- for iNdEx < l {
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- wireType := int(wire & 0x7)
- switch wireType {
- case 0:
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- iNdEx++
- if data[iNdEx-1] < 0x80 {
- break
- }
- }
- return iNdEx, nil
- case 1:
- iNdEx += 8
- return iNdEx, nil
- case 2:
- var length int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- length |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- iNdEx += length
- if length < 0 {
- return 0, ErrInvalidLengthGenerated
- }
- return iNdEx, nil
- case 3:
- for {
- var innerWire uint64
- var start int = iNdEx
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowGenerated
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := data[iNdEx]
- iNdEx++
- innerWire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- innerWireType := int(innerWire & 0x7)
- if innerWireType == 4 {
- break
- }
- next, err := skipGenerated(data[start:])
- if err != nil {
- return 0, err
- }
- iNdEx = start + next
- }
- return iNdEx, nil
- case 4:
- return iNdEx, nil
- case 5:
- iNdEx += 4
- return iNdEx, nil
- default:
- return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
- }
- }
- panic("unreachable")
-}
-
-var (
- ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
- ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
-)
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.proto b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.proto
deleted file mode 100644
index 060b6ca..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/generated.proto
+++ /dev/null
@@ -1,2935 +0,0 @@
-/*
-Copyright 2016 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.
-*/
-
-
-// This file was autogenerated by go-to-protobuf. Do not edit it manually!
-
-syntax = 'proto2';
-
-package k8s.io.kubernetes.pkg.api.v1;
-
-import "k8s.io/kubernetes/pkg/api/resource/generated.proto";
-import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto";
-import "k8s.io/kubernetes/pkg/runtime/generated.proto";
-import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
-
-// Package-wide variables from generator "generated".
-option go_package = "v1";
-
-// Represents a Persistent Disk resource in AWS.
-//
-// An AWS EBS disk must exist before mounting to a container. The disk
-// must also be in the same AWS zone as the kubelet. An AWS EBS disk
-// can only be mounted as read/write once. AWS EBS volumes support
-// ownership management and SELinux relabeling.
-message AWSElasticBlockStoreVolumeSource {
- // Unique ID of the persistent disk resource in AWS (Amazon EBS volume).
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- optional string volumeID = 1;
-
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- optional string fsType = 2;
-
- // The partition in the volume that you want to mount.
- // If omitted, the default is to mount by volume name.
- // Examples: For volume /dev/sda1, you specify the partition as "1".
- // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
- optional int32 partition = 3;
-
- // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true".
- // If omitted, the default is "false".
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- optional bool readOnly = 4;
-}
-
-// Affinity is a group of affinity scheduling rules.
-message Affinity {
- // Describes node affinity scheduling rules for the pod.
- optional NodeAffinity nodeAffinity = 1;
-
- // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).
- optional PodAffinity podAffinity = 2;
-
- // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).
- optional PodAntiAffinity podAntiAffinity = 3;
-}
-
-// AttachedVolume describes a volume attached to a node
-message AttachedVolume {
- // Name of the attached volume
- optional string name = 1;
-
- // DevicePath represents the device path where the volume should be avilable
- optional string devicePath = 2;
-}
-
-// AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
-message AzureFileVolumeSource {
- // the name of secret that contains Azure Storage Account Name and Key
- optional string secretName = 1;
-
- // Share Name
- optional string shareName = 2;
-
- // Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- optional bool readOnly = 3;
-}
-
-// Binding ties one object to another.
-// For example, a pod is bound to a node by a scheduler.
-message Binding {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // The target object that you want to bind to the standard object.
- optional ObjectReference target = 2;
-}
-
-// Adds and removes POSIX capabilities from running containers.
-message Capabilities {
- // Added capabilities
- repeated string add = 1;
-
- // Removed capabilities
- repeated string drop = 2;
-}
-
-// Represents a Ceph Filesystem mount that lasts the lifetime of a pod
-// Cephfs volumes do not support ownership management or SELinux relabeling.
-message CephFSVolumeSource {
- // Required: Monitors is a collection of Ceph monitors
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- repeated string monitors = 1;
-
- // Optional: Used as the mounted root, rather than the full Ceph tree, default is /
- optional string path = 2;
-
- // Optional: User is the rados user name, default is admin
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- optional string user = 3;
-
- // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- optional string secretFile = 4;
-
- // Optional: SecretRef is reference to the authentication secret for User, default is empty.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- optional LocalObjectReference secretRef = 5;
-
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- optional bool readOnly = 6;
-}
-
-// Represents a cinder volume resource in Openstack.
-// A Cinder volume must exist before mounting to a container.
-// The volume must also be in the same region as the kubelet.
-// Cinder volumes support ownership management and SELinux relabeling.
-message CinderVolumeSource {
- // volume id used to identify the volume in cinder
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- optional string volumeID = 1;
-
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- optional string fsType = 2;
-
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- optional bool readOnly = 3;
-}
-
-// Information about the condition of a component.
-message ComponentCondition {
- // Type of condition for a component.
- // Valid value: "Healthy"
- optional string type = 1;
-
- // Status of the condition for a component.
- // Valid values for "Healthy": "True", "False", or "Unknown".
- optional string status = 2;
-
- // Message about the condition for a component.
- // For example, information about a health check.
- optional string message = 3;
-
- // Condition error code for a component.
- // For example, a health check error code.
- optional string error = 4;
-}
-
-// ComponentStatus (and ComponentStatusList) holds the cluster validation info.
-message ComponentStatus {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // List of component conditions observed
- repeated ComponentCondition conditions = 2;
-}
-
-// Status of all the conditions for the component as a list of ComponentStatus objects.
-message ComponentStatusList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of ComponentStatus objects.
- repeated ComponentStatus items = 2;
-}
-
-// ConfigMap holds configuration data for pods to consume.
-message ConfigMap {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Data contains the configuration data.
- // Each key must be a valid DNS_SUBDOMAIN with an optional leading dot.
- map<string, string> data = 2;
-}
-
-// Selects a key from a ConfigMap.
-message ConfigMapKeySelector {
- // The ConfigMap to select from.
- optional LocalObjectReference localObjectReference = 1;
-
- // The key to select.
- optional string key = 2;
-}
-
-// ConfigMapList is a resource containing a list of ConfigMap objects.
-message ConfigMapList {
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // Items is the list of ConfigMaps.
- repeated ConfigMap items = 2;
-}
-
-// Adapts a ConfigMap into a volume.
-//
-// The contents of the target ConfigMap's Data field will be presented in a
-// volume as files using the keys in the Data field as the file names, unless
-// the items element is populated with specific mappings of keys to paths.
-// ConfigMap volumes support ownership management and SELinux relabeling.
-message ConfigMapVolumeSource {
- optional LocalObjectReference localObjectReference = 1;
-
- // If unspecified, each key-value pair in the Data field of the referenced
- // ConfigMap will be projected into the volume as a file whose name is the
- // key and content is the value. If specified, the listed keys will be
- // projected into the specified paths, and unlisted keys will not be
- // present. If a key is specified which is not present in the ConfigMap,
- // the volume setup will error. Paths must be relative and may not contain
- // the '..' path or start with '..'.
- repeated KeyToPath items = 2;
-}
-
-// A single application container that you want to run within a pod.
-message Container {
- // Name of the container specified as a DNS_LABEL.
- // Each container in a pod must have a unique name (DNS_LABEL).
- // Cannot be updated.
- optional string name = 1;
-
- // Docker image name.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md
- optional string image = 2;
-
- // Entrypoint array. Not executed within a shell.
- // The docker image's ENTRYPOINT is used if this is not provided.
- // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
- // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
- // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
- // regardless of whether the variable exists or not.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands
- repeated string command = 3;
-
- // Arguments to the entrypoint.
- // The docker image's CMD is used if this is not provided.
- // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
- // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
- // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
- // regardless of whether the variable exists or not.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands
- repeated string args = 4;
-
- // Container's working directory.
- // If not specified, the container runtime's default will be used, which
- // might be configured in the container image.
- // Cannot be updated.
- optional string workingDir = 5;
-
- // List of ports to expose from the container. Exposing a port here gives
- // the system additional information about the network connections a
- // container uses, but is primarily informational. Not specifying a port here
- // DOES NOT prevent that port from being exposed. Any port which is
- // listening on the default "0.0.0.0" address inside a container will be
- // accessible from the network.
- // Cannot be updated.
- repeated ContainerPort ports = 6;
-
- // List of environment variables to set in the container.
- // Cannot be updated.
- repeated EnvVar env = 7;
-
- // Compute Resources required by this container.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources
- optional ResourceRequirements resources = 8;
-
- // Pod volumes to mount into the container's filesystem.
- // Cannot be updated.
- repeated VolumeMount volumeMounts = 9;
-
- // Periodic probe of container liveness.
- // Container will be restarted if the probe fails.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- optional Probe livenessProbe = 10;
-
- // Periodic probe of container service readiness.
- // Container will be removed from service endpoints if the probe fails.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- optional Probe readinessProbe = 11;
-
- // Actions that the management system should take in response to container lifecycle events.
- // Cannot be updated.
- optional Lifecycle lifecycle = 12;
-
- // Optional: Path at which the file to which the container's termination message
- // will be written is mounted into the container's filesystem.
- // Message written is intended to be brief final status, such as an assertion failure message.
- // Defaults to /dev/termination-log.
- // Cannot be updated.
- optional string terminationMessagePath = 13;
-
- // Image pull policy.
- // One of Always, Never, IfNotPresent.
- // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#updating-images
- optional string imagePullPolicy = 14;
-
- // Security options the pod should run with.
- // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md
- optional SecurityContext securityContext = 15;
-
- // Whether this container should allocate a buffer for stdin in the container runtime. If this
- // is not set, reads from stdin in the container will always result in EOF.
- // Default is false.
- optional bool stdin = 16;
-
- // Whether the container runtime should close the stdin channel after it has been opened by
- // a single attach. When stdin is true the stdin stream will remain open across multiple attach
- // sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the
- // first client attaches to stdin, and then remains open and accepts data until the client disconnects,
- // at which time stdin is closed and remains closed until the container is restarted. If this
- // flag is false, a container processes that reads from stdin will never receive an EOF.
- // Default is false
- optional bool stdinOnce = 17;
-
- // Whether this container should allocate a TTY for itself, also requires 'stdin' to be true.
- // Default is false.
- optional bool tty = 18;
-}
-
-// Describe a container image
-message ContainerImage {
- // Names by which this image is known.
- // e.g. ["gcr.io/google_containers/hyperkube:v1.0.7", "dockerhub.io/google_containers/hyperkube:v1.0.7"]
- repeated string names = 1;
-
- // The size of the image in bytes.
- optional int64 sizeBytes = 2;
-}
-
-// ContainerPort represents a network port in a single container.
-message ContainerPort {
- // If specified, this must be an IANA_SVC_NAME and unique within the pod. Each
- // named port in a pod must have a unique name. Name for the port that can be
- // referred to by services.
- optional string name = 1;
-
- // Number of port to expose on the host.
- // If specified, this must be a valid port number, 0 < x < 65536.
- // If HostNetwork is specified, this must match ContainerPort.
- // Most containers do not need this.
- optional int32 hostPort = 2;
-
- // Number of port to expose on the pod's IP address.
- // This must be a valid port number, 0 < x < 65536.
- optional int32 containerPort = 3;
-
- // Protocol for port. Must be UDP or TCP.
- // Defaults to "TCP".
- optional string protocol = 4;
-
- // What host IP to bind the external port to.
- optional string hostIP = 5;
-}
-
-// ContainerState holds a possible state of container.
-// Only one of its members may be specified.
-// If none of them is specified, the default one is ContainerStateWaiting.
-message ContainerState {
- // Details about a waiting container
- optional ContainerStateWaiting waiting = 1;
-
- // Details about a running container
- optional ContainerStateRunning running = 2;
-
- // Details about a terminated container
- optional ContainerStateTerminated terminated = 3;
-}
-
-// ContainerStateRunning is a running state of a container.
-message ContainerStateRunning {
- // Time at which the container was last (re-)started
- optional k8s.io.kubernetes.pkg.api.unversioned.Time startedAt = 1;
-}
-
-// ContainerStateTerminated is a terminated state of a container.
-message ContainerStateTerminated {
- // Exit status from the last termination of the container
- optional int32 exitCode = 1;
-
- // Signal from the last termination of the container
- optional int32 signal = 2;
-
- // (brief) reason from the last termination of the container
- optional string reason = 3;
-
- // Message regarding the last termination of the container
- optional string message = 4;
-
- // Time at which previous execution of the container started
- optional k8s.io.kubernetes.pkg.api.unversioned.Time startedAt = 5;
-
- // Time at which the container last terminated
- optional k8s.io.kubernetes.pkg.api.unversioned.Time finishedAt = 6;
-
- // Container's ID in the format 'docker://<container_id>'
- optional string containerID = 7;
-}
-
-// ContainerStateWaiting is a waiting state of a container.
-message ContainerStateWaiting {
- // (brief) reason the container is not yet running.
- optional string reason = 1;
-
- // Message regarding why the container is not yet running.
- optional string message = 2;
-}
-
-// ContainerStatus contains details for the current status of this container.
-message ContainerStatus {
- // This must be a DNS_LABEL. Each container in a pod must have a unique name.
- // Cannot be updated.
- optional string name = 1;
-
- // Details about the container's current condition.
- optional ContainerState state = 2;
-
- // Details about the container's last termination condition.
- optional ContainerState lastState = 3;
-
- // Specifies whether the container has passed its readiness probe.
- optional bool ready = 4;
-
- // The number of times the container has been restarted, currently based on
- // the number of dead containers that have not yet been removed.
- // Note that this is calculated from dead containers. But those containers are subject to
- // garbage collection. This value will get capped at 5 by GC.
- optional int32 restartCount = 5;
-
- // The image the container is running.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md
- // TODO(dchen1107): Which image the container is running with?
- optional string image = 6;
-
- // ImageID of the container's image.
- optional string imageID = 7;
-
- // Container's ID in the format 'docker://<container_id>'.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#container-information
- optional string containerID = 8;
-}
-
-// DaemonEndpoint contains information about a single Daemon endpoint.
-message DaemonEndpoint {
- // Port number of the given endpoint.
- optional int32 Port = 1;
-}
-
-// DeleteOptions may be provided when deleting an API object
-message DeleteOptions {
- // The duration in seconds before the object should be deleted. Value must be non-negative integer.
- // The value zero indicates delete immediately. If this value is nil, the default grace period for the
- // specified type will be used.
- // Defaults to a per object value if not specified. zero means delete immediately.
- optional int64 gracePeriodSeconds = 1;
-
- // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be
- // returned.
- optional Preconditions preconditions = 2;
-
- // Should the dependent objects be orphaned. If true/false, the "orphan"
- // finalizer will be added to/removed from the object's finalizers list.
- optional bool orphanDependents = 3;
-}
-
-// DownwardAPIVolumeFile represents information to create the file containing the pod field
-message DownwardAPIVolumeFile {
- // Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'
- optional string path = 1;
-
- // Required: Selects a field of the pod: only annotations, labels, name and namespace are supported.
- optional ObjectFieldSelector fieldRef = 2;
-
- // Selects a resource of the container: only resources limits and requests
- // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.
- optional ResourceFieldSelector resourceFieldRef = 3;
-}
-
-// DownwardAPIVolumeSource represents a volume containing downward API info.
-// Downward API volumes support ownership management and SELinux relabeling.
-message DownwardAPIVolumeSource {
- // Items is a list of downward API volume file
- repeated DownwardAPIVolumeFile items = 1;
-}
-
-// Represents an empty directory for a pod.
-// Empty directory volumes support ownership management and SELinux relabeling.
-message EmptyDirVolumeSource {
- // What type of storage medium should back this directory.
- // The default is "" which means to use the node's default medium.
- // Must be an empty string (default) or Memory.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir
- optional string medium = 1;
-}
-
-// EndpointAddress is a tuple that describes single IP address.
-message EndpointAddress {
- // The IP of this endpoint.
- // May not be loopback (127.0.0.0/8), link-local (169.254.0.0/16),
- // or link-local multicast ((224.0.0.0/24).
- // IPv6 is also accepted but not fully supported on all platforms. Also, certain
- // kubernetes components, like kube-proxy, are not IPv6 ready.
- // TODO: This should allow hostname or IP, See #4447.
- optional string ip = 1;
-
- // The Hostname of this endpoint
- optional string hostname = 3;
-
- // Reference to object providing the endpoint.
- optional ObjectReference targetRef = 2;
-}
-
-// EndpointPort is a tuple that describes a single port.
-message EndpointPort {
- // The name of this port (corresponds to ServicePort.Name).
- // Must be a DNS_LABEL.
- // Optional only if one port is defined.
- optional string name = 1;
-
- // The port number of the endpoint.
- optional int32 port = 2;
-
- // The IP protocol for this port.
- // Must be UDP or TCP.
- // Default is TCP.
- optional string protocol = 3;
-}
-
-// EndpointSubset is a group of addresses with a common set of ports. The
-// expanded set of endpoints is the Cartesian product of Addresses x Ports.
-// For example, given:
-// {
-// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
-// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
-// }
-// The resulting set of endpoints can be viewed as:
-// a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],
-// b: [ 10.10.1.1:309, 10.10.2.2:309 ]
-message EndpointSubset {
- // IP addresses which offer the related ports that are marked as ready. These endpoints
- // should be considered safe for load balancers and clients to utilize.
- repeated EndpointAddress addresses = 1;
-
- // IP addresses which offer the related ports but are not currently marked as ready
- // because they have not yet finished starting, have recently failed a readiness check,
- // or have recently failed a liveness check.
- repeated EndpointAddress notReadyAddresses = 2;
-
- // Port numbers available on the related IP addresses.
- repeated EndpointPort ports = 3;
-}
-
-// Endpoints is a collection of endpoints that implement the actual service. Example:
-// Name: "mysvc",
-// Subsets: [
-// {
-// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
-// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
-// },
-// {
-// Addresses: [{"ip": "10.10.3.3"}],
-// Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}]
-// },
-// ]
-message Endpoints {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // The set of all endpoints is the union of all subsets. Addresses are placed into
- // subsets according to the IPs they share. A single address with multiple ports,
- // some of which are ready and some of which are not (because they come from
- // different containers) will result in the address being displayed in different
- // subsets for the different ports. No address will appear in both Addresses and
- // NotReadyAddresses in the same subset.
- // Sets of addresses and ports that comprise a service.
- repeated EndpointSubset subsets = 2;
-}
-
-// EndpointsList is a list of endpoints.
-message EndpointsList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of endpoints.
- repeated Endpoints items = 2;
-}
-
-// EnvVar represents an environment variable present in a Container.
-message EnvVar {
- // Name of the environment variable. Must be a C_IDENTIFIER.
- optional string name = 1;
-
- // Variable references $(VAR_NAME) are expanded
- // using the previous defined environment variables in the container and
- // any service environment variables. If a variable cannot be resolved,
- // the reference in the input string will be unchanged. The $(VAR_NAME)
- // syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped
- // references will never be expanded, regardless of whether the variable
- // exists or not.
- // Defaults to "".
- optional string value = 2;
-
- // Source for the environment variable's value. Cannot be used if value is not empty.
- optional EnvVarSource valueFrom = 3;
-}
-
-// EnvVarSource represents a source for the value of an EnvVar.
-message EnvVarSource {
- // Selects a field of the pod; only name and namespace are supported.
- optional ObjectFieldSelector fieldRef = 1;
-
- // Selects a resource of the container: only resources limits and requests
- // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.
- optional ResourceFieldSelector resourceFieldRef = 2;
-
- // Selects a key of a ConfigMap.
- optional ConfigMapKeySelector configMapKeyRef = 3;
-
- // Selects a key of a secret in the pod's namespace
- optional SecretKeySelector secretKeyRef = 4;
-}
-
-// Event is a report of an event somewhere in the cluster.
-// TODO: Decide whether to store these separately or with the object they apply to.
-message Event {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // The object that this event is about.
- optional ObjectReference involvedObject = 2;
-
- // This should be a short, machine understandable string that gives the reason
- // for the transition into the object's current status.
- // TODO: provide exact specification for format.
- optional string reason = 3;
-
- // A human-readable description of the status of this operation.
- // TODO: decide on maximum length.
- optional string message = 4;
-
- // The component reporting this event. Should be a short machine understandable string.
- optional EventSource source = 5;
-
- // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)
- optional k8s.io.kubernetes.pkg.api.unversioned.Time firstTimestamp = 6;
-
- // The time at which the most recent occurrence of this event was recorded.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTimestamp = 7;
-
- // The number of times this event has occurred.
- optional int32 count = 8;
-
- // Type of this event (Normal, Warning), new types could be added in the future
- optional string type = 9;
-}
-
-// EventList is a list of events.
-message EventList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of events
- repeated Event items = 2;
-}
-
-// EventSource contains information for an event.
-message EventSource {
- // Component from which the event is generated.
- optional string component = 1;
-
- // Host name on which the event is generated.
- optional string host = 2;
-}
-
-// ExecAction describes a "run in container" action.
-message ExecAction {
- // Command is the command line to execute inside the container, the working directory for the
- // command is root ('/') in the container's filesystem. The command is simply exec'd, it is
- // not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use
- // a shell, you need to explicitly call out to that shell.
- // Exit status of 0 is treated as live/healthy and non-zero is unhealthy.
- repeated string command = 1;
-}
-
-// ExportOptions is the query options to the standard REST get call.
-message ExportOptions {
- // Should this value be exported. Export strips fields that a user can not specify.
- optional bool export = 1;
-
- // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
- optional bool exact = 2;
-}
-
-// Represents a Fibre Channel volume.
-// Fibre Channel volumes can only be mounted as read/write once.
-// Fibre Channel volumes support ownership management and SELinux relabeling.
-message FCVolumeSource {
- // Required: FC target world wide names (WWNs)
- repeated string targetWWNs = 1;
-
- // Required: FC target lun number
- optional int32 lun = 2;
-
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- optional string fsType = 3;
-
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- optional bool readOnly = 4;
-}
-
-// FlexVolume represents a generic volume resource that is
-// provisioned/attached using a exec based plugin. This is an alpha feature and may change in future.
-message FlexVolumeSource {
- // Driver is the name of the driver to use for this volume.
- optional string driver = 1;
-
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script.
- optional string fsType = 2;
-
- // Optional: SecretRef is reference to the secret object containing
- // sensitive information to pass to the plugin scripts. This may be
- // empty if no secret object is specified. If the secret object
- // contains more than one secret, all secrets are passed to the plugin
- // scripts.
- optional LocalObjectReference secretRef = 3;
-
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- optional bool readOnly = 4;
-
- // Optional: Extra command options if any.
- map<string, string> options = 5;
-}
-
-// Represents a Flocker volume mounted by the Flocker agent.
-// Flocker volumes do not support ownership management or SELinux relabeling.
-message FlockerVolumeSource {
- // Required: the volume name. This is going to be store on metadata -> name on the payload for Flocker
- optional string datasetName = 1;
-}
-
-// Represents a Persistent Disk resource in Google Compute Engine.
-//
-// A GCE PD must exist before mounting to a container. The disk must
-// also be in the same GCE project and zone as the kubelet. A GCE PD
-// can only be mounted as read/write once or read-only many times. GCE
-// PDs support ownership management and SELinux relabeling.
-message GCEPersistentDiskVolumeSource {
- // Unique name of the PD resource in GCE. Used to identify the disk in GCE.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- optional string pdName = 1;
-
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- optional string fsType = 2;
-
- // The partition in the volume that you want to mount.
- // If omitted, the default is to mount by volume name.
- // Examples: For volume /dev/sda1, you specify the partition as "1".
- // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- optional int32 partition = 3;
-
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- optional bool readOnly = 4;
-}
-
-// Represents a volume that is populated with the contents of a git repository.
-// Git repo volumes do not support ownership management.
-// Git repo volumes support SELinux relabeling.
-message GitRepoVolumeSource {
- // Repository URL
- optional string repository = 1;
-
- // Commit hash for the specified revision.
- optional string revision = 2;
-
- // Target directory name.
- // Must not contain or start with '..'. If '.' is supplied, the volume directory will be the
- // git repository. Otherwise, if specified, the volume will contain the git repository in
- // the subdirectory with the given name.
- optional string directory = 3;
-}
-
-// Represents a Glusterfs mount that lasts the lifetime of a pod.
-// Glusterfs volumes do not support ownership management or SELinux relabeling.
-message GlusterfsVolumeSource {
- // EndpointsName is the endpoint name that details Glusterfs topology.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- optional string endpoints = 1;
-
- // Path is the Glusterfs volume path.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- optional string path = 2;
-
- // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- optional bool readOnly = 3;
-}
-
-// HTTPGetAction describes an action based on HTTP Get requests.
-message HTTPGetAction {
- // Path to access on the HTTP server.
- optional string path = 1;
-
- // Name or number of the port to access on the container.
- // Number must be in the range 1 to 65535.
- // Name must be an IANA_SVC_NAME.
- optional k8s.io.kubernetes.pkg.util.intstr.IntOrString port = 2;
-
- // Host name to connect to, defaults to the pod IP. You probably want to set
- // "Host" in httpHeaders instead.
- optional string host = 3;
-
- // Scheme to use for connecting to the host.
- // Defaults to HTTP.
- optional string scheme = 4;
-
- // Custom headers to set in the request. HTTP allows repeated headers.
- repeated HTTPHeader httpHeaders = 5;
-}
-
-// HTTPHeader describes a custom header to be used in HTTP probes
-message HTTPHeader {
- // The header field name
- optional string name = 1;
-
- // The header field value
- optional string value = 2;
-}
-
-// Handler defines a specific action that should be taken
-// TODO: pass structured data to these actions, and document that data here.
-message Handler {
- // One and only one of the following should be specified.
- // Exec specifies the action to take.
- optional ExecAction exec = 1;
-
- // HTTPGet specifies the http request to perform.
- optional HTTPGetAction httpGet = 2;
-
- // TCPSocket specifies an action involving a TCP port.
- // TCP hooks not yet supported
- // TODO: implement a realistic TCP lifecycle hook
- optional TCPSocketAction tcpSocket = 3;
-}
-
-// Represents a host path mapped into a pod.
-// Host path volumes do not support ownership management or SELinux relabeling.
-message HostPathVolumeSource {
- // Path of the directory on the host.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- optional string path = 1;
-}
-
-// Represents an ISCSI disk.
-// ISCSI volumes can only be mounted as read/write once.
-// ISCSI volumes support ownership management and SELinux relabeling.
-message ISCSIVolumeSource {
- // iSCSI target portal. The portal is either an IP or ip_addr:port if the port
- // is other than default (typically TCP ports 860 and 3260).
- optional string targetPortal = 1;
-
- // Target iSCSI Qualified Name.
- optional string iqn = 2;
-
- // iSCSI target lun number.
- optional int32 lun = 3;
-
- // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport.
- optional string iscsiInterface = 4;
-
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#iscsi
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- optional string fsType = 5;
-
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- optional bool readOnly = 6;
-}
-
-// Maps a string key to a path within a volume.
-message KeyToPath {
- // The key to project.
- optional string key = 1;
-
- // The relative path of the file to map the key to.
- // May not be an absolute path.
- // May not contain the path element '..'.
- // May not start with the string '..'.
- optional string path = 2;
-}
-
-// Lifecycle describes actions that the management system should take in response to container lifecycle
-// events. For the PostStart and PreStop lifecycle handlers, management of the container blocks
-// until the action is complete, unless the container process fails, in which case the handler is aborted.
-message Lifecycle {
- // PostStart is called immediately after a container is created. If the handler fails,
- // the container is terminated and restarted according to its restart policy.
- // Other management of the container blocks until the hook completes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details
- optional Handler postStart = 1;
-
- // PreStop is called immediately before a container is terminated.
- // The container is terminated after the handler completes.
- // The reason for termination is passed to the handler.
- // Regardless of the outcome of the handler, the container is eventually terminated.
- // Other management of the container blocks until the hook completes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details
- optional Handler preStop = 2;
-}
-
-// LimitRange sets resource usage limits for each kind of resource in a Namespace.
-message LimitRange {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the limits enforced.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional LimitRangeSpec spec = 2;
-}
-
-// LimitRangeItem defines a min/max usage limit for any resource that matches on kind.
-message LimitRangeItem {
- // Type of resource that this limit applies to.
- optional string type = 1;
-
- // Max usage constraints on this kind by resource name.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> max = 2;
-
- // Min usage constraints on this kind by resource name.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> min = 3;
-
- // Default resource requirement limit value by resource name if resource limit is omitted.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> default = 4;
-
- // DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> defaultRequest = 5;
-
- // MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> maxLimitRequestRatio = 6;
-}
-
-// LimitRangeList is a list of LimitRange items.
-message LimitRangeList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // Items is a list of LimitRange objects.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md
- repeated LimitRange items = 2;
-}
-
-// LimitRangeSpec defines a min/max usage limit for resources that match on kind.
-message LimitRangeSpec {
- // Limits is the list of LimitRangeItem objects that are enforced.
- repeated LimitRangeItem limits = 1;
-}
-
-// List holds a list of objects, which may not be known by the server.
-message List {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of objects
- repeated k8s.io.kubernetes.pkg.runtime.RawExtension items = 2;
-}
-
-// ListOptions is the query options to a standard REST list call.
-message ListOptions {
- // A selector to restrict the list of returned objects by their labels.
- // Defaults to everything.
- optional string labelSelector = 1;
-
- // A selector to restrict the list of returned objects by their fields.
- // Defaults to everything.
- optional string fieldSelector = 2;
-
- // Watch for changes to the described resources and return them as a stream of
- // add, update, and remove notifications. Specify resourceVersion.
- optional bool watch = 3;
-
- // When specified with a watch call, shows changes that occur after that particular version of a resource.
- // Defaults to changes from the beginning of history.
- optional string resourceVersion = 4;
-
- // Timeout for the list/watch call.
- optional int64 timeoutSeconds = 5;
-}
-
-// LoadBalancerIngress represents the status of a load-balancer ingress point:
-// traffic intended for the service should be sent to an ingress point.
-message LoadBalancerIngress {
- // IP is set for load-balancer ingress points that are IP based
- // (typically GCE or OpenStack load-balancers)
- optional string ip = 1;
-
- // Hostname is set for load-balancer ingress points that are DNS based
- // (typically AWS load-balancers)
- optional string hostname = 2;
-}
-
-// LoadBalancerStatus represents the status of a load-balancer.
-message LoadBalancerStatus {
- // Ingress is a list containing ingress points for the load-balancer.
- // Traffic intended for the service should be sent to these ingress points.
- repeated LoadBalancerIngress ingress = 1;
-}
-
-// LocalObjectReference contains enough information to let you locate the
-// referenced object inside the same namespace.
-message LocalObjectReference {
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- // TODO: Add other useful fields. apiVersion, kind, uid?
- optional string name = 1;
-}
-
-// Represents an NFS mount that lasts the lifetime of a pod.
-// NFS volumes do not support ownership management or SELinux relabeling.
-message NFSVolumeSource {
- // Server is the hostname or IP address of the NFS server.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- optional string server = 1;
-
- // Path that is exported by the NFS server.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- optional string path = 2;
-
- // ReadOnly here will force
- // the NFS export to be mounted with read-only permissions.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- optional bool readOnly = 3;
-}
-
-// Namespace provides a scope for Names.
-// Use of multiple namespaces is optional.
-message Namespace {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the behavior of the Namespace.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional NamespaceSpec spec = 2;
-
- // Status describes the current status of a Namespace.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional NamespaceStatus status = 3;
-}
-
-// NamespaceList is a list of Namespaces.
-message NamespaceList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // Items is the list of Namespace objects in the list.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- repeated Namespace items = 2;
-}
-
-// NamespaceSpec describes the attributes on a Namespace.
-message NamespaceSpec {
- // Finalizers is an opaque list of values that must be empty to permanently remove object from storage.
- // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers
- repeated string finalizers = 1;
-}
-
-// NamespaceStatus is information about the current status of a Namespace.
-message NamespaceStatus {
- // Phase is the current lifecycle phase of the namespace.
- // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases
- optional string phase = 1;
-}
-
-// Node is a worker node in Kubernetes, formerly known as minion.
-// Each node will have a unique identifier in the cache (i.e. in etcd).
-message Node {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the behavior of a node.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional NodeSpec spec = 2;
-
- // Most recently observed status of the node.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional NodeStatus status = 3;
-}
-
-// NodeAddress contains information for the node's address.
-message NodeAddress {
- // Node address type, one of Hostname, ExternalIP or InternalIP.
- optional string type = 1;
-
- // The node address.
- optional string address = 2;
-}
-
-// Node affinity is a group of node affinity scheduling rules.
-message NodeAffinity {
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to an update), the system
- // may or may not try to eventually evict the pod from its node.
- optional NodeSelector requiredDuringSchedulingIgnoredDuringExecution = 1;
-
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node matches the corresponding matchExpressions; the
- // node(s) with the highest sum are the most preferred.
- repeated PreferredSchedulingTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
-}
-
-// NodeCondition contains condition infromation for a node.
-message NodeCondition {
- // Type of node condition.
- optional string type = 1;
-
- // Status of the condition, one of True, False, Unknown.
- optional string status = 2;
-
- // Last time we got an update on a given condition.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time lastHeartbeatTime = 3;
-
- // Last time the condition transit from one status to another.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4;
-
- // (brief) reason for the condition's last transition.
- optional string reason = 5;
-
- // Human readable message indicating details about last transition.
- optional string message = 6;
-}
-
-// NodeDaemonEndpoints lists ports opened by daemons running on the Node.
-message NodeDaemonEndpoints {
- // Endpoint on which Kubelet is listening.
- optional DaemonEndpoint kubeletEndpoint = 1;
-}
-
-// NodeList is the whole list of all Nodes which have been registered with master.
-message NodeList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of nodes
- repeated Node items = 2;
-}
-
-// NodeProxyOptions is the query options to a Node's proxy call.
-message NodeProxyOptions {
- // Path is the URL path to use for the current proxy request to node.
- optional string path = 1;
-}
-
-// A node selector represents the union of the results of one or more label queries
-// over a set of nodes; that is, it represents the OR of the selectors represented
-// by the node selector terms.
-message NodeSelector {
- // Required. A list of node selector terms. The terms are ORed.
- repeated NodeSelectorTerm nodeSelectorTerms = 1;
-}
-
-// A node selector requirement is a selector that contains values, a key, and an operator
-// that relates the key and values.
-message NodeSelectorRequirement {
- // The label key that the selector applies to.
- optional string key = 1;
-
- // Represents a key's relationship to a set of values.
- // Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.
- optional string operator = 2;
-
- // An array of string values. If the operator is In or NotIn,
- // the values array must be non-empty. If the operator is Exists or DoesNotExist,
- // the values array must be empty. If the operator is Gt or Lt, the values
- // array must have a single element, which will be interpreted as an integer.
- // This array is replaced during a strategic merge patch.
- repeated string values = 3;
-}
-
-// A null or empty node selector term matches no objects.
-message NodeSelectorTerm {
- // Required. A list of node selector requirements. The requirements are ANDed.
- repeated NodeSelectorRequirement matchExpressions = 1;
-}
-
-// NodeSpec describes the attributes that a node is created with.
-message NodeSpec {
- // PodCIDR represents the pod IP range assigned to the node.
- optional string podCIDR = 1;
-
- // External ID of the node assigned by some machine database (e.g. a cloud provider).
- // Deprecated.
- optional string externalID = 2;
-
- // ID of the node assigned by the cloud provider in the format: <ProviderName>://<ProviderSpecificNodeID>
- optional string providerID = 3;
-
- // Unschedulable controls node schedulability of new pods. By default, node is schedulable.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration"`
- optional bool unschedulable = 4;
-}
-
-// NodeStatus is information about the current status of a node.
-message NodeStatus {
- // Capacity represents the total resources of a node.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity for more details.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> capacity = 1;
-
- // Allocatable represents the resources of a node that are available for scheduling.
- // Defaults to Capacity.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> allocatable = 2;
-
- // NodePhase is the recently observed lifecycle phase of the node.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase
- optional string phase = 3;
-
- // Conditions is an array of current observed node conditions.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition
- repeated NodeCondition conditions = 4;
-
- // List of addresses reachable to the node.
- // Queried from cloud provider, if available.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses
- repeated NodeAddress addresses = 5;
-
- // Endpoints of daemons running on the Node.
- optional NodeDaemonEndpoints daemonEndpoints = 6;
-
- // Set of ids/uuids to uniquely identify the node.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info
- optional NodeSystemInfo nodeInfo = 7;
-
- // List of container images on this node
- repeated ContainerImage images = 8;
-
- // List of attachable volumes in use (mounted) by the node.
- repeated string volumesInUse = 9;
-
- // List of volumes that are attached to the node.
- repeated AttachedVolume volumesAttached = 10;
-}
-
-// NodeSystemInfo is a set of ids/uuids to uniquely identify the node.
-message NodeSystemInfo {
- // Machine ID reported by the node.
- optional string machineID = 1;
-
- // System UUID reported by the node.
- optional string systemUUID = 2;
-
- // Boot ID reported by the node.
- optional string bootID = 3;
-
- // Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).
- optional string kernelVersion = 4;
-
- // OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).
- optional string osImage = 5;
-
- // ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0).
- optional string containerRuntimeVersion = 6;
-
- // Kubelet Version reported by the node.
- optional string kubeletVersion = 7;
-
- // KubeProxy Version reported by the node.
- optional string kubeProxyVersion = 8;
-
- // The Operating System reported by the node
- optional string operatingSystem = 9;
-
- // The Architecture reported by the node
- optional string architecture = 10;
-}
-
-// ObjectFieldSelector selects an APIVersioned field of an object.
-message ObjectFieldSelector {
- // Version of the schema the FieldPath is written in terms of, defaults to "v1".
- optional string apiVersion = 1;
-
- // Path of the field to select in the specified API version.
- optional string fieldPath = 2;
-}
-
-// ObjectMeta is metadata that all persisted resources must have, which includes all objects
-// users must create.
-message ObjectMeta {
- // Name must be unique within a namespace. Is required when creating resources, although
- // some resources may allow a client to request the generation of an appropriate name
- // automatically. Name is primarily intended for creation idempotence and configuration
- // definition.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- optional string name = 1;
-
- // GenerateName is an optional prefix, used by the server, to generate a unique
- // name ONLY IF the Name field has not been provided.
- // If this field is used, the name returned to the client will be different
- // than the name passed. This value will also be combined with a unique suffix.
- // The provided value has the same validation rules as the Name field,
- // and may be truncated by the length of the suffix required to make the value
- // unique on the server.
- //
- // If this field is specified and the generated name exists, the server will
- // NOT return a 409 - instead, it will either return 201 Created or 500 with Reason
- // ServerTimeout indicating a unique name could not be found in the time allotted, and the client
- // should retry (optionally after the time indicated in the Retry-After header).
- //
- // Applied only if Name is not specified.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency
- optional string generateName = 2;
-
- // Namespace defines the space within each name must be unique. An empty namespace is
- // equivalent to the "default" namespace, but "default" is the canonical representation.
- // Not all objects are required to be scoped to a namespace - the value of this field for
- // those objects will be empty.
- //
- // Must be a DNS_LABEL.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- optional string namespace = 3;
-
- // SelfLink is a URL representing this object.
- // Populated by the system.
- // Read-only.
- optional string selfLink = 4;
-
- // UID is the unique in time and space value for this object. It is typically generated by
- // the server on successful creation of a resource and is not allowed to change on PUT
- // operations.
- //
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- optional string uid = 5;
-
- // An opaque value that represents the internal version of this object that can
- // be used by clients to determine when objects have changed. May be used for optimistic
- // concurrency, change detection, and the watch operation on a resource or set of resources.
- // Clients must treat these values as opaque and passed unmodified back to the server.
- // They may only be valid for a particular resource or set of resources.
- //
- // Populated by the system.
- // Read-only.
- // Value must be treated as opaque by clients and .
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
- optional string resourceVersion = 6;
-
- // A sequence number representing a specific generation of the desired state.
- // Populated by the system. Read-only.
- optional int64 generation = 7;
-
- // CreationTimestamp is a timestamp representing the server time when this object was
- // created. It is not guaranteed to be set in happens-before order across separate operations.
- // Clients may not set this value. It is represented in RFC3339 form and is in UTC.
- //
- // Populated by the system.
- // Read-only.
- // Null for lists.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional k8s.io.kubernetes.pkg.api.unversioned.Time creationTimestamp = 8;
-
- // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This
- // field is set by the server when a graceful deletion is requested by the user, and is not
- // directly settable by a client. The resource will be deleted (no longer visible from
- // resource lists, and not reachable by name) after the time in this field. Once set, this
- // value may not be unset or be set further into the future, although it may be shortened
- // or the resource may be deleted prior to this time. For example, a user may request that
- // a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination
- // signal to the containers in the pod. Once the resource is deleted in the API, the Kubelet
- // will send a hard termination signal to the container.
- // If not set, graceful deletion of the object has not been requested.
- //
- // Populated by the system when a graceful deletion is requested.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional k8s.io.kubernetes.pkg.api.unversioned.Time deletionTimestamp = 9;
-
- // Number of seconds allowed for this object to gracefully terminate before
- // it will be removed from the system. Only set when deletionTimestamp is also set.
- // May only be shortened.
- // Read-only.
- optional int64 deletionGracePeriodSeconds = 10;
-
- // Map of string keys and values that can be used to organize and categorize
- // (scope and select) objects. May match selectors of replication controllers
- // and services.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md
- // TODO: replace map[string]string with labels.LabelSet type
- map<string, string> labels = 11;
-
- // Annotations is an unstructured key value map stored with a resource that may be
- // set by external tools to store and retrieve arbitrary metadata. They are not
- // queryable and should be preserved when modifying objects.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/annotations.md
- map<string, string> annotations = 12;
-
- // List of objects depended by this object. If ALL objects in the list have
- // been deleted, this object will be garbage collected. If this object is managed by a controller,
- // then an entry in this list will point to this controller, with the controller field set to true.
- // There cannot be more than one managing controller.
- repeated OwnerReference ownerReferences = 13;
-
- // Must be empty before the object is deleted from the registry. Each entry
- // is an identifier for the responsible component that will remove the entry
- // from the list. If the deletionTimestamp of the object is non-nil, entries
- // in this list can only be removed.
- repeated string finalizers = 14;
-}
-
-// ObjectReference contains enough information to let you inspect or modify the referred object.
-message ObjectReference {
- // Kind of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional string kind = 1;
-
- // Namespace of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- optional string namespace = 2;
-
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- optional string name = 3;
-
- // UID of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- optional string uid = 4;
-
- // API version of the referent.
- optional string apiVersion = 5;
-
- // Specific resourceVersion to which this reference is made, if any.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
- optional string resourceVersion = 6;
-
- // If referring to a piece of an object instead of an entire object, this string
- // should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2].
- // For example, if the object reference is to a container within a pod, this would take on a value like:
- // "spec.containers{name}" (where "name" refers to the name of the container that triggered
- // the event) or if no container name is specified "spec.containers[2]" (container with
- // index 2 in this pod). This syntax is chosen only to have some well-defined way of
- // referencing a part of an object.
- // TODO: this design is not final and this field is subject to change in the future.
- optional string fieldPath = 7;
-}
-
-// OwnerReference contains enough information to let you identify an owning
-// object. Currently, an owning object must be in the same namespace, so there
-// is no namespace field.
-message OwnerReference {
- // API version of the referent.
- optional string apiVersion = 5;
-
- // Kind of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional string kind = 1;
-
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- optional string name = 3;
-
- // UID of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- optional string uid = 4;
-
- // If true, this reference points to the managing controller.
- optional bool controller = 6;
-}
-
-// PersistentVolume (PV) is a storage resource provisioned by an administrator.
-// It is analogous to a node.
-// More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md
-message PersistentVolume {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines a specification of a persistent volume owned by the cluster.
- // Provisioned by an administrator.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes
- optional PersistentVolumeSpec spec = 2;
-
- // Status represents the current information/status for the persistent volume.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes
- optional PersistentVolumeStatus status = 3;
-}
-
-// PersistentVolumeClaim is a user's request for and claim to a persistent volume
-message PersistentVolumeClaim {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the desired characteristics of a volume requested by a pod author.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- optional PersistentVolumeClaimSpec spec = 2;
-
- // Status represents the current information/status of a persistent volume claim.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- optional PersistentVolumeClaimStatus status = 3;
-}
-
-// PersistentVolumeClaimList is a list of PersistentVolumeClaim items.
-message PersistentVolumeClaimList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // A list of persistent volume claims.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- repeated PersistentVolumeClaim items = 2;
-}
-
-// PersistentVolumeClaimSpec describes the common attributes of storage devices
-// and allows a Source for provider-specific attributes
-message PersistentVolumeClaimSpec {
- // AccessModes contains the desired access modes the volume should have.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1
- repeated string accessModes = 1;
-
- // A label query over volumes to consider for binding.
- optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 4;
-
- // Resources represents the minimum resources the volume should have.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources
- optional ResourceRequirements resources = 2;
-
- // VolumeName is the binding reference to the PersistentVolume backing this claim.
- optional string volumeName = 3;
-}
-
-// PersistentVolumeClaimStatus is the current status of a persistent volume claim.
-message PersistentVolumeClaimStatus {
- // Phase represents the current phase of PersistentVolumeClaim.
- optional string phase = 1;
-
- // AccessModes contains the actual access modes the volume backing the PVC has.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1
- repeated string accessModes = 2;
-
- // Represents the actual resources of the underlying volume.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> capacity = 3;
-}
-
-// PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace.
-// This volume finds the bound PV and mounts that volume for the pod. A
-// PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another
-// type of volume that is owned by someone else (the system).
-message PersistentVolumeClaimVolumeSource {
- // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- optional string claimName = 1;
-
- // Will force the ReadOnly setting in VolumeMounts.
- // Default false.
- optional bool readOnly = 2;
-}
-
-// PersistentVolumeList is a list of PersistentVolume items.
-message PersistentVolumeList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of persistent volumes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md
- repeated PersistentVolume items = 2;
-}
-
-// PersistentVolumeSource is similar to VolumeSource but meant for the
-// administrator who creates PVs. Exactly one of its members must be set.
-message PersistentVolumeSource {
- // GCEPersistentDisk represents a GCE Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- optional GCEPersistentDiskVolumeSource gcePersistentDisk = 1;
-
- // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 2;
-
- // HostPath represents a directory on the host.
- // Provisioned by a developer or tester.
- // This is useful for single-node development and testing only!
- // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- optional HostPathVolumeSource hostPath = 3;
-
- // Glusterfs represents a Glusterfs volume that is attached to a host and
- // exposed to the pod. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
- optional GlusterfsVolumeSource glusterfs = 4;
-
- // NFS represents an NFS mount on the host. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- optional NFSVolumeSource nfs = 5;
-
- // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
- optional RBDVolumeSource rbd = 6;
-
- // ISCSI represents an ISCSI Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
- optional ISCSIVolumeSource iscsi = 7;
-
- // Cinder represents a cinder volume attached and mounted on kubelets host machine
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- optional CinderVolumeSource cinder = 8;
-
- // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
- optional CephFSVolumeSource cephfs = 9;
-
- // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
- optional FCVolumeSource fc = 10;
-
- // Flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running
- optional FlockerVolumeSource flocker = 11;
-
- // FlexVolume represents a generic volume resource that is
- // provisioned/attached using a exec based plugin. This is an
- // alpha feature and may change in future.
- optional FlexVolumeSource flexVolume = 12;
-
- // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
- optional AzureFileVolumeSource azureFile = 13;
-
- // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
- optional VsphereVirtualDiskVolumeSource vsphereVolume = 14;
-}
-
-// PersistentVolumeSpec is the specification of a persistent volume.
-message PersistentVolumeSpec {
- // A description of the persistent volume's resources and capacity.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> capacity = 1;
-
- // The actual volume backing the persistent volume.
- optional PersistentVolumeSource persistentVolumeSource = 2;
-
- // AccessModes contains all ways the volume can be mounted.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes
- repeated string accessModes = 3;
-
- // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim.
- // Expected to be non-nil when bound.
- // claim.VolumeName is the authoritative bind between PV and PVC.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#binding
- optional ObjectReference claimRef = 4;
-
- // What happens to a persistent volume when released from its claim.
- // Valid options are Retain (default) and Recycle.
- // Recyling must be supported by the volume plugin underlying this persistent volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#recycling-policy
- optional string persistentVolumeReclaimPolicy = 5;
-}
-
-// PersistentVolumeStatus is the current status of a persistent volume.
-message PersistentVolumeStatus {
- // Phase indicates if a volume is available, bound to a claim, or released by a claim.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#phase
- optional string phase = 1;
-
- // A human-readable message indicating details about why the volume is in this state.
- optional string message = 2;
-
- // Reason is a brief CamelCase string that describes any failure and is meant
- // for machine parsing and tidy display in the CLI.
- optional string reason = 3;
-}
-
-// Pod is a collection of containers that can run on a host. This resource is created
-// by clients and scheduled onto hosts.
-message Pod {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Specification of the desired behavior of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional PodSpec spec = 2;
-
- // Most recently observed status of the pod.
- // This data may not be up to date.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional PodStatus status = 3;
-}
-
-// Pod affinity is a group of inter pod affinity scheduling rules.
-message PodAffinity {
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system will try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"`
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system may or may not try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- repeated PodAffinityTerm requiredDuringSchedulingIgnoredDuringExecution = 1;
-
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
- // node(s) with the highest sum are the most preferred.
- repeated WeightedPodAffinityTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
-}
-
-// Defines a set of pods (namely those matching the labelSelector
-// relative to the given namespace(s)) that this pod should be
-// co-located (affinity) or not co-located (anti-affinity) with,
-// where co-located is defined as running on a node whose value of
-// the label with key <topologyKey> tches that of any node on which
-// a pod of the set of pods is running
-message PodAffinityTerm {
- // A label query over a set of resources, in this case pods.
- optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector labelSelector = 1;
-
- // namespaces specifies which namespaces the labelSelector applies to (matches against);
- // nil list means "this pod's namespace," empty list means "all namespaces"
- // The json tag here is not "omitempty" since we need to distinguish nil and empty.
- // See https://golang.org/pkg/encoding/json/#Marshal for more details.
- repeated string namespaces = 2;
-
- // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
- // the labelSelector in the specified namespaces, where co-located is defined as running on a node
- // whose value of the label with key topologyKey matches that of any node on which any of the
- // selected pods is running.
- // For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies"
- // ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains);
- // for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed.
- optional string topologyKey = 3;
-}
-
-// Pod anti affinity is a group of inter pod anti affinity scheduling rules.
-message PodAntiAffinity {
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // If the anti-affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the anti-affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system will try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"`
- // If the anti-affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the anti-affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system may or may not try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- repeated PodAffinityTerm requiredDuringSchedulingIgnoredDuringExecution = 1;
-
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the anti-affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling anti-affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
- // node(s) with the highest sum are the most preferred.
- repeated WeightedPodAffinityTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
-}
-
-// PodAttachOptions is the query options to a Pod's remote attach call.
-// ---
-// TODO: merge w/ PodExecOptions below for stdin, stdout, etc
-// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
-message PodAttachOptions {
- // Stdin if true, redirects the standard input stream of the pod for this call.
- // Defaults to false.
- optional bool stdin = 1;
-
- // Stdout if true indicates that stdout is to be redirected for the attach call.
- // Defaults to true.
- optional bool stdout = 2;
-
- // Stderr if true indicates that stderr is to be redirected for the attach call.
- // Defaults to true.
- optional bool stderr = 3;
-
- // TTY if true indicates that a tty will be allocated for the attach call.
- // This is passed through the container runtime so the tty
- // is allocated on the worker node by the container runtime.
- // Defaults to false.
- optional bool tty = 4;
-
- // The container in which to execute the command.
- // Defaults to only container if there is only one container in the pod.
- optional string container = 5;
-}
-
-// PodCondition contains details for the current condition of this pod.
-message PodCondition {
- // Type is the type of the condition.
- // Currently only Ready.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- optional string type = 1;
-
- // Status is the status of the condition.
- // Can be True, False, Unknown.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- optional string status = 2;
-
- // Last time we probed the condition.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3;
-
- // Last time the condition transitioned from one status to another.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4;
-
- // Unique, one-word, CamelCase reason for the condition's last transition.
- optional string reason = 5;
-
- // Human-readable message indicating details about last transition.
- optional string message = 6;
-}
-
-// PodExecOptions is the query options to a Pod's remote exec call.
-// ---
-// TODO: This is largely identical to PodAttachOptions above, make sure they stay in sync and see about merging
-// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
-message PodExecOptions {
- // Redirect the standard input stream of the pod for this call.
- // Defaults to false.
- optional bool stdin = 1;
-
- // Redirect the standard output stream of the pod for this call.
- // Defaults to true.
- optional bool stdout = 2;
-
- // Redirect the standard error stream of the pod for this call.
- // Defaults to true.
- optional bool stderr = 3;
-
- // TTY if true indicates that a tty will be allocated for the exec call.
- // Defaults to false.
- optional bool tty = 4;
-
- // Container in which to execute the command.
- // Defaults to only container if there is only one container in the pod.
- optional string container = 5;
-
- // Command is the remote command to execute. argv array. Not executed within a shell.
- repeated string command = 6;
-}
-
-// PodList is a list of Pods.
-message PodList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of pods.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pods.md
- repeated Pod items = 2;
-}
-
-// PodLogOptions is the query options for a Pod's logs REST call.
-message PodLogOptions {
- // The container for which to stream logs. Defaults to only container if there is one container in the pod.
- optional string container = 1;
-
- // Follow the log stream of the pod. Defaults to false.
- optional bool follow = 2;
-
- // Return previous terminated container logs. Defaults to false.
- optional bool previous = 3;
-
- // A relative time in seconds before the current time from which to show logs. If this value
- // precedes the time a pod was started, only logs since the pod start will be returned.
- // If this value is in the future, no logs will be returned.
- // Only one of sinceSeconds or sinceTime may be specified.
- optional int64 sinceSeconds = 4;
-
- // An RFC3339 timestamp from which to show logs. If this value
- // precedes the time a pod was started, only logs since the pod start will be returned.
- // If this value is in the future, no logs will be returned.
- // Only one of sinceSeconds or sinceTime may be specified.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time sinceTime = 5;
-
- // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line
- // of log output. Defaults to false.
- optional bool timestamps = 6;
-
- // If set, the number of lines from the end of the logs to show. If not specified,
- // logs are shown from the creation of the container or sinceSeconds or sinceTime
- optional int64 tailLines = 7;
-
- // If set, the number of bytes to read from the server before terminating the
- // log output. This may not display a complete final line of logging, and may return
- // slightly more or slightly less than the specified limit.
- optional int64 limitBytes = 8;
-}
-
-// PodProxyOptions is the query options to a Pod's proxy call.
-message PodProxyOptions {
- // Path is the URL path to use for the current proxy request to pod.
- optional string path = 1;
-}
-
-// PodSecurityContext holds pod-level security attributes and common container settings.
-// Some fields are also present in container.securityContext. Field values of
-// container.securityContext take precedence over field values of PodSecurityContext.
-message PodSecurityContext {
- // The SELinux context to be applied to all containers.
- // If unspecified, the container runtime will allocate a random SELinux context for each
- // container. May also be set in SecurityContext. If set in
- // both SecurityContext and PodSecurityContext, the value specified in SecurityContext
- // takes precedence for that container.
- optional SELinuxOptions seLinuxOptions = 1;
-
- // The UID to run the entrypoint of the container process.
- // Defaults to user specified in image metadata if unspecified.
- // May also be set in SecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence
- // for that container.
- optional int64 runAsUser = 2;
-
- // Indicates that the container must run as a non-root user.
- // If true, the Kubelet will validate the image at runtime to ensure that it
- // does not run as UID 0 (root) and fail to start the container if it does.
- // If unset or false, no such validation will be performed.
- // May also be set in SecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- optional bool runAsNonRoot = 3;
-
- // A list of groups applied to the first process run in each container, in addition
- // to the container's primary GID. If unspecified, no groups will be added to
- // any container.
- repeated int64 supplementalGroups = 4;
-
- // A special supplemental group that applies to all containers in a pod.
- // Some volume types allow the Kubelet to change the ownership of that volume
- // to be owned by the pod:
- //
- // 1. The owning GID will be the FSGroup
- // 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)
- // 3. The permission bits are OR'd with rw-rw----
- //
- // If unset, the Kubelet will not modify the ownership and permissions of any volume.
- optional int64 fsGroup = 5;
-}
-
-// PodSpec is a description of a pod.
-message PodSpec {
- // List of volumes that can be mounted by containers belonging to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md
- repeated Volume volumes = 1;
-
- // List of containers belonging to the pod.
- // Containers cannot currently be added or removed.
- // There must be at least one container in a Pod.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md
- repeated Container containers = 2;
-
- // Restart policy for all containers within the pod.
- // One of Always, OnFailure, Never.
- // Default to Always.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#restartpolicy
- optional string restartPolicy = 3;
-
- // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request.
- // Value must be non-negative integer. The value zero indicates delete immediately.
- // If this value is nil, the default grace period will be used instead.
- // The grace period is the duration in seconds after the processes running in the pod are sent
- // a termination signal and the time when the processes are forcibly halted with a kill signal.
- // Set this value longer than the expected cleanup time for your process.
- // Defaults to 30 seconds.
- optional int64 terminationGracePeriodSeconds = 4;
-
- // Optional duration in seconds the pod may be active on the node relative to
- // StartTime before the system will actively try to mark it failed and kill associated containers.
- // Value must be a positive integer.
- optional int64 activeDeadlineSeconds = 5;
-
- // Set DNS policy for containers within the pod.
- // One of 'ClusterFirst' or 'Default'.
- // Defaults to "ClusterFirst".
- optional string dnsPolicy = 6;
-
- // NodeSelector is a selector which must be true for the pod to fit on a node.
- // Selector which must match a node's labels for the pod to be scheduled on that node.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/node-selection/README.md
- map<string, string> nodeSelector = 7;
-
- // ServiceAccountName is the name of the ServiceAccount to use to run this pod.
- // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md
- optional string serviceAccountName = 8;
-
- // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName.
- // Deprecated: Use serviceAccountName instead.
- // +k8s:conversion-gen=false
- optional string serviceAccount = 9;
-
- // NodeName is a request to schedule this pod onto a specific node. If it is non-empty,
- // the scheduler simply schedules this pod onto that node, assuming that it fits resource
- // requirements.
- optional string nodeName = 10;
-
- // Host networking requested for this pod. Use the host's network namespace.
- // If this option is set, the ports that will be used must be specified.
- // Default to false.
- // +k8s:conversion-gen=false
- optional bool hostNetwork = 11;
-
- // Use the host's pid namespace.
- // Optional: Default to false.
- // +k8s:conversion-gen=false
- optional bool hostPID = 12;
-
- // Use the host's ipc namespace.
- // Optional: Default to false.
- // +k8s:conversion-gen=false
- optional bool hostIPC = 13;
-
- // SecurityContext holds pod-level security attributes and common container settings.
- // Optional: Defaults to empty. See type description for default values of each field.
- optional PodSecurityContext securityContext = 14;
-
- // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec.
- // If specified, these secrets will be passed to individual puller implementations for them to use. For example,
- // in the case of docker, only DockerConfig type secrets are honored.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#specifying-imagepullsecrets-on-a-pod
- repeated LocalObjectReference imagePullSecrets = 15;
-
- // Specifies the hostname of the Pod
- // If not specified, the pod's hostname will be set to a system-defined value.
- optional string hostname = 16;
-
- // If specified, the fully qualified Pod hostname will be "<hostname>.<subdomain>.<pod namespace>.svc.<cluster domain>".
- // If not specified, the pod will not have a domainname at all.
- optional string subdomain = 17;
-}
-
-// PodStatus represents information about the status of a pod. Status may trail the actual
-// state of a system.
-message PodStatus {
- // Current condition of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-phase
- optional string phase = 1;
-
- // Current service state of pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- repeated PodCondition conditions = 2;
-
- // A human readable message indicating details about why the pod is in this condition.
- optional string message = 3;
-
- // A brief CamelCase message indicating details about why the pod is in this state.
- // e.g. 'OutOfDisk'
- optional string reason = 4;
-
- // IP address of the host to which the pod is assigned. Empty if not yet scheduled.
- optional string hostIP = 5;
-
- // IP address allocated to the pod. Routable at least within the cluster.
- // Empty if not yet allocated.
- optional string podIP = 6;
-
- // RFC 3339 date and time at which the object was acknowledged by the Kubelet.
- // This is before the Kubelet pulled the container image(s) for the pod.
- optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 7;
-
- // The list has one entry per container in the manifest. Each entry is currently the output
- // of `docker inspect`.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-statuses
- repeated ContainerStatus containerStatuses = 8;
-}
-
-// PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded
-message PodStatusResult {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Most recently observed status of the pod.
- // This data may not be up to date.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional PodStatus status = 2;
-}
-
-// PodTemplate describes a template for creating copies of a predefined pod.
-message PodTemplate {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Template defines the pods that will be created from this pod template.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional PodTemplateSpec template = 2;
-}
-
-// PodTemplateList is a list of PodTemplates.
-message PodTemplateList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of pod templates
- repeated PodTemplate items = 2;
-}
-
-// PodTemplateSpec describes the data a pod should have when created from a template
-message PodTemplateSpec {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Specification of the desired behavior of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional PodSpec spec = 2;
-}
-
-// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.
-message Preconditions {
- // Specifies the target UID.
- optional string uid = 1;
-}
-
-// An empty preferred scheduling term matches all objects with implicit weight 0
-// (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).
-message PreferredSchedulingTerm {
- // Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.
- optional int32 weight = 1;
-
- // A node selector term, associated with the corresponding weight.
- optional NodeSelectorTerm preference = 2;
-}
-
-// Probe describes a health check to be performed against a container to determine whether it is
-// alive or ready to receive traffic.
-message Probe {
- // The action taken to determine the health of a container
- optional Handler handler = 1;
-
- // Number of seconds after the container has started before liveness probes are initiated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- optional int32 initialDelaySeconds = 2;
-
- // Number of seconds after which the probe times out.
- // Defaults to 1 second. Minimum value is 1.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- optional int32 timeoutSeconds = 3;
-
- // How often (in seconds) to perform the probe.
- // Default to 10 seconds. Minimum value is 1.
- optional int32 periodSeconds = 4;
-
- // Minimum consecutive successes for the probe to be considered successful after having failed.
- // Defaults to 1. Must be 1 for liveness. Minimum value is 1.
- optional int32 successThreshold = 5;
-
- // Minimum consecutive failures for the probe to be considered failed after having succeeded.
- // Defaults to 3. Minimum value is 1.
- optional int32 failureThreshold = 6;
-}
-
-// Represents a Rados Block Device mount that lasts the lifetime of a pod.
-// RBD volumes support ownership management and SELinux relabeling.
-message RBDVolumeSource {
- // A collection of Ceph monitors.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- repeated string monitors = 1;
-
- // The rados image name.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- optional string image = 2;
-
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#rbd
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- optional string fsType = 3;
-
- // The rados pool name.
- // Default is rbd.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it.
- optional string pool = 4;
-
- // The rados user name.
- // Default is admin.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- optional string user = 5;
-
- // Keyring is the path to key ring for RBDUser.
- // Default is /etc/ceph/keyring.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- optional string keyring = 6;
-
- // SecretRef is name of the authentication secret for RBDUser. If provided
- // overrides keyring.
- // Default is nil.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- optional LocalObjectReference secretRef = 7;
-
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- optional bool readOnly = 8;
-}
-
-// RangeAllocation is not a public type.
-message RangeAllocation {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Range is string that identifies the range represented by 'data'.
- optional string range = 2;
-
- // Data is a bit array containing all allocated addresses in the previous segment.
- optional bytes data = 3;
-}
-
-// ReplicationController represents the configuration of a replication controller.
-message ReplicationController {
- // If the Labels of a ReplicationController are empty, they are defaulted to
- // be the same as the Pod(s) that the replication controller manages.
- // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the specification of the desired behavior of the replication controller.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ReplicationControllerSpec spec = 2;
-
- // Status is the most recently observed status of the replication controller.
- // This data may be out of date by some window of time.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ReplicationControllerStatus status = 3;
-}
-
-// ReplicationControllerList is a collection of replication controllers.
-message ReplicationControllerList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of replication controllers.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md
- repeated ReplicationController items = 2;
-}
-
-// ReplicationControllerSpec is the specification of a replication controller.
-message ReplicationControllerSpec {
- // Replicas is the number of desired replicas.
- // This is a pointer to distinguish between explicit zero and unspecified.
- // Defaults to 1.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
- optional int32 replicas = 1;
-
- // Selector is a label query over pods that should match the Replicas count.
- // If Selector is empty, it is defaulted to the labels present on the Pod template.
- // Label keys and values that must match in order to be controlled by this replication
- // controller, if empty defaulted to labels on Pod template.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
- map<string, string> selector = 2;
-
- // Template is the object that describes the pod that will be created if
- // insufficient replicas are detected. This takes precedence over a TemplateRef.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
- optional PodTemplateSpec template = 3;
-}
-
-// ReplicationControllerStatus represents the current status of a replication
-// controller.
-message ReplicationControllerStatus {
- // Replicas is the most recently oberved number of replicas.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
- optional int32 replicas = 1;
-
- // The number of pods that have labels matching the labels of the pod template of the replication controller.
- optional int32 fullyLabeledReplicas = 2;
-
- // ObservedGeneration reflects the generation of the most recently observed replication controller.
- optional int64 observedGeneration = 3;
-}
-
-// ResourceFieldSelector represents container resources (cpu, memory) and their output format
-message ResourceFieldSelector {
- // Container name: required for volumes, optional for env vars
- optional string containerName = 1;
-
- // Required: resource to select
- optional string resource = 2;
-
- // Specifies the output format of the exposed resources, defaults to "1"
- optional k8s.io.kubernetes.pkg.api.resource.Quantity divisor = 3;
-}
-
-// ResourceQuota sets aggregate quota restrictions enforced per namespace
-message ResourceQuota {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the desired quota.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ResourceQuotaSpec spec = 2;
-
- // Status defines the actual enforced quota and its current usage.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ResourceQuotaStatus status = 3;
-}
-
-// ResourceQuotaList is a list of ResourceQuota items.
-message ResourceQuotaList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // Items is a list of ResourceQuota objects.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- repeated ResourceQuota items = 2;
-}
-
-// ResourceQuotaSpec defines the desired hard limits to enforce for Quota.
-message ResourceQuotaSpec {
- // Hard is the set of desired hard limits for each named resource.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> hard = 1;
-
- // A collection of filters that must match each object tracked by a quota.
- // If not specified, the quota matches all objects.
- repeated string scopes = 2;
-}
-
-// ResourceQuotaStatus defines the enforced hard limits and observed use.
-message ResourceQuotaStatus {
- // Hard is the set of enforced hard limits for each named resource.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> hard = 1;
-
- // Used is the current observed total usage of the resource in the namespace.
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> used = 2;
-}
-
-// ResourceRequirements describes the compute resource requirements.
-message ResourceRequirements {
- // Limits describes the maximum amount of compute resources allowed.
- // More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> limits = 1;
-
- // Requests describes the minimum amount of compute resources required.
- // If Requests is omitted for a container, it defaults to Limits if that is explicitly specified,
- // otherwise to an implementation-defined value.
- // More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications
- map<string, k8s.io.kubernetes.pkg.api.resource.Quantity> requests = 2;
-}
-
-// SELinuxOptions are the labels to be applied to the container
-message SELinuxOptions {
- // User is a SELinux user label that applies to the container.
- optional string user = 1;
-
- // Role is a SELinux role label that applies to the container.
- optional string role = 2;
-
- // Type is a SELinux type label that applies to the container.
- optional string type = 3;
-
- // Level is SELinux level label that applies to the container.
- optional string level = 4;
-}
-
-// Secret holds secret data of a certain type. The total bytes of the values in
-// the Data field must be less than MaxSecretSize bytes.
-message Secret {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN
- // or leading dot followed by valid DNS_SUBDOMAIN.
- // The serialized form of the secret data is a base64 encoded string,
- // representing the arbitrary (possibly non-string) data value here.
- // Described in https://tools.ietf.org/html/rfc4648#section-4
- map<string, bytes> data = 2;
-
- // stringData allows specifying non-binary secret data in string form.
- // It is provided as a write-only convenience method.
- // All keys and values are merged into the data field on write, overwriting any existing values.
- // It is never output when reading from the API.
- // +k8s:conversion-gen=false
- map<string, string> stringData = 4;
-
- // Used to facilitate programmatic handling of secret data.
- optional string type = 3;
-}
-
-// SecretKeySelector selects a key of a Secret.
-message SecretKeySelector {
- // The name of the secret in the pod's namespace to select from.
- optional LocalObjectReference localObjectReference = 1;
-
- // The key of the secret to select from. Must be a valid secret key.
- optional string key = 2;
-}
-
-// SecretList is a list of Secret.
-message SecretList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // Items is a list of secret objects.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md
- repeated Secret items = 2;
-}
-
-// Adapts a Secret into a volume.
-//
-// The contents of the target Secret's Data field will be presented in a volume
-// as files using the keys in the Data field as the file names.
-// Secret volumes support ownership management and SELinux relabeling.
-message SecretVolumeSource {
- // Name of the secret in the pod's namespace to use.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets
- optional string secretName = 1;
-
- // If unspecified, each key-value pair in the Data field of the referenced
- // Secret will be projected into the volume as a file whose name is the
- // key and content is the value. If specified, the listed keys will be
- // projected into the specified paths, and unlisted keys will not be
- // present. If a key is specified which is not present in the Secret,
- // the volume setup will error. Paths must be relative and may not contain
- // the '..' path or start with '..'.
- repeated KeyToPath items = 2;
-}
-
-// SecurityContext holds security configuration that will be applied to a container.
-// Some fields are present in both SecurityContext and PodSecurityContext. When both
-// are set, the values in SecurityContext take precedence.
-message SecurityContext {
- // The capabilities to add/drop when running containers.
- // Defaults to the default set of capabilities granted by the container runtime.
- optional Capabilities capabilities = 1;
-
- // Run container in privileged mode.
- // Processes in privileged containers are essentially equivalent to root on the host.
- // Defaults to false.
- optional bool privileged = 2;
-
- // The SELinux context to be applied to the container.
- // If unspecified, the container runtime will allocate a random SELinux context for each
- // container. May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- optional SELinuxOptions seLinuxOptions = 3;
-
- // The UID to run the entrypoint of the container process.
- // Defaults to user specified in image metadata if unspecified.
- // May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- optional int64 runAsUser = 4;
-
- // Indicates that the container must run as a non-root user.
- // If true, the Kubelet will validate the image at runtime to ensure that it
- // does not run as UID 0 (root) and fail to start the container if it does.
- // If unset or false, no such validation will be performed.
- // May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- optional bool runAsNonRoot = 5;
-
- // Whether this container has a read-only root filesystem.
- // Default is false.
- optional bool readOnlyRootFilesystem = 6;
-}
-
-// SerializedReference is a reference to serialized object.
-message SerializedReference {
- // The reference to an object in the system.
- optional ObjectReference reference = 1;
-}
-
-// Service is a named abstraction of software service (for example, mysql) consisting of local port
-// (for example 3306) that the proxy listens on, and the selector that determines which pods
-// will answer requests sent through the proxy.
-message Service {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Spec defines the behavior of a service.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ServiceSpec spec = 2;
-
- // Most recently observed status of the service.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- optional ServiceStatus status = 3;
-}
-
-// ServiceAccount binds together:
-// * a name, understood by users, and perhaps by peripheral systems, for an identity
-// * a principal that can be authenticated and authorized
-// * a set of secrets
-message ServiceAccount {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- optional ObjectMeta metadata = 1;
-
- // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md
- repeated ObjectReference secrets = 2;
-
- // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images
- // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets
- // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md#manually-specifying-an-imagepullsecret
- repeated LocalObjectReference imagePullSecrets = 3;
-}
-
-// ServiceAccountList is a list of ServiceAccount objects
-message ServiceAccountList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of ServiceAccounts.
- // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts
- repeated ServiceAccount items = 2;
-}
-
-// ServiceList holds a list of services.
-message ServiceList {
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
-
- // List of services
- repeated Service items = 2;
-}
-
-// ServicePort contains information on service's port.
-message ServicePort {
- // The name of this port within the service. This must be a DNS_LABEL.
- // All ports within a ServiceSpec must have unique names. This maps to
- // the 'Name' field in EndpointPort objects.
- // Optional if only one ServicePort is defined on this service.
- optional string name = 1;
-
- // The IP protocol for this port. Supports "TCP" and "UDP".
- // Default is TCP.
- optional string protocol = 2;
-
- // The port that will be exposed by this service.
- optional int32 port = 3;
-
- // Number or name of the port to access on the pods targeted by the service.
- // Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.
- // If this is a string, it will be looked up as a named port in the
- // target Pod's container ports. If this is not specified, the value
- // of the 'port' field is used (an identity map).
- // This field is ignored for services with clusterIP=None, and should be
- // omitted or set equal to the 'port' field.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#defining-a-service
- optional k8s.io.kubernetes.pkg.util.intstr.IntOrString targetPort = 4;
-
- // The port on each node on which this service is exposed when type=NodePort or LoadBalancer.
- // Usually assigned by the system. If specified, it will be allocated to the service
- // if unused or else creation of the service will fail.
- // Default is to auto-allocate a port if the ServiceType of this Service requires one.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#type--nodeport
- optional int32 nodePort = 5;
-}
-
-// ServiceProxyOptions is the query options to a Service's proxy call.
-message ServiceProxyOptions {
- // Path is the part of URLs that include service endpoints, suffixes,
- // and parameters to use for the current proxy request to service.
- // For example, the whole request URL is
- // http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy.
- // Path is _search?q=user:kimchy.
- optional string path = 1;
-}
-
-// ServiceSpec describes the attributes that a user creates on a service.
-message ServiceSpec {
- // The list of ports that are exposed by this service.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- repeated ServicePort ports = 1;
-
- // This service will route traffic to pods having labels matching this selector.
- // Label keys and values that must match in order to receive traffic for this service.
- // If not specified, endpoints must be manually specified and the system will not automatically manage them.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#overview
- map<string, string> selector = 2;
-
- // ClusterIP is usually assigned by the master and is the IP address of the service.
- // If specified, it will be allocated to the service if it is unused
- // or else creation of the service will fail.
- // Valid values are None, empty string (""), or a valid IP address.
- // 'None' can be specified for a headless service when proxying is not required.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- optional string clusterIP = 3;
-
- // Type of exposed service. Must be ClusterIP, NodePort, or LoadBalancer.
- // Defaults to ClusterIP.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#external-services
- optional string type = 4;
-
- // externalIPs is a list of IP addresses for which nodes in the cluster
- // will also accept traffic for this service. These IPs are not managed by
- // Kubernetes. The user is responsible for ensuring that traffic arrives
- // at a node with this IP. A common example is external load-balancers
- // that are not part of the Kubernetes system. A previous form of this
- // functionality exists as the deprecatedPublicIPs field. When using this
- // field, callers should also clear the deprecatedPublicIPs field.
- repeated string externalIPs = 5;
-
- // deprecatedPublicIPs is deprecated and replaced by the externalIPs field
- // with almost the exact same semantics. This field is retained in the v1
- // API for compatibility until at least 8/20/2016. It will be removed from
- // any new API revisions. If both deprecatedPublicIPs *and* externalIPs are
- // set, deprecatedPublicIPs is used.
- // +k8s:conversion-gen=false
- repeated string deprecatedPublicIPs = 6;
-
- // Supports "ClientIP" and "None". Used to maintain session affinity.
- // Enable client IP based session affinity.
- // Must be ClientIP or None.
- // Defaults to None.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- optional string sessionAffinity = 7;
-
- // Only applies to Service Type: LoadBalancer
- // LoadBalancer will get created with the IP specified in this field.
- // This feature depends on whether the underlying cloud-provider supports specifying
- // the loadBalancerIP when a load balancer is created.
- // This field will be ignored if the cloud-provider does not support the feature.
- optional string loadBalancerIP = 8;
-
- // If specified and supported by the platform, this will restrict traffic through the cloud-provider
- // load-balancer will be restricted to the specified client IPs. This field will be ignored if the
- // cloud-provider does not support the feature."
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services-firewalls.md
- repeated string loadBalancerSourceRanges = 9;
-}
-
-// ServiceStatus represents the current status of a service.
-message ServiceStatus {
- // LoadBalancer contains the current status of the load-balancer,
- // if one is present.
- optional LoadBalancerStatus loadBalancer = 1;
-}
-
-// TCPSocketAction describes an action based on opening a socket
-message TCPSocketAction {
- // Number or name of the port to access on the container.
- // Number must be in the range 1 to 65535.
- // Name must be an IANA_SVC_NAME.
- optional k8s.io.kubernetes.pkg.util.intstr.IntOrString port = 1;
-}
-
-// The node this Taint is attached to has the effect "effect" on
-// any pod that that does not tolerate the Taint.
-message Taint {
- // Required. The taint key to be applied to a node.
- optional string key = 1;
-
- // Required. The taint value corresponding to the taint key.
- optional string value = 2;
-
- // Required. The effect of the taint on pods
- // that do not tolerate the taint.
- // Valid effects are NoSchedule and PreferNoSchedule.
- optional string effect = 3;
-}
-
-// The pod this Toleration is attached to tolerates any taint that matches
-// the triple <key,value,effect> using the matching operator <operator>.
-message Toleration {
- // Required. Key is the taint key that the toleration applies to.
- optional string key = 1;
-
- // operator represents a key's relationship to the value.
- // Valid operators are Exists and Equal. Defaults to Equal.
- // Exists is equivalent to wildcard for value, so that a pod can
- // tolerate all taints of a particular category.
- optional string operator = 2;
-
- // Value is the taint value the toleration matches to.
- // If the operator is Exists, the value should be empty, otherwise just a regular string.
- optional string value = 3;
-
- // Effect indicates the taint effect to match. Empty means match all taint effects.
- // When specified, allowed values are NoSchedule and PreferNoSchedule.
- optional string effect = 4;
-}
-
-// Volume represents a named volume in a pod that may be accessed by any container in the pod.
-message Volume {
- // Volume's name.
- // Must be a DNS_LABEL and unique within the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- optional string name = 1;
-
- // VolumeSource represents the location and type of the mounted volume.
- // If not specified, the Volume is implied to be an EmptyDir.
- // This implied behavior is deprecated and will be removed in a future version.
- optional VolumeSource volumeSource = 2;
-}
-
-// VolumeMount describes a mounting of a Volume within a container.
-message VolumeMount {
- // This must match the Name of a Volume.
- optional string name = 1;
-
- // Mounted read-only if true, read-write otherwise (false or unspecified).
- // Defaults to false.
- optional bool readOnly = 2;
-
- // Path within the container at which the volume should be mounted. Must
- // not contain ':'.
- optional string mountPath = 3;
-
- // Path within the volume from which the container's volume should be mounted.
- // Defaults to "" (volume's root).
- optional string subPath = 4;
-}
-
-// Represents the source of a volume to mount.
-// Only one of its members may be specified.
-message VolumeSource {
- // HostPath represents a pre-existing file or directory on the host
- // machine that is directly exposed to the container. This is generally
- // used for system agents or other privileged things that are allowed
- // to see the host machine. Most containers will NOT need this.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- // ---
- // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not
- // mount host directories as read/write.
- optional HostPathVolumeSource hostPath = 1;
-
- // EmptyDir represents a temporary directory that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir
- optional EmptyDirVolumeSource emptyDir = 2;
-
- // GCEPersistentDisk represents a GCE Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- optional GCEPersistentDiskVolumeSource gcePersistentDisk = 3;
-
- // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 4;
-
- // GitRepo represents a git repository at a particular revision.
- optional GitRepoVolumeSource gitRepo = 5;
-
- // Secret represents a secret that should populate this volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets
- optional SecretVolumeSource secret = 6;
-
- // NFS represents an NFS mount on the host that shares a pod's lifetime
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- optional NFSVolumeSource nfs = 7;
-
- // ISCSI represents an ISCSI Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md
- optional ISCSIVolumeSource iscsi = 8;
-
- // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
- optional GlusterfsVolumeSource glusterfs = 9;
-
- // PersistentVolumeClaimVolumeSource represents a reference to a
- // PersistentVolumeClaim in the same namespace.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- optional PersistentVolumeClaimVolumeSource persistentVolumeClaim = 10;
-
- // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
- optional RBDVolumeSource rbd = 11;
-
- // FlexVolume represents a generic volume resource that is
- // provisioned/attached using a exec based plugin. This is an
- // alpha feature and may change in future.
- optional FlexVolumeSource flexVolume = 12;
-
- // Cinder represents a cinder volume attached and mounted on kubelets host machine
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- optional CinderVolumeSource cinder = 13;
-
- // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
- optional CephFSVolumeSource cephfs = 14;
-
- // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running
- optional FlockerVolumeSource flocker = 15;
-
- // DownwardAPI represents downward API about the pod that should populate this volume
- optional DownwardAPIVolumeSource downwardAPI = 16;
-
- // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
- optional FCVolumeSource fc = 17;
-
- // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
- optional AzureFileVolumeSource azureFile = 18;
-
- // ConfigMap represents a configMap that should populate this volume
- optional ConfigMapVolumeSource configMap = 19;
-
- // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
- optional VsphereVirtualDiskVolumeSource vsphereVolume = 20;
-}
-
-// Represents a vSphere volume resource.
-message VsphereVirtualDiskVolumeSource {
- // Path that identifies vSphere volume vmdk
- optional string volumePath = 1;
-
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- optional string fsType = 2;
-}
-
-// The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)
-message WeightedPodAffinityTerm {
- // weight associated with matching the corresponding podAffinityTerm,
- // in the range 1-100.
- optional int32 weight = 1;
-
- // Required. A pod affinity term, associated with the corresponding weight.
- optional PodAffinityTerm podAffinityTerm = 2;
-}
-
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/meta.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/meta.go
deleted file mode 100644
index d5ba042..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/meta.go
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
-Copyright 2014 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.
-*/
-
-package v1
-
-import (
- "k8s.io/kubernetes/pkg/api/meta"
- "k8s.io/kubernetes/pkg/api/meta/metatypes"
- "k8s.io/kubernetes/pkg/api/unversioned"
- "k8s.io/kubernetes/pkg/types"
-)
-
-func (obj *ObjectMeta) GetObjectMeta() meta.Object { return obj }
-
-// Namespace implements meta.Object for any object with an ObjectMeta typed field. Allows
-// fast, direct access to metadata fields for API objects.
-func (meta *ObjectMeta) GetNamespace() string { return meta.Namespace }
-func (meta *ObjectMeta) SetNamespace(namespace string) { meta.Namespace = namespace }
-func (meta *ObjectMeta) GetName() string { return meta.Name }
-func (meta *ObjectMeta) SetName(name string) { meta.Name = name }
-func (meta *ObjectMeta) GetGenerateName() string { return meta.GenerateName }
-func (meta *ObjectMeta) SetGenerateName(generateName string) { meta.GenerateName = generateName }
-func (meta *ObjectMeta) GetUID() types.UID { return meta.UID }
-func (meta *ObjectMeta) SetUID(uid types.UID) { meta.UID = uid }
-func (meta *ObjectMeta) GetResourceVersion() string { return meta.ResourceVersion }
-func (meta *ObjectMeta) SetResourceVersion(version string) { meta.ResourceVersion = version }
-func (meta *ObjectMeta) GetSelfLink() string { return meta.SelfLink }
-func (meta *ObjectMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink }
-func (meta *ObjectMeta) GetCreationTimestamp() unversioned.Time { return meta.CreationTimestamp }
-func (meta *ObjectMeta) SetCreationTimestamp(creationTimestamp unversioned.Time) {
- meta.CreationTimestamp = creationTimestamp
-}
-func (meta *ObjectMeta) GetDeletionTimestamp() *unversioned.Time { return meta.DeletionTimestamp }
-func (meta *ObjectMeta) SetDeletionTimestamp(deletionTimestamp *unversioned.Time) {
- meta.DeletionTimestamp = deletionTimestamp
-}
-func (meta *ObjectMeta) GetLabels() map[string]string { return meta.Labels }
-func (meta *ObjectMeta) SetLabels(labels map[string]string) { meta.Labels = labels }
-func (meta *ObjectMeta) GetAnnotations() map[string]string { return meta.Annotations }
-func (meta *ObjectMeta) SetAnnotations(annotations map[string]string) { meta.Annotations = annotations }
-func (meta *ObjectMeta) GetFinalizers() []string { return meta.Finalizers }
-func (meta *ObjectMeta) SetFinalizers(finalizers []string) { meta.Finalizers = finalizers }
-
-func (meta *ObjectMeta) GetOwnerReferences() []metatypes.OwnerReference {
- ret := make([]metatypes.OwnerReference, len(meta.OwnerReferences))
- for i := 0; i < len(meta.OwnerReferences); i++ {
- ret[i].Kind = meta.OwnerReferences[i].Kind
- ret[i].Name = meta.OwnerReferences[i].Name
- ret[i].UID = meta.OwnerReferences[i].UID
- ret[i].APIVersion = meta.OwnerReferences[i].APIVersion
- if meta.OwnerReferences[i].Controller != nil {
- value := *meta.OwnerReferences[i].Controller
- ret[i].Controller = &value
- }
- }
- return ret
-}
-
-func (meta *ObjectMeta) SetOwnerReferences(references []metatypes.OwnerReference) {
- newReferences := make([]OwnerReference, len(references))
- for i := 0; i < len(references); i++ {
- newReferences[i].Kind = references[i].Kind
- newReferences[i].Name = references[i].Name
- newReferences[i].UID = references[i].UID
- newReferences[i].APIVersion = references[i].APIVersion
- if references[i].Controller != nil {
- value := *references[i].Controller
- newReferences[i].Controller = &value
- }
- }
- meta.OwnerReferences = newReferences
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/register.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/register.go
deleted file mode 100644
index 8c625b8..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/register.go
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
-Copyright 2015 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.
-*/
-
-package v1
-
-import (
- "k8s.io/kubernetes/pkg/api/unversioned"
- "k8s.io/kubernetes/pkg/runtime"
- versionedwatch "k8s.io/kubernetes/pkg/watch/versioned"
-)
-
-// GroupName is the group name use in this package
-const GroupName = ""
-
-// SchemeGroupVersion is group version used to register these objects
-var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1"}
-
-func AddToScheme(scheme *runtime.Scheme) {
- // Add the API to Scheme.
- addKnownTypes(scheme)
- addConversionFuncs(scheme)
- addDefaultingFuncs(scheme)
-}
-
-// Adds the list of known types to api.Scheme.
-func addKnownTypes(scheme *runtime.Scheme) {
- scheme.AddKnownTypes(SchemeGroupVersion,
- &Pod{},
- &PodList{},
- &PodStatusResult{},
- &PodTemplate{},
- &PodTemplateList{},
- &ReplicationController{},
- &ReplicationControllerList{},
- &Service{},
- &ServiceProxyOptions{},
- &ServiceList{},
- &Endpoints{},
- &EndpointsList{},
- &Node{},
- &NodeList{},
- &NodeProxyOptions{},
- &Binding{},
- &Event{},
- &EventList{},
- &List{},
- &LimitRange{},
- &LimitRangeList{},
- &ResourceQuota{},
- &ResourceQuotaList{},
- &Namespace{},
- &NamespaceList{},
- &Secret{},
- &SecretList{},
- &ServiceAccount{},
- &ServiceAccountList{},
- &PersistentVolume{},
- &PersistentVolumeList{},
- &PersistentVolumeClaim{},
- &PersistentVolumeClaimList{},
- &DeleteOptions{},
- &ExportOptions{},
- &ListOptions{},
- &PodAttachOptions{},
- &PodLogOptions{},
- &PodExecOptions{},
- &PodProxyOptions{},
- &ComponentStatus{},
- &ComponentStatusList{},
- &SerializedReference{},
- &RangeAllocation{},
- &ConfigMap{},
- &ConfigMapList{},
- )
-
- // Add common types
- scheme.AddKnownTypes(SchemeGroupVersion, &unversioned.Status{})
-
- // Add the watch version that applies
- versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion)
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.generated.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.generated.go
deleted file mode 100644
index 93c45da..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.generated.go
+++ /dev/null
@@ -1,60001 +0,0 @@
-/*
-Copyright 2016 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.
-*/
-
-// ************************************************************
-// DO NOT EDIT.
-// THIS FILE IS AUTO-GENERATED BY codecgen.
-// ************************************************************
-
-package v1
-
-import (
- "errors"
- "fmt"
- codec1978 "github.com/ugorji/go/codec"
- pkg3_resource "k8s.io/kubernetes/pkg/api/resource"
- pkg2_unversioned "k8s.io/kubernetes/pkg/api/unversioned"
- pkg5_runtime "k8s.io/kubernetes/pkg/runtime"
- pkg1_types "k8s.io/kubernetes/pkg/types"
- pkg4_intstr "k8s.io/kubernetes/pkg/util/intstr"
- "reflect"
- "runtime"
- time "time"
-)
-
-const (
- // ----- content types ----
- codecSelferC_UTF81234 = 1
- codecSelferC_RAW1234 = 0
- // ----- value types used ----
- codecSelferValueTypeArray1234 = 10
- codecSelferValueTypeMap1234 = 9
- // ----- containerStateValues ----
- codecSelfer_containerMapKey1234 = 2
- codecSelfer_containerMapValue1234 = 3
- codecSelfer_containerMapEnd1234 = 4
- codecSelfer_containerArrayElem1234 = 6
- codecSelfer_containerArrayEnd1234 = 7
-)
-
-var (
- codecSelferBitsize1234 = uint8(reflect.TypeOf(uint(0)).Bits())
- codecSelferOnlyMapOrArrayEncodeToStructErr1234 = errors.New(`only encoded map or array can be decoded into a struct`)
-)
-
-type codecSelfer1234 struct{}
-
-func init() {
- if codec1978.GenVersion != 5 {
- _, file, _, _ := runtime.Caller(0)
- err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v",
- 5, codec1978.GenVersion, file)
- panic(err)
- }
- if false { // reference the types, but skip this branch at build/run time
- var v0 pkg3_resource.Quantity
- var v1 pkg2_unversioned.Time
- var v2 pkg5_runtime.RawExtension
- var v3 pkg1_types.UID
- var v4 pkg4_intstr.IntOrString
- var v5 time.Time
- _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5
- }
-}
-
-func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [14]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Name != ""
- yyq2[1] = x.GenerateName != ""
- yyq2[2] = x.Namespace != ""
- yyq2[3] = x.SelfLink != ""
- yyq2[4] = x.UID != ""
- yyq2[5] = x.ResourceVersion != ""
- yyq2[6] = x.Generation != 0
- yyq2[7] = true
- yyq2[8] = x.DeletionTimestamp != nil
- yyq2[9] = x.DeletionGracePeriodSeconds != nil
- yyq2[10] = len(x.Labels) != 0
- yyq2[11] = len(x.Annotations) != 0
- yyq2[12] = len(x.OwnerReferences) != 0
- yyq2[13] = len(x.Finalizers) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(14)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("generateName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Namespace))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("namespace"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Namespace))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("selfLink"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("uid"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resourceVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeInt(int64(x.Generation))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("generation"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeInt(int64(x.Generation))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yy25 := &x.CreationTimestamp
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else if z.HasExtensions() && z.EncExt(yy25) {
- } else if yym26 {
- z.EncBinaryMarshal(yy25)
- } else if !yym26 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy25)
- } else {
- z.EncFallback(yy25)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("creationTimestamp"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy27 := &x.CreationTimestamp
- yym28 := z.EncBinary()
- _ = yym28
- if false {
- } else if z.HasExtensions() && z.EncExt(yy27) {
- } else if yym28 {
- z.EncBinaryMarshal(yy27)
- } else if !yym28 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy27)
- } else {
- z.EncFallback(yy27)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.DeletionTimestamp == nil {
- r.EncodeNil()
- } else {
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) {
- } else if yym30 {
- z.EncBinaryMarshal(x.DeletionTimestamp)
- } else if !yym30 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.DeletionTimestamp)
- } else {
- z.EncFallback(x.DeletionTimestamp)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("deletionTimestamp"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.DeletionTimestamp == nil {
- r.EncodeNil()
- } else {
- yym31 := z.EncBinary()
- _ = yym31
- if false {
- } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) {
- } else if yym31 {
- z.EncBinaryMarshal(x.DeletionTimestamp)
- } else if !yym31 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.DeletionTimestamp)
- } else {
- z.EncFallback(x.DeletionTimestamp)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.DeletionGracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy33 := *x.DeletionGracePeriodSeconds
- yym34 := z.EncBinary()
- _ = yym34
- if false {
- } else {
- r.EncodeInt(int64(yy33))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("deletionGracePeriodSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.DeletionGracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy35 := *x.DeletionGracePeriodSeconds
- yym36 := z.EncBinary()
- _ = yym36
- if false {
- } else {
- r.EncodeInt(int64(yy35))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.Labels == nil {
- r.EncodeNil()
- } else {
- yym38 := z.EncBinary()
- _ = yym38
- if false {
- } else {
- z.F.EncMapStringStringV(x.Labels, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("labels"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Labels == nil {
- r.EncodeNil()
- } else {
- yym39 := z.EncBinary()
- _ = yym39
- if false {
- } else {
- z.F.EncMapStringStringV(x.Labels, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.Annotations == nil {
- r.EncodeNil()
- } else {
- yym41 := z.EncBinary()
- _ = yym41
- if false {
- } else {
- z.F.EncMapStringStringV(x.Annotations, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("annotations"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Annotations == nil {
- r.EncodeNil()
- } else {
- yym42 := z.EncBinary()
- _ = yym42
- if false {
- } else {
- z.F.EncMapStringStringV(x.Annotations, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- if x.OwnerReferences == nil {
- r.EncodeNil()
- } else {
- yym44 := z.EncBinary()
- _ = yym44
- if false {
- } else {
- h.encSliceOwnerReference(([]OwnerReference)(x.OwnerReferences), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ownerReferences"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.OwnerReferences == nil {
- r.EncodeNil()
- } else {
- yym45 := z.EncBinary()
- _ = yym45
- if false {
- } else {
- h.encSliceOwnerReference(([]OwnerReference)(x.OwnerReferences), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.Finalizers == nil {
- r.EncodeNil()
- } else {
- yym47 := z.EncBinary()
- _ = yym47
- if false {
- } else {
- z.F.EncSliceStringV(x.Finalizers, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("finalizers"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Finalizers == nil {
- r.EncodeNil()
- } else {
- yym48 := z.EncBinary()
- _ = yym48
- if false {
- } else {
- z.F.EncSliceStringV(x.Finalizers, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ObjectMeta) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ObjectMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "generateName":
- if r.TryDecodeAsNil() {
- x.GenerateName = ""
- } else {
- x.GenerateName = string(r.DecodeString())
- }
- case "namespace":
- if r.TryDecodeAsNil() {
- x.Namespace = ""
- } else {
- x.Namespace = string(r.DecodeString())
- }
- case "selfLink":
- if r.TryDecodeAsNil() {
- x.SelfLink = ""
- } else {
- x.SelfLink = string(r.DecodeString())
- }
- case "uid":
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- case "resourceVersion":
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- case "generation":
- if r.TryDecodeAsNil() {
- x.Generation = 0
- } else {
- x.Generation = int64(r.DecodeInt(64))
- }
- case "creationTimestamp":
- if r.TryDecodeAsNil() {
- x.CreationTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv11 := &x.CreationTimestamp
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else if yym12 {
- z.DecBinaryUnmarshal(yyv11)
- } else if !yym12 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv11)
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- case "deletionTimestamp":
- if r.TryDecodeAsNil() {
- if x.DeletionTimestamp != nil {
- x.DeletionTimestamp = nil
- }
- } else {
- if x.DeletionTimestamp == nil {
- x.DeletionTimestamp = new(pkg2_unversioned.Time)
- }
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) {
- } else if yym14 {
- z.DecBinaryUnmarshal(x.DeletionTimestamp)
- } else if !yym14 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.DeletionTimestamp)
- } else {
- z.DecFallback(x.DeletionTimestamp, false)
- }
- }
- case "deletionGracePeriodSeconds":
- if r.TryDecodeAsNil() {
- if x.DeletionGracePeriodSeconds != nil {
- x.DeletionGracePeriodSeconds = nil
- }
- } else {
- if x.DeletionGracePeriodSeconds == nil {
- x.DeletionGracePeriodSeconds = new(int64)
- }
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "labels":
- if r.TryDecodeAsNil() {
- x.Labels = nil
- } else {
- yyv17 := &x.Labels
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- z.F.DecMapStringStringX(yyv17, false, d)
- }
- }
- case "annotations":
- if r.TryDecodeAsNil() {
- x.Annotations = nil
- } else {
- yyv19 := &x.Annotations
- yym20 := z.DecBinary()
- _ = yym20
- if false {
- } else {
- z.F.DecMapStringStringX(yyv19, false, d)
- }
- }
- case "ownerReferences":
- if r.TryDecodeAsNil() {
- x.OwnerReferences = nil
- } else {
- yyv21 := &x.OwnerReferences
- yym22 := z.DecBinary()
- _ = yym22
- if false {
- } else {
- h.decSliceOwnerReference((*[]OwnerReference)(yyv21), d)
- }
- }
- case "finalizers":
- if r.TryDecodeAsNil() {
- x.Finalizers = nil
- } else {
- yyv23 := &x.Finalizers
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else {
- z.F.DecSliceStringX(yyv23, false, d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj25 int
- var yyb25 bool
- var yyhl25 bool = l >= 0
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.GenerateName = ""
- } else {
- x.GenerateName = string(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Namespace = ""
- } else {
- x.Namespace = string(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SelfLink = ""
- } else {
- x.SelfLink = string(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Generation = 0
- } else {
- x.Generation = int64(r.DecodeInt(64))
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.CreationTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv33 := &x.CreationTimestamp
- yym34 := z.DecBinary()
- _ = yym34
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv33) {
- } else if yym34 {
- z.DecBinaryUnmarshal(yyv33)
- } else if !yym34 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv33)
- } else {
- z.DecFallback(yyv33, false)
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.DeletionTimestamp != nil {
- x.DeletionTimestamp = nil
- }
- } else {
- if x.DeletionTimestamp == nil {
- x.DeletionTimestamp = new(pkg2_unversioned.Time)
- }
- yym36 := z.DecBinary()
- _ = yym36
- if false {
- } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) {
- } else if yym36 {
- z.DecBinaryUnmarshal(x.DeletionTimestamp)
- } else if !yym36 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.DeletionTimestamp)
- } else {
- z.DecFallback(x.DeletionTimestamp, false)
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.DeletionGracePeriodSeconds != nil {
- x.DeletionGracePeriodSeconds = nil
- }
- } else {
- if x.DeletionGracePeriodSeconds == nil {
- x.DeletionGracePeriodSeconds = new(int64)
- }
- yym38 := z.DecBinary()
- _ = yym38
- if false {
- } else {
- *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Labels = nil
- } else {
- yyv39 := &x.Labels
- yym40 := z.DecBinary()
- _ = yym40
- if false {
- } else {
- z.F.DecMapStringStringX(yyv39, false, d)
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Annotations = nil
- } else {
- yyv41 := &x.Annotations
- yym42 := z.DecBinary()
- _ = yym42
- if false {
- } else {
- z.F.DecMapStringStringX(yyv41, false, d)
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.OwnerReferences = nil
- } else {
- yyv43 := &x.OwnerReferences
- yym44 := z.DecBinary()
- _ = yym44
- if false {
- } else {
- h.decSliceOwnerReference((*[]OwnerReference)(yyv43), d)
- }
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Finalizers = nil
- } else {
- yyv45 := &x.Finalizers
- yym46 := z.DecBinary()
- _ = yym46
- if false {
- } else {
- z.F.DecSliceStringX(yyv45, false, d)
- }
- }
- for {
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj25-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [21]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.VolumeSource.HostPath != nil && x.HostPath != nil
- yyq2[2] = x.VolumeSource.EmptyDir != nil && x.EmptyDir != nil
- yyq2[3] = x.VolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil
- yyq2[4] = x.VolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil
- yyq2[5] = x.VolumeSource.GitRepo != nil && x.GitRepo != nil
- yyq2[6] = x.VolumeSource.Secret != nil && x.Secret != nil
- yyq2[7] = x.VolumeSource.NFS != nil && x.NFS != nil
- yyq2[8] = x.VolumeSource.ISCSI != nil && x.ISCSI != nil
- yyq2[9] = x.VolumeSource.Glusterfs != nil && x.Glusterfs != nil
- yyq2[10] = x.VolumeSource.PersistentVolumeClaim != nil && x.PersistentVolumeClaim != nil
- yyq2[11] = x.VolumeSource.RBD != nil && x.RBD != nil
- yyq2[12] = x.VolumeSource.FlexVolume != nil && x.FlexVolume != nil
- yyq2[13] = x.VolumeSource.Cinder != nil && x.Cinder != nil
- yyq2[14] = x.VolumeSource.CephFS != nil && x.CephFS != nil
- yyq2[15] = x.VolumeSource.Flocker != nil && x.Flocker != nil
- yyq2[16] = x.VolumeSource.DownwardAPI != nil && x.DownwardAPI != nil
- yyq2[17] = x.VolumeSource.FC != nil && x.FC != nil
- yyq2[18] = x.VolumeSource.AzureFile != nil && x.AzureFile != nil
- yyq2[19] = x.VolumeSource.ConfigMap != nil && x.ConfigMap != nil
- yyq2[20] = x.VolumeSource.VsphereVolume != nil && x.VsphereVolume != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(21)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- var yyn6 bool
- if x.VolumeSource.HostPath == nil {
- yyn6 = true
- goto LABEL6
- }
- LABEL6:
- if yyr2 || yy2arr2 {
- if yyn6 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn6 {
- r.EncodeNil()
- } else {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn9 bool
- if x.VolumeSource.EmptyDir == nil {
- yyn9 = true
- goto LABEL9
- }
- LABEL9:
- if yyr2 || yy2arr2 {
- if yyn9 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.EmptyDir == nil {
- r.EncodeNil()
- } else {
- x.EmptyDir.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("emptyDir"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn9 {
- r.EncodeNil()
- } else {
- if x.EmptyDir == nil {
- r.EncodeNil()
- } else {
- x.EmptyDir.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn12 bool
- if x.VolumeSource.GCEPersistentDisk == nil {
- yyn12 = true
- goto LABEL12
- }
- LABEL12:
- if yyr2 || yy2arr2 {
- if yyn12 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn12 {
- r.EncodeNil()
- } else {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn15 bool
- if x.VolumeSource.AWSElasticBlockStore == nil {
- yyn15 = true
- goto LABEL15
- }
- LABEL15:
- if yyr2 || yy2arr2 {
- if yyn15 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn15 {
- r.EncodeNil()
- } else {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn18 bool
- if x.VolumeSource.GitRepo == nil {
- yyn18 = true
- goto LABEL18
- }
- LABEL18:
- if yyr2 || yy2arr2 {
- if yyn18 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.GitRepo == nil {
- r.EncodeNil()
- } else {
- x.GitRepo.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gitRepo"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn18 {
- r.EncodeNil()
- } else {
- if x.GitRepo == nil {
- r.EncodeNil()
- } else {
- x.GitRepo.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn21 bool
- if x.VolumeSource.Secret == nil {
- yyn21 = true
- goto LABEL21
- }
- LABEL21:
- if yyr2 || yy2arr2 {
- if yyn21 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.Secret == nil {
- r.EncodeNil()
- } else {
- x.Secret.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secret"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn21 {
- r.EncodeNil()
- } else {
- if x.Secret == nil {
- r.EncodeNil()
- } else {
- x.Secret.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn24 bool
- if x.VolumeSource.NFS == nil {
- yyn24 = true
- goto LABEL24
- }
- LABEL24:
- if yyr2 || yy2arr2 {
- if yyn24 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn24 {
- r.EncodeNil()
- } else {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn27 bool
- if x.VolumeSource.ISCSI == nil {
- yyn27 = true
- goto LABEL27
- }
- LABEL27:
- if yyr2 || yy2arr2 {
- if yyn27 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iscsi"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn27 {
- r.EncodeNil()
- } else {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn30 bool
- if x.VolumeSource.Glusterfs == nil {
- yyn30 = true
- goto LABEL30
- }
- LABEL30:
- if yyr2 || yy2arr2 {
- if yyn30 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("glusterfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn30 {
- r.EncodeNil()
- } else {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn33 bool
- if x.VolumeSource.PersistentVolumeClaim == nil {
- yyn33 = true
- goto LABEL33
- }
- LABEL33:
- if yyr2 || yy2arr2 {
- if yyn33 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.PersistentVolumeClaim == nil {
- r.EncodeNil()
- } else {
- x.PersistentVolumeClaim.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeClaim"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn33 {
- r.EncodeNil()
- } else {
- if x.PersistentVolumeClaim == nil {
- r.EncodeNil()
- } else {
- x.PersistentVolumeClaim.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn36 bool
- if x.VolumeSource.RBD == nil {
- yyn36 = true
- goto LABEL36
- }
- LABEL36:
- if yyr2 || yy2arr2 {
- if yyn36 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("rbd"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn36 {
- r.EncodeNil()
- } else {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn39 bool
- if x.VolumeSource.FlexVolume == nil {
- yyn39 = true
- goto LABEL39
- }
- LABEL39:
- if yyr2 || yy2arr2 {
- if yyn39 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flexVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn39 {
- r.EncodeNil()
- } else {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn42 bool
- if x.VolumeSource.Cinder == nil {
- yyn42 = true
- goto LABEL42
- }
- LABEL42:
- if yyr2 || yy2arr2 {
- if yyn42 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cinder"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn42 {
- r.EncodeNil()
- } else {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn45 bool
- if x.VolumeSource.CephFS == nil {
- yyn45 = true
- goto LABEL45
- }
- LABEL45:
- if yyr2 || yy2arr2 {
- if yyn45 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[14] {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[14] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cephfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn45 {
- r.EncodeNil()
- } else {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn48 bool
- if x.VolumeSource.Flocker == nil {
- yyn48 = true
- goto LABEL48
- }
- LABEL48:
- if yyr2 || yy2arr2 {
- if yyn48 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[15] {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[15] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flocker"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn48 {
- r.EncodeNil()
- } else {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn51 bool
- if x.VolumeSource.DownwardAPI == nil {
- yyn51 = true
- goto LABEL51
- }
- LABEL51:
- if yyr2 || yy2arr2 {
- if yyn51 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[16] {
- if x.DownwardAPI == nil {
- r.EncodeNil()
- } else {
- x.DownwardAPI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[16] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("downwardAPI"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn51 {
- r.EncodeNil()
- } else {
- if x.DownwardAPI == nil {
- r.EncodeNil()
- } else {
- x.DownwardAPI.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn54 bool
- if x.VolumeSource.FC == nil {
- yyn54 = true
- goto LABEL54
- }
- LABEL54:
- if yyr2 || yy2arr2 {
- if yyn54 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[17] {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[17] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fc"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn54 {
- r.EncodeNil()
- } else {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn57 bool
- if x.VolumeSource.AzureFile == nil {
- yyn57 = true
- goto LABEL57
- }
- LABEL57:
- if yyr2 || yy2arr2 {
- if yyn57 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[18] {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[18] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("azureFile"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn57 {
- r.EncodeNil()
- } else {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn60 bool
- if x.VolumeSource.ConfigMap == nil {
- yyn60 = true
- goto LABEL60
- }
- LABEL60:
- if yyr2 || yy2arr2 {
- if yyn60 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[19] {
- if x.ConfigMap == nil {
- r.EncodeNil()
- } else {
- x.ConfigMap.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[19] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("configMap"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn60 {
- r.EncodeNil()
- } else {
- if x.ConfigMap == nil {
- r.EncodeNil()
- } else {
- x.ConfigMap.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn63 bool
- if x.VolumeSource.VsphereVolume == nil {
- yyn63 = true
- goto LABEL63
- }
- LABEL63:
- if yyr2 || yy2arr2 {
- if yyn63 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[20] {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[20] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn63 {
- r.EncodeNil()
- } else {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Volume) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Volume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "hostPath":
- if x.VolumeSource.HostPath == nil {
- x.VolumeSource.HostPath = new(HostPathVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- case "emptyDir":
- if x.VolumeSource.EmptyDir == nil {
- x.VolumeSource.EmptyDir = new(EmptyDirVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.EmptyDir != nil {
- x.EmptyDir = nil
- }
- } else {
- if x.EmptyDir == nil {
- x.EmptyDir = new(EmptyDirVolumeSource)
- }
- x.EmptyDir.CodecDecodeSelf(d)
- }
- case "gcePersistentDisk":
- if x.VolumeSource.GCEPersistentDisk == nil {
- x.VolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- case "awsElasticBlockStore":
- if x.VolumeSource.AWSElasticBlockStore == nil {
- x.VolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- case "gitRepo":
- if x.VolumeSource.GitRepo == nil {
- x.VolumeSource.GitRepo = new(GitRepoVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.GitRepo != nil {
- x.GitRepo = nil
- }
- } else {
- if x.GitRepo == nil {
- x.GitRepo = new(GitRepoVolumeSource)
- }
- x.GitRepo.CodecDecodeSelf(d)
- }
- case "secret":
- if x.VolumeSource.Secret == nil {
- x.VolumeSource.Secret = new(SecretVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Secret != nil {
- x.Secret = nil
- }
- } else {
- if x.Secret == nil {
- x.Secret = new(SecretVolumeSource)
- }
- x.Secret.CodecDecodeSelf(d)
- }
- case "nfs":
- if x.VolumeSource.NFS == nil {
- x.VolumeSource.NFS = new(NFSVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- case "iscsi":
- if x.VolumeSource.ISCSI == nil {
- x.VolumeSource.ISCSI = new(ISCSIVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- case "glusterfs":
- if x.VolumeSource.Glusterfs == nil {
- x.VolumeSource.Glusterfs = new(GlusterfsVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- case "persistentVolumeClaim":
- if x.VolumeSource.PersistentVolumeClaim == nil {
- x.VolumeSource.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.PersistentVolumeClaim != nil {
- x.PersistentVolumeClaim = nil
- }
- } else {
- if x.PersistentVolumeClaim == nil {
- x.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- x.PersistentVolumeClaim.CodecDecodeSelf(d)
- }
- case "rbd":
- if x.VolumeSource.RBD == nil {
- x.VolumeSource.RBD = new(RBDVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- case "flexVolume":
- if x.VolumeSource.FlexVolume == nil {
- x.VolumeSource.FlexVolume = new(FlexVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- case "cinder":
- if x.VolumeSource.Cinder == nil {
- x.VolumeSource.Cinder = new(CinderVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- case "cephfs":
- if x.VolumeSource.CephFS == nil {
- x.VolumeSource.CephFS = new(CephFSVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- case "flocker":
- if x.VolumeSource.Flocker == nil {
- x.VolumeSource.Flocker = new(FlockerVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- case "downwardAPI":
- if x.VolumeSource.DownwardAPI == nil {
- x.VolumeSource.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.DownwardAPI != nil {
- x.DownwardAPI = nil
- }
- } else {
- if x.DownwardAPI == nil {
- x.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- x.DownwardAPI.CodecDecodeSelf(d)
- }
- case "fc":
- if x.VolumeSource.FC == nil {
- x.VolumeSource.FC = new(FCVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- case "azureFile":
- if x.VolumeSource.AzureFile == nil {
- x.VolumeSource.AzureFile = new(AzureFileVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- case "configMap":
- if x.VolumeSource.ConfigMap == nil {
- x.VolumeSource.ConfigMap = new(ConfigMapVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.ConfigMap != nil {
- x.ConfigMap = nil
- }
- } else {
- if x.ConfigMap == nil {
- x.ConfigMap = new(ConfigMapVolumeSource)
- }
- x.ConfigMap.CodecDecodeSelf(d)
- }
- case "vsphereVolume":
- if x.VolumeSource.VsphereVolume == nil {
- x.VolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj25 int
- var yyb25 bool
- var yyhl25 bool = l >= 0
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- if x.VolumeSource.HostPath == nil {
- x.VolumeSource.HostPath = new(HostPathVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- if x.VolumeSource.EmptyDir == nil {
- x.VolumeSource.EmptyDir = new(EmptyDirVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.EmptyDir != nil {
- x.EmptyDir = nil
- }
- } else {
- if x.EmptyDir == nil {
- x.EmptyDir = new(EmptyDirVolumeSource)
- }
- x.EmptyDir.CodecDecodeSelf(d)
- }
- if x.VolumeSource.GCEPersistentDisk == nil {
- x.VolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- if x.VolumeSource.AWSElasticBlockStore == nil {
- x.VolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- if x.VolumeSource.GitRepo == nil {
- x.VolumeSource.GitRepo = new(GitRepoVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GitRepo != nil {
- x.GitRepo = nil
- }
- } else {
- if x.GitRepo == nil {
- x.GitRepo = new(GitRepoVolumeSource)
- }
- x.GitRepo.CodecDecodeSelf(d)
- }
- if x.VolumeSource.Secret == nil {
- x.VolumeSource.Secret = new(SecretVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Secret != nil {
- x.Secret = nil
- }
- } else {
- if x.Secret == nil {
- x.Secret = new(SecretVolumeSource)
- }
- x.Secret.CodecDecodeSelf(d)
- }
- if x.VolumeSource.NFS == nil {
- x.VolumeSource.NFS = new(NFSVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- if x.VolumeSource.ISCSI == nil {
- x.VolumeSource.ISCSI = new(ISCSIVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- if x.VolumeSource.Glusterfs == nil {
- x.VolumeSource.Glusterfs = new(GlusterfsVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- if x.VolumeSource.PersistentVolumeClaim == nil {
- x.VolumeSource.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PersistentVolumeClaim != nil {
- x.PersistentVolumeClaim = nil
- }
- } else {
- if x.PersistentVolumeClaim == nil {
- x.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- x.PersistentVolumeClaim.CodecDecodeSelf(d)
- }
- if x.VolumeSource.RBD == nil {
- x.VolumeSource.RBD = new(RBDVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- if x.VolumeSource.FlexVolume == nil {
- x.VolumeSource.FlexVolume = new(FlexVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- if x.VolumeSource.Cinder == nil {
- x.VolumeSource.Cinder = new(CinderVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- if x.VolumeSource.CephFS == nil {
- x.VolumeSource.CephFS = new(CephFSVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- if x.VolumeSource.Flocker == nil {
- x.VolumeSource.Flocker = new(FlockerVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- if x.VolumeSource.DownwardAPI == nil {
- x.VolumeSource.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.DownwardAPI != nil {
- x.DownwardAPI = nil
- }
- } else {
- if x.DownwardAPI == nil {
- x.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- x.DownwardAPI.CodecDecodeSelf(d)
- }
- if x.VolumeSource.FC == nil {
- x.VolumeSource.FC = new(FCVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- if x.VolumeSource.AzureFile == nil {
- x.VolumeSource.AzureFile = new(AzureFileVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- if x.VolumeSource.ConfigMap == nil {
- x.VolumeSource.ConfigMap = new(ConfigMapVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ConfigMap != nil {
- x.ConfigMap = nil
- }
- } else {
- if x.ConfigMap == nil {
- x.ConfigMap = new(ConfigMapVolumeSource)
- }
- x.ConfigMap.CodecDecodeSelf(d)
- }
- if x.VolumeSource.VsphereVolume == nil {
- x.VolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- for {
- yyj25++
- if yyhl25 {
- yyb25 = yyj25 > l
- } else {
- yyb25 = r.CheckBreak()
- }
- if yyb25 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj25-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [20]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.HostPath != nil
- yyq2[1] = x.EmptyDir != nil
- yyq2[2] = x.GCEPersistentDisk != nil
- yyq2[3] = x.AWSElasticBlockStore != nil
- yyq2[4] = x.GitRepo != nil
- yyq2[5] = x.Secret != nil
- yyq2[6] = x.NFS != nil
- yyq2[7] = x.ISCSI != nil
- yyq2[8] = x.Glusterfs != nil
- yyq2[9] = x.PersistentVolumeClaim != nil
- yyq2[10] = x.RBD != nil
- yyq2[11] = x.FlexVolume != nil
- yyq2[12] = x.Cinder != nil
- yyq2[13] = x.CephFS != nil
- yyq2[14] = x.Flocker != nil
- yyq2[15] = x.DownwardAPI != nil
- yyq2[16] = x.FC != nil
- yyq2[17] = x.AzureFile != nil
- yyq2[18] = x.ConfigMap != nil
- yyq2[19] = x.VsphereVolume != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(20)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.EmptyDir == nil {
- r.EncodeNil()
- } else {
- x.EmptyDir.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("emptyDir"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.EmptyDir == nil {
- r.EncodeNil()
- } else {
- x.EmptyDir.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.GitRepo == nil {
- r.EncodeNil()
- } else {
- x.GitRepo.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gitRepo"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.GitRepo == nil {
- r.EncodeNil()
- } else {
- x.GitRepo.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.Secret == nil {
- r.EncodeNil()
- } else {
- x.Secret.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secret"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Secret == nil {
- r.EncodeNil()
- } else {
- x.Secret.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iscsi"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("glusterfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.PersistentVolumeClaim == nil {
- r.EncodeNil()
- } else {
- x.PersistentVolumeClaim.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeClaim"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PersistentVolumeClaim == nil {
- r.EncodeNil()
- } else {
- x.PersistentVolumeClaim.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("rbd"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flexVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cinder"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cephfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[14] {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[14] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flocker"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[15] {
- if x.DownwardAPI == nil {
- r.EncodeNil()
- } else {
- x.DownwardAPI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[15] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("downwardAPI"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.DownwardAPI == nil {
- r.EncodeNil()
- } else {
- x.DownwardAPI.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[16] {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[16] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fc"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[17] {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[17] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("azureFile"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[18] {
- if x.ConfigMap == nil {
- r.EncodeNil()
- } else {
- x.ConfigMap.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[18] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("configMap"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ConfigMap == nil {
- r.EncodeNil()
- } else {
- x.ConfigMap.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[19] {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[19] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *VolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *VolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "hostPath":
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- case "emptyDir":
- if r.TryDecodeAsNil() {
- if x.EmptyDir != nil {
- x.EmptyDir = nil
- }
- } else {
- if x.EmptyDir == nil {
- x.EmptyDir = new(EmptyDirVolumeSource)
- }
- x.EmptyDir.CodecDecodeSelf(d)
- }
- case "gcePersistentDisk":
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- case "awsElasticBlockStore":
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- case "gitRepo":
- if r.TryDecodeAsNil() {
- if x.GitRepo != nil {
- x.GitRepo = nil
- }
- } else {
- if x.GitRepo == nil {
- x.GitRepo = new(GitRepoVolumeSource)
- }
- x.GitRepo.CodecDecodeSelf(d)
- }
- case "secret":
- if r.TryDecodeAsNil() {
- if x.Secret != nil {
- x.Secret = nil
- }
- } else {
- if x.Secret == nil {
- x.Secret = new(SecretVolumeSource)
- }
- x.Secret.CodecDecodeSelf(d)
- }
- case "nfs":
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- case "iscsi":
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- case "glusterfs":
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- case "persistentVolumeClaim":
- if r.TryDecodeAsNil() {
- if x.PersistentVolumeClaim != nil {
- x.PersistentVolumeClaim = nil
- }
- } else {
- if x.PersistentVolumeClaim == nil {
- x.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- x.PersistentVolumeClaim.CodecDecodeSelf(d)
- }
- case "rbd":
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- case "flexVolume":
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- case "cinder":
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- case "cephfs":
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- case "flocker":
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- case "downwardAPI":
- if r.TryDecodeAsNil() {
- if x.DownwardAPI != nil {
- x.DownwardAPI = nil
- }
- } else {
- if x.DownwardAPI == nil {
- x.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- x.DownwardAPI.CodecDecodeSelf(d)
- }
- case "fc":
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- case "azureFile":
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- case "configMap":
- if r.TryDecodeAsNil() {
- if x.ConfigMap != nil {
- x.ConfigMap = nil
- }
- } else {
- if x.ConfigMap == nil {
- x.ConfigMap = new(ConfigMapVolumeSource)
- }
- x.ConfigMap.CodecDecodeSelf(d)
- }
- case "vsphereVolume":
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj24 int
- var yyb24 bool
- var yyhl24 bool = l >= 0
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.EmptyDir != nil {
- x.EmptyDir = nil
- }
- } else {
- if x.EmptyDir == nil {
- x.EmptyDir = new(EmptyDirVolumeSource)
- }
- x.EmptyDir.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GitRepo != nil {
- x.GitRepo = nil
- }
- } else {
- if x.GitRepo == nil {
- x.GitRepo = new(GitRepoVolumeSource)
- }
- x.GitRepo.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Secret != nil {
- x.Secret = nil
- }
- } else {
- if x.Secret == nil {
- x.Secret = new(SecretVolumeSource)
- }
- x.Secret.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PersistentVolumeClaim != nil {
- x.PersistentVolumeClaim = nil
- }
- } else {
- if x.PersistentVolumeClaim == nil {
- x.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource)
- }
- x.PersistentVolumeClaim.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.DownwardAPI != nil {
- x.DownwardAPI = nil
- }
- } else {
- if x.DownwardAPI == nil {
- x.DownwardAPI = new(DownwardAPIVolumeSource)
- }
- x.DownwardAPI.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ConfigMap != nil {
- x.ConfigMap = nil
- }
- } else {
- if x.ConfigMap == nil {
- x.ConfigMap = new(ConfigMapVolumeSource)
- }
- x.ConfigMap.CodecDecodeSelf(d)
- }
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- for {
- yyj24++
- if yyhl24 {
- yyb24 = yyj24 > l
- } else {
- yyb24 = r.CheckBreak()
- }
- if yyb24 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj24-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeClaimVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("claimName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeClaimVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "claimName":
- if r.TryDecodeAsNil() {
- x.ClaimName = ""
- } else {
- x.ClaimName = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ClaimName = ""
- } else {
- x.ClaimName = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [14]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.GCEPersistentDisk != nil
- yyq2[1] = x.AWSElasticBlockStore != nil
- yyq2[2] = x.HostPath != nil
- yyq2[3] = x.Glusterfs != nil
- yyq2[4] = x.NFS != nil
- yyq2[5] = x.RBD != nil
- yyq2[6] = x.ISCSI != nil
- yyq2[7] = x.Cinder != nil
- yyq2[8] = x.CephFS != nil
- yyq2[9] = x.FC != nil
- yyq2[10] = x.Flocker != nil
- yyq2[11] = x.FlexVolume != nil
- yyq2[12] = x.AzureFile != nil
- yyq2[13] = x.VsphereVolume != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(14)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("glusterfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("rbd"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iscsi"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cinder"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cephfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fc"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flocker"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flexVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("azureFile"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "gcePersistentDisk":
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- case "awsElasticBlockStore":
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- case "hostPath":
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- case "glusterfs":
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- case "nfs":
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- case "rbd":
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- case "iscsi":
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- case "cinder":
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- case "cephfs":
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- case "fc":
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- case "flocker":
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- case "flexVolume":
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- case "azureFile":
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- case "vsphereVolume":
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj18 int
- var yyb18 bool
- var yyhl18 bool = l >= 0
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- for {
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj18-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolume) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolume) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = PersistentVolumeSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = PersistentVolumeStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = PersistentVolumeSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = PersistentVolumeStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [18]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Capacity) != 0
- yyq2[1] = len(x.AccessModes) != 0
- yyq2[2] = x.ClaimRef != nil
- yyq2[3] = x.PersistentVolumeReclaimPolicy != ""
- yyq2[4] = x.PersistentVolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil
- yyq2[5] = x.PersistentVolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil
- yyq2[6] = x.PersistentVolumeSource.HostPath != nil && x.HostPath != nil
- yyq2[7] = x.PersistentVolumeSource.Glusterfs != nil && x.Glusterfs != nil
- yyq2[8] = x.PersistentVolumeSource.NFS != nil && x.NFS != nil
- yyq2[9] = x.PersistentVolumeSource.RBD != nil && x.RBD != nil
- yyq2[10] = x.PersistentVolumeSource.ISCSI != nil && x.ISCSI != nil
- yyq2[11] = x.PersistentVolumeSource.Cinder != nil && x.Cinder != nil
- yyq2[12] = x.PersistentVolumeSource.CephFS != nil && x.CephFS != nil
- yyq2[13] = x.PersistentVolumeSource.FC != nil && x.FC != nil
- yyq2[14] = x.PersistentVolumeSource.Flocker != nil && x.Flocker != nil
- yyq2[15] = x.PersistentVolumeSource.FlexVolume != nil && x.FlexVolume != nil
- yyq2[16] = x.PersistentVolumeSource.AzureFile != nil && x.AzureFile != nil
- yyq2[17] = x.PersistentVolumeSource.VsphereVolume != nil && x.VsphereVolume != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(18)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("capacity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("accessModes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.ClaimRef == nil {
- r.EncodeNil()
- } else {
- x.ClaimRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("claimRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ClaimRef == nil {
- r.EncodeNil()
- } else {
- x.ClaimRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeReclaimPolicy"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e)
- }
- }
- var yyn15 bool
- if x.PersistentVolumeSource.GCEPersistentDisk == nil {
- yyn15 = true
- goto LABEL15
- }
- LABEL15:
- if yyr2 || yy2arr2 {
- if yyn15 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn15 {
- r.EncodeNil()
- } else {
- if x.GCEPersistentDisk == nil {
- r.EncodeNil()
- } else {
- x.GCEPersistentDisk.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn18 bool
- if x.PersistentVolumeSource.AWSElasticBlockStore == nil {
- yyn18 = true
- goto LABEL18
- }
- LABEL18:
- if yyr2 || yy2arr2 {
- if yyn18 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn18 {
- r.EncodeNil()
- } else {
- if x.AWSElasticBlockStore == nil {
- r.EncodeNil()
- } else {
- x.AWSElasticBlockStore.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn21 bool
- if x.PersistentVolumeSource.HostPath == nil {
- yyn21 = true
- goto LABEL21
- }
- LABEL21:
- if yyr2 || yy2arr2 {
- if yyn21 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn21 {
- r.EncodeNil()
- } else {
- if x.HostPath == nil {
- r.EncodeNil()
- } else {
- x.HostPath.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn24 bool
- if x.PersistentVolumeSource.Glusterfs == nil {
- yyn24 = true
- goto LABEL24
- }
- LABEL24:
- if yyr2 || yy2arr2 {
- if yyn24 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("glusterfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn24 {
- r.EncodeNil()
- } else {
- if x.Glusterfs == nil {
- r.EncodeNil()
- } else {
- x.Glusterfs.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn27 bool
- if x.PersistentVolumeSource.NFS == nil {
- yyn27 = true
- goto LABEL27
- }
- LABEL27:
- if yyr2 || yy2arr2 {
- if yyn27 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn27 {
- r.EncodeNil()
- } else {
- if x.NFS == nil {
- r.EncodeNil()
- } else {
- x.NFS.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn30 bool
- if x.PersistentVolumeSource.RBD == nil {
- yyn30 = true
- goto LABEL30
- }
- LABEL30:
- if yyr2 || yy2arr2 {
- if yyn30 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("rbd"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn30 {
- r.EncodeNil()
- } else {
- if x.RBD == nil {
- r.EncodeNil()
- } else {
- x.RBD.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn33 bool
- if x.PersistentVolumeSource.ISCSI == nil {
- yyn33 = true
- goto LABEL33
- }
- LABEL33:
- if yyr2 || yy2arr2 {
- if yyn33 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iscsi"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn33 {
- r.EncodeNil()
- } else {
- if x.ISCSI == nil {
- r.EncodeNil()
- } else {
- x.ISCSI.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn36 bool
- if x.PersistentVolumeSource.Cinder == nil {
- yyn36 = true
- goto LABEL36
- }
- LABEL36:
- if yyr2 || yy2arr2 {
- if yyn36 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cinder"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn36 {
- r.EncodeNil()
- } else {
- if x.Cinder == nil {
- r.EncodeNil()
- } else {
- x.Cinder.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn39 bool
- if x.PersistentVolumeSource.CephFS == nil {
- yyn39 = true
- goto LABEL39
- }
- LABEL39:
- if yyr2 || yy2arr2 {
- if yyn39 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("cephfs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn39 {
- r.EncodeNil()
- } else {
- if x.CephFS == nil {
- r.EncodeNil()
- } else {
- x.CephFS.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn42 bool
- if x.PersistentVolumeSource.FC == nil {
- yyn42 = true
- goto LABEL42
- }
- LABEL42:
- if yyr2 || yy2arr2 {
- if yyn42 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fc"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn42 {
- r.EncodeNil()
- } else {
- if x.FC == nil {
- r.EncodeNil()
- } else {
- x.FC.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn45 bool
- if x.PersistentVolumeSource.Flocker == nil {
- yyn45 = true
- goto LABEL45
- }
- LABEL45:
- if yyr2 || yy2arr2 {
- if yyn45 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[14] {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[14] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flocker"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn45 {
- r.EncodeNil()
- } else {
- if x.Flocker == nil {
- r.EncodeNil()
- } else {
- x.Flocker.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn48 bool
- if x.PersistentVolumeSource.FlexVolume == nil {
- yyn48 = true
- goto LABEL48
- }
- LABEL48:
- if yyr2 || yy2arr2 {
- if yyn48 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[15] {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[15] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("flexVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn48 {
- r.EncodeNil()
- } else {
- if x.FlexVolume == nil {
- r.EncodeNil()
- } else {
- x.FlexVolume.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn51 bool
- if x.PersistentVolumeSource.AzureFile == nil {
- yyn51 = true
- goto LABEL51
- }
- LABEL51:
- if yyr2 || yy2arr2 {
- if yyn51 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[16] {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[16] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("azureFile"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn51 {
- r.EncodeNil()
- } else {
- if x.AzureFile == nil {
- r.EncodeNil()
- } else {
- x.AzureFile.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn54 bool
- if x.PersistentVolumeSource.VsphereVolume == nil {
- yyn54 = true
- goto LABEL54
- }
- LABEL54:
- if yyr2 || yy2arr2 {
- if yyn54 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[17] {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[17] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn54 {
- r.EncodeNil()
- } else {
- if x.VsphereVolume == nil {
- r.EncodeNil()
- } else {
- x.VsphereVolume.CodecEncodeSelf(e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "capacity":
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv4 := &x.Capacity
- yyv4.CodecDecodeSelf(d)
- }
- case "accessModes":
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv5 := &x.AccessModes
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv5), d)
- }
- }
- case "claimRef":
- if r.TryDecodeAsNil() {
- if x.ClaimRef != nil {
- x.ClaimRef = nil
- }
- } else {
- if x.ClaimRef == nil {
- x.ClaimRef = new(ObjectReference)
- }
- x.ClaimRef.CodecDecodeSelf(d)
- }
- case "persistentVolumeReclaimPolicy":
- if r.TryDecodeAsNil() {
- x.PersistentVolumeReclaimPolicy = ""
- } else {
- x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString())
- }
- case "gcePersistentDisk":
- if x.PersistentVolumeSource.GCEPersistentDisk == nil {
- x.PersistentVolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- case "awsElasticBlockStore":
- if x.PersistentVolumeSource.AWSElasticBlockStore == nil {
- x.PersistentVolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- case "hostPath":
- if x.PersistentVolumeSource.HostPath == nil {
- x.PersistentVolumeSource.HostPath = new(HostPathVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- case "glusterfs":
- if x.PersistentVolumeSource.Glusterfs == nil {
- x.PersistentVolumeSource.Glusterfs = new(GlusterfsVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- case "nfs":
- if x.PersistentVolumeSource.NFS == nil {
- x.PersistentVolumeSource.NFS = new(NFSVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- case "rbd":
- if x.PersistentVolumeSource.RBD == nil {
- x.PersistentVolumeSource.RBD = new(RBDVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- case "iscsi":
- if x.PersistentVolumeSource.ISCSI == nil {
- x.PersistentVolumeSource.ISCSI = new(ISCSIVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- case "cinder":
- if x.PersistentVolumeSource.Cinder == nil {
- x.PersistentVolumeSource.Cinder = new(CinderVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- case "cephfs":
- if x.PersistentVolumeSource.CephFS == nil {
- x.PersistentVolumeSource.CephFS = new(CephFSVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- case "fc":
- if x.PersistentVolumeSource.FC == nil {
- x.PersistentVolumeSource.FC = new(FCVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- case "flocker":
- if x.PersistentVolumeSource.Flocker == nil {
- x.PersistentVolumeSource.Flocker = new(FlockerVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- case "flexVolume":
- if x.PersistentVolumeSource.FlexVolume == nil {
- x.PersistentVolumeSource.FlexVolume = new(FlexVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- case "azureFile":
- if x.PersistentVolumeSource.AzureFile == nil {
- x.PersistentVolumeSource.AzureFile = new(AzureFileVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- case "vsphereVolume":
- if x.PersistentVolumeSource.VsphereVolume == nil {
- x.PersistentVolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj23 int
- var yyb23 bool
- var yyhl23 bool = l >= 0
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv24 := &x.Capacity
- yyv24.CodecDecodeSelf(d)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv25 := &x.AccessModes
- yym26 := z.DecBinary()
- _ = yym26
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv25), d)
- }
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ClaimRef != nil {
- x.ClaimRef = nil
- }
- } else {
- if x.ClaimRef == nil {
- x.ClaimRef = new(ObjectReference)
- }
- x.ClaimRef.CodecDecodeSelf(d)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PersistentVolumeReclaimPolicy = ""
- } else {
- x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString())
- }
- if x.PersistentVolumeSource.GCEPersistentDisk == nil {
- x.PersistentVolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GCEPersistentDisk != nil {
- x.GCEPersistentDisk = nil
- }
- } else {
- if x.GCEPersistentDisk == nil {
- x.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource)
- }
- x.GCEPersistentDisk.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.AWSElasticBlockStore == nil {
- x.PersistentVolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AWSElasticBlockStore != nil {
- x.AWSElasticBlockStore = nil
- }
- } else {
- if x.AWSElasticBlockStore == nil {
- x.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource)
- }
- x.AWSElasticBlockStore.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.HostPath == nil {
- x.PersistentVolumeSource.HostPath = new(HostPathVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HostPath != nil {
- x.HostPath = nil
- }
- } else {
- if x.HostPath == nil {
- x.HostPath = new(HostPathVolumeSource)
- }
- x.HostPath.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.Glusterfs == nil {
- x.PersistentVolumeSource.Glusterfs = new(GlusterfsVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Glusterfs != nil {
- x.Glusterfs = nil
- }
- } else {
- if x.Glusterfs == nil {
- x.Glusterfs = new(GlusterfsVolumeSource)
- }
- x.Glusterfs.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.NFS == nil {
- x.PersistentVolumeSource.NFS = new(NFSVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.NFS != nil {
- x.NFS = nil
- }
- } else {
- if x.NFS == nil {
- x.NFS = new(NFSVolumeSource)
- }
- x.NFS.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.RBD == nil {
- x.PersistentVolumeSource.RBD = new(RBDVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RBD != nil {
- x.RBD = nil
- }
- } else {
- if x.RBD == nil {
- x.RBD = new(RBDVolumeSource)
- }
- x.RBD.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.ISCSI == nil {
- x.PersistentVolumeSource.ISCSI = new(ISCSIVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ISCSI != nil {
- x.ISCSI = nil
- }
- } else {
- if x.ISCSI == nil {
- x.ISCSI = new(ISCSIVolumeSource)
- }
- x.ISCSI.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.Cinder == nil {
- x.PersistentVolumeSource.Cinder = new(CinderVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Cinder != nil {
- x.Cinder = nil
- }
- } else {
- if x.Cinder == nil {
- x.Cinder = new(CinderVolumeSource)
- }
- x.Cinder.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.CephFS == nil {
- x.PersistentVolumeSource.CephFS = new(CephFSVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.CephFS != nil {
- x.CephFS = nil
- }
- } else {
- if x.CephFS == nil {
- x.CephFS = new(CephFSVolumeSource)
- }
- x.CephFS.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.FC == nil {
- x.PersistentVolumeSource.FC = new(FCVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FC != nil {
- x.FC = nil
- }
- } else {
- if x.FC == nil {
- x.FC = new(FCVolumeSource)
- }
- x.FC.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.Flocker == nil {
- x.PersistentVolumeSource.Flocker = new(FlockerVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Flocker != nil {
- x.Flocker = nil
- }
- } else {
- if x.Flocker == nil {
- x.Flocker = new(FlockerVolumeSource)
- }
- x.Flocker.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.FlexVolume == nil {
- x.PersistentVolumeSource.FlexVolume = new(FlexVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FlexVolume != nil {
- x.FlexVolume = nil
- }
- } else {
- if x.FlexVolume == nil {
- x.FlexVolume = new(FlexVolumeSource)
- }
- x.FlexVolume.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.AzureFile == nil {
- x.PersistentVolumeSource.AzureFile = new(AzureFileVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.AzureFile != nil {
- x.AzureFile = nil
- }
- } else {
- if x.AzureFile == nil {
- x.AzureFile = new(AzureFileVolumeSource)
- }
- x.AzureFile.CodecDecodeSelf(d)
- }
- if x.PersistentVolumeSource.VsphereVolume == nil {
- x.PersistentVolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.VsphereVolume != nil {
- x.VsphereVolume = nil
- }
- } else {
- if x.VsphereVolume == nil {
- x.VsphereVolume = new(VsphereVirtualDiskVolumeSource)
- }
- x.VsphereVolume.CodecDecodeSelf(d)
- }
- for {
- yyj23++
- if yyhl23 {
- yyb23 = yyj23 > l
- } else {
- yyb23 = r.CheckBreak()
- }
- if yyb23 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj23-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x PersistentVolumeReclaimPolicy) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PersistentVolumeReclaimPolicy) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *PersistentVolumeStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Phase != ""
- yyq2[1] = x.Message != ""
- yyq2[2] = x.Reason != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Phase.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("phase"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Phase.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "phase":
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PersistentVolumePhase(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PersistentVolumePhase(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSlicePersistentVolume((*[]PersistentVolume)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSlicePersistentVolume((*[]PersistentVolume)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeClaim) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeClaim) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeClaim) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = PersistentVolumeClaimSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = PersistentVolumeClaimStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = PersistentVolumeClaimSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = PersistentVolumeClaimStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeClaimList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeClaimList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeClaimList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeClaimList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.AccessModes) != 0
- yyq2[1] = x.Selector != nil
- yyq2[2] = true
- yyq2[3] = x.VolumeName != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("accessModes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(x.Selector) {
- } else {
- z.EncFallback(x.Selector)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("selector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.EncExt(x.Selector) {
- } else {
- z.EncFallback(x.Selector)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy10 := &x.Resources
- yy10.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resources"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy12 := &x.Resources
- yy12.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumeName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeClaimSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "accessModes":
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv4 := &x.AccessModes
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv4), d)
- }
- }
- case "selector":
- if r.TryDecodeAsNil() {
- if x.Selector != nil {
- x.Selector = nil
- }
- } else {
- if x.Selector == nil {
- x.Selector = new(pkg2_unversioned.LabelSelector)
- }
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(x.Selector) {
- } else {
- z.DecFallback(x.Selector, false)
- }
- }
- case "resources":
- if r.TryDecodeAsNil() {
- x.Resources = ResourceRequirements{}
- } else {
- yyv8 := &x.Resources
- yyv8.CodecDecodeSelf(d)
- }
- case "volumeName":
- if r.TryDecodeAsNil() {
- x.VolumeName = ""
- } else {
- x.VolumeName = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv11 := &x.AccessModes
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv11), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Selector != nil {
- x.Selector = nil
- }
- } else {
- if x.Selector == nil {
- x.Selector = new(pkg2_unversioned.LabelSelector)
- }
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.DecExt(x.Selector) {
- } else {
- z.DecFallback(x.Selector, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Resources = ResourceRequirements{}
- } else {
- yyv15 := &x.Resources
- yyv15.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumeName = ""
- } else {
- x.VolumeName = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Phase != ""
- yyq2[1] = len(x.AccessModes) != 0
- yyq2[2] = len(x.Capacity) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Phase.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("phase"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Phase.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("accessModes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.AccessModes == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("capacity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PersistentVolumeClaimStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "phase":
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PersistentVolumeClaimPhase(r.DecodeString())
- }
- case "accessModes":
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv5 := &x.AccessModes
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv5), d)
- }
- }
- case "capacity":
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv7 := &x.Capacity
- yyv7.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PersistentVolumeClaimPhase(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.AccessModes = nil
- } else {
- yyv10 := &x.AccessModes
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else {
- h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv10), d)
- }
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv12 := &x.Capacity
- yyv12.CodecDecodeSelf(d)
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x PersistentVolumeAccessMode) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PersistentVolumeAccessMode) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x PersistentVolumePhase) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PersistentVolumePhase) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x PersistentVolumeClaimPhase) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PersistentVolumeClaimPhase) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *HostPathVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *HostPathVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *HostPathVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *HostPathVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Medium != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Medium.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("medium"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Medium.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EmptyDirVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EmptyDirVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "medium":
- if r.TryDecodeAsNil() {
- x.Medium = ""
- } else {
- x.Medium = StorageMedium(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Medium = ""
- } else {
- x.Medium = StorageMedium(r.DecodeString())
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *GlusterfsVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("endpoints"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *GlusterfsVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *GlusterfsVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "endpoints":
- if r.TryDecodeAsNil() {
- x.EndpointsName = ""
- } else {
- x.EndpointsName = string(r.DecodeString())
- }
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *GlusterfsVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.EndpointsName = ""
- } else {
- x.EndpointsName = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [8]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.FSType != ""
- yyq2[3] = x.RBDPool != ""
- yyq2[4] = x.RadosUser != ""
- yyq2[5] = x.Keyring != ""
- yyq2[6] = x.SecretRef != nil
- yyq2[7] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(8)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.CephMonitors == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- z.F.EncSliceStringV(x.CephMonitors, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("monitors"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.CephMonitors == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- z.F.EncSliceStringV(x.CephMonitors, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("image"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("pool"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("user"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Keyring))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("keyring"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Keyring))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *RBDVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *RBDVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "monitors":
- if r.TryDecodeAsNil() {
- x.CephMonitors = nil
- } else {
- yyv4 := &x.CephMonitors
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- z.F.DecSliceStringX(yyv4, false, d)
- }
- }
- case "image":
- if r.TryDecodeAsNil() {
- x.RBDImage = ""
- } else {
- x.RBDImage = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "pool":
- if r.TryDecodeAsNil() {
- x.RBDPool = ""
- } else {
- x.RBDPool = string(r.DecodeString())
- }
- case "user":
- if r.TryDecodeAsNil() {
- x.RadosUser = ""
- } else {
- x.RadosUser = string(r.DecodeString())
- }
- case "keyring":
- if r.TryDecodeAsNil() {
- x.Keyring = ""
- } else {
- x.Keyring = string(r.DecodeString())
- }
- case "secretRef":
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj13 int
- var yyb13 bool
- var yyhl13 bool = l >= 0
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.CephMonitors = nil
- } else {
- yyv14 := &x.CephMonitors
- yym15 := z.DecBinary()
- _ = yym15
- if false {
- } else {
- z.F.DecSliceStringX(yyv14, false, d)
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RBDImage = ""
- } else {
- x.RBDImage = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RBDPool = ""
- } else {
- x.RBDPool = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RadosUser = ""
- } else {
- x.RadosUser = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Keyring = ""
- } else {
- x.Keyring = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj13-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *CinderVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FSType != ""
- yyq2[2] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumeID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *CinderVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *CinderVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "volumeID":
- if r.TryDecodeAsNil() {
- x.VolumeID = ""
- } else {
- x.VolumeID = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *CinderVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumeID = ""
- } else {
- x.VolumeID = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Path != ""
- yyq2[2] = x.User != ""
- yyq2[3] = x.SecretFile != ""
- yyq2[4] = x.SecretRef != nil
- yyq2[5] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Monitors == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- z.F.EncSliceStringV(x.Monitors, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("monitors"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Monitors == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- z.F.EncSliceStringV(x.Monitors, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.User))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("user"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.User))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretFile"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *CephFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *CephFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "monitors":
- if r.TryDecodeAsNil() {
- x.Monitors = nil
- } else {
- yyv4 := &x.Monitors
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- z.F.DecSliceStringX(yyv4, false, d)
- }
- }
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "user":
- if r.TryDecodeAsNil() {
- x.User = ""
- } else {
- x.User = string(r.DecodeString())
- }
- case "secretFile":
- if r.TryDecodeAsNil() {
- x.SecretFile = ""
- } else {
- x.SecretFile = string(r.DecodeString())
- }
- case "secretRef":
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Monitors = nil
- } else {
- yyv12 := &x.Monitors
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- z.F.DecSliceStringX(yyv12, false, d)
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.User = ""
- } else {
- x.User = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SecretFile = ""
- } else {
- x.SecretFile = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *FlockerVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("datasetName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *FlockerVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *FlockerVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "datasetName":
- if r.TryDecodeAsNil() {
- x.DatasetName = ""
- } else {
- x.DatasetName = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *FlockerVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DatasetName = ""
- } else {
- x.DatasetName = string(r.DecodeString())
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x StorageMedium) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *StorageMedium) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x Protocol) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *Protocol) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FSType != ""
- yyq2[2] = x.Partition != 0
- yyq2[3] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PDName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("pdName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PDName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.Partition))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("partition"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.Partition))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *GCEPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "pdName":
- if r.TryDecodeAsNil() {
- x.PDName = ""
- } else {
- x.PDName = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "partition":
- if r.TryDecodeAsNil() {
- x.Partition = 0
- } else {
- x.Partition = int32(r.DecodeInt(32))
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PDName = ""
- } else {
- x.PDName = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Partition = 0
- } else {
- x.Partition = int32(r.DecodeInt(32))
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FSType != ""
- yyq2[2] = x.SecretRef != nil
- yyq2[3] = x.ReadOnly != false
- yyq2[4] = len(x.Options) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Driver))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("driver"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Driver))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecretRef == nil {
- r.EncodeNil()
- } else {
- x.SecretRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.Options == nil {
- r.EncodeNil()
- } else {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- z.F.EncMapStringStringV(x.Options, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("options"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Options == nil {
- r.EncodeNil()
- } else {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- z.F.EncMapStringStringV(x.Options, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *FlexVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *FlexVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "driver":
- if r.TryDecodeAsNil() {
- x.Driver = ""
- } else {
- x.Driver = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "secretRef":
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- case "options":
- if r.TryDecodeAsNil() {
- x.Options = nil
- } else {
- yyv8 := &x.Options
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- z.F.DecMapStringStringX(yyv8, false, d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Driver = ""
- } else {
- x.Driver = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecretRef != nil {
- x.SecretRef = nil
- }
- } else {
- if x.SecretRef == nil {
- x.SecretRef = new(LocalObjectReference)
- }
- x.SecretRef.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Options = nil
- } else {
- yyv15 := &x.Options
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- z.F.DecMapStringStringX(yyv15, false, d)
- }
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FSType != ""
- yyq2[2] = x.Partition != 0
- yyq2[3] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumeID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.Partition))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("partition"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.Partition))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *AWSElasticBlockStoreVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "volumeID":
- if r.TryDecodeAsNil() {
- x.VolumeID = ""
- } else {
- x.VolumeID = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "partition":
- if r.TryDecodeAsNil() {
- x.Partition = 0
- } else {
- x.Partition = int32(r.DecodeInt(32))
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumeID = ""
- } else {
- x.VolumeID = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Partition = 0
- } else {
- x.Partition = int32(r.DecodeInt(32))
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *GitRepoVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Revision != ""
- yyq2[2] = x.Directory != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Repository))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("repository"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Repository))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Revision))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("revision"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Revision))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Directory))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("directory"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Directory))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *GitRepoVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *GitRepoVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "repository":
- if r.TryDecodeAsNil() {
- x.Repository = ""
- } else {
- x.Repository = string(r.DecodeString())
- }
- case "revision":
- if r.TryDecodeAsNil() {
- x.Revision = ""
- } else {
- x.Revision = string(r.DecodeString())
- }
- case "directory":
- if r.TryDecodeAsNil() {
- x.Directory = ""
- } else {
- x.Directory = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *GitRepoVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Repository = ""
- } else {
- x.Repository = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Revision = ""
- } else {
- x.Revision = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Directory = ""
- } else {
- x.Directory = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *SecretVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.SecretName != ""
- yyq2[1] = len(x.Items) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceKeyToPath(([]KeyToPath)(x.Items), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceKeyToPath(([]KeyToPath)(x.Items), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SecretVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SecretVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "secretName":
- if r.TryDecodeAsNil() {
- x.SecretName = ""
- } else {
- x.SecretName = string(r.DecodeString())
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv5 := &x.Items
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSliceKeyToPath((*[]KeyToPath)(yyv5), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SecretVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SecretName = ""
- } else {
- x.SecretName = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv9 := &x.Items
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSliceKeyToPath((*[]KeyToPath)(yyv9), d)
- }
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Server))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("server"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Server))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "server":
- if r.TryDecodeAsNil() {
- x.Server = ""
- } else {
- x.Server = string(r.DecodeString())
- }
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Server = ""
- } else {
- x.Server = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ISCSIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[3] = x.ISCSIInterface != ""
- yyq2[4] = x.FSType != ""
- yyq2[5] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 3
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("targetPortal"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IQN))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iqn"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IQN))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.Lun))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lun"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.Lun))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("iscsiInterface"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ISCSIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ISCSIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "targetPortal":
- if r.TryDecodeAsNil() {
- x.TargetPortal = ""
- } else {
- x.TargetPortal = string(r.DecodeString())
- }
- case "iqn":
- if r.TryDecodeAsNil() {
- x.IQN = ""
- } else {
- x.IQN = string(r.DecodeString())
- }
- case "lun":
- if r.TryDecodeAsNil() {
- x.Lun = 0
- } else {
- x.Lun = int32(r.DecodeInt(32))
- }
- case "iscsiInterface":
- if r.TryDecodeAsNil() {
- x.ISCSIInterface = ""
- } else {
- x.ISCSIInterface = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TargetPortal = ""
- } else {
- x.TargetPortal = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.IQN = ""
- } else {
- x.IQN = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Lun = 0
- } else {
- x.Lun = int32(r.DecodeInt(32))
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ISCSIInterface = ""
- } else {
- x.ISCSIInterface = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.FSType != ""
- yyq2[3] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.TargetWWNs == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- z.F.EncSliceStringV(x.TargetWWNs, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("targetWWNs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TargetWWNs == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- z.F.EncSliceStringV(x.TargetWWNs, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Lun == nil {
- r.EncodeNil()
- } else {
- yy7 := *x.Lun
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(yy7))
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lun"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Lun == nil {
- r.EncodeNil()
- } else {
- yy9 := *x.Lun
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(yy9))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *FCVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *FCVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "targetWWNs":
- if r.TryDecodeAsNil() {
- x.TargetWWNs = nil
- } else {
- yyv4 := &x.TargetWWNs
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- z.F.DecSliceStringX(yyv4, false, d)
- }
- }
- case "lun":
- if r.TryDecodeAsNil() {
- if x.Lun != nil {
- x.Lun = nil
- }
- } else {
- if x.Lun == nil {
- x.Lun = new(int32)
- }
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- *((*int32)(x.Lun)) = int32(r.DecodeInt(32))
- }
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TargetWWNs = nil
- } else {
- yyv11 := &x.TargetWWNs
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- z.F.DecSliceStringX(yyv11, false, d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Lun != nil {
- x.Lun = nil
- }
- } else {
- if x.Lun == nil {
- x.Lun = new(int32)
- }
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- *((*int32)(x.Lun)) = int32(r.DecodeInt(32))
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *AzureFileVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.ReadOnly != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SecretName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ShareName))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("shareName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ShareName))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *AzureFileVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *AzureFileVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "secretName":
- if r.TryDecodeAsNil() {
- x.SecretName = ""
- } else {
- x.SecretName = string(r.DecodeString())
- }
- case "shareName":
- if r.TryDecodeAsNil() {
- x.ShareName = ""
- } else {
- x.ShareName = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *AzureFileVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SecretName = ""
- } else {
- x.SecretName = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ShareName = ""
- } else {
- x.ShareName = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *VsphereVirtualDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FSType != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumePath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsType"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FSType))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *VsphereVirtualDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "volumePath":
- if r.TryDecodeAsNil() {
- x.VolumePath = ""
- } else {
- x.VolumePath = string(r.DecodeString())
- }
- case "fsType":
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumePath = ""
- } else {
- x.VolumePath = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FSType = ""
- } else {
- x.FSType = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ConfigMapVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Items) != 0
- yyq2[1] = x.Name != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceKeyToPath(([]KeyToPath)(x.Items), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceKeyToPath(([]KeyToPath)(x.Items), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ConfigMapVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ConfigMapVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv4 := &x.Items
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceKeyToPath((*[]KeyToPath)(yyv4), d)
- }
- }
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ConfigMapVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv8 := &x.Items
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- h.decSliceKeyToPath((*[]KeyToPath)(yyv8), d)
- }
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *KeyToPath) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *KeyToPath) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *KeyToPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *KeyToPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerPort) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Name != ""
- yyq2[1] = x.HostPort != 0
- yyq2[3] = x.Protocol != ""
- yyq2[4] = x.HostIP != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.HostPort))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPort"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.HostPort))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.ContainerPort))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerPort"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.ContainerPort))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.Protocol.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("protocol"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Protocol.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.HostIP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostIP"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.HostIP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerPort) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "hostPort":
- if r.TryDecodeAsNil() {
- x.HostPort = 0
- } else {
- x.HostPort = int32(r.DecodeInt(32))
- }
- case "containerPort":
- if r.TryDecodeAsNil() {
- x.ContainerPort = 0
- } else {
- x.ContainerPort = int32(r.DecodeInt(32))
- }
- case "protocol":
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- case "hostIP":
- if r.TryDecodeAsNil() {
- x.HostIP = ""
- } else {
- x.HostIP = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostPort = 0
- } else {
- x.HostPort = int32(r.DecodeInt(32))
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerPort = 0
- } else {
- x.ContainerPort = int32(r.DecodeInt(32))
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostIP = ""
- } else {
- x.HostIP = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *VolumeMount) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.ReadOnly != false
- yyq2[3] = x.SubPath != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnly"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.ReadOnly))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.MountPath))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("mountPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.MountPath))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SubPath))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("subPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SubPath))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *VolumeMount) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *VolumeMount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "readOnly":
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- case "mountPath":
- if r.TryDecodeAsNil() {
- x.MountPath = ""
- } else {
- x.MountPath = string(r.DecodeString())
- }
- case "subPath":
- if r.TryDecodeAsNil() {
- x.SubPath = ""
- } else {
- x.SubPath = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *VolumeMount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ReadOnly = false
- } else {
- x.ReadOnly = bool(r.DecodeBool())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.MountPath = ""
- } else {
- x.MountPath = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SubPath = ""
- } else {
- x.SubPath = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EnvVar) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Value != ""
- yyq2[2] = x.ValueFrom != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("value"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.ValueFrom == nil {
- r.EncodeNil()
- } else {
- x.ValueFrom.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("valueFrom"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ValueFrom == nil {
- r.EncodeNil()
- } else {
- x.ValueFrom.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EnvVar) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EnvVar) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "value":
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- case "valueFrom":
- if r.TryDecodeAsNil() {
- if x.ValueFrom != nil {
- x.ValueFrom = nil
- }
- } else {
- if x.ValueFrom == nil {
- x.ValueFrom = new(EnvVarSource)
- }
- x.ValueFrom.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EnvVar) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ValueFrom != nil {
- x.ValueFrom = nil
- }
- } else {
- if x.ValueFrom == nil {
- x.ValueFrom = new(EnvVarSource)
- }
- x.ValueFrom.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EnvVarSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.FieldRef != nil
- yyq2[1] = x.ResourceFieldRef != nil
- yyq2[2] = x.ConfigMapKeyRef != nil
- yyq2[3] = x.SecretKeyRef != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.FieldRef == nil {
- r.EncodeNil()
- } else {
- x.FieldRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fieldRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FieldRef == nil {
- r.EncodeNil()
- } else {
- x.FieldRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.ResourceFieldRef == nil {
- r.EncodeNil()
- } else {
- x.ResourceFieldRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resourceFieldRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ResourceFieldRef == nil {
- r.EncodeNil()
- } else {
- x.ResourceFieldRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.ConfigMapKeyRef == nil {
- r.EncodeNil()
- } else {
- x.ConfigMapKeyRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("configMapKeyRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ConfigMapKeyRef == nil {
- r.EncodeNil()
- } else {
- x.ConfigMapKeyRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.SecretKeyRef == nil {
- r.EncodeNil()
- } else {
- x.SecretKeyRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secretKeyRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecretKeyRef == nil {
- r.EncodeNil()
- } else {
- x.SecretKeyRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EnvVarSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EnvVarSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "fieldRef":
- if r.TryDecodeAsNil() {
- if x.FieldRef != nil {
- x.FieldRef = nil
- }
- } else {
- if x.FieldRef == nil {
- x.FieldRef = new(ObjectFieldSelector)
- }
- x.FieldRef.CodecDecodeSelf(d)
- }
- case "resourceFieldRef":
- if r.TryDecodeAsNil() {
- if x.ResourceFieldRef != nil {
- x.ResourceFieldRef = nil
- }
- } else {
- if x.ResourceFieldRef == nil {
- x.ResourceFieldRef = new(ResourceFieldSelector)
- }
- x.ResourceFieldRef.CodecDecodeSelf(d)
- }
- case "configMapKeyRef":
- if r.TryDecodeAsNil() {
- if x.ConfigMapKeyRef != nil {
- x.ConfigMapKeyRef = nil
- }
- } else {
- if x.ConfigMapKeyRef == nil {
- x.ConfigMapKeyRef = new(ConfigMapKeySelector)
- }
- x.ConfigMapKeyRef.CodecDecodeSelf(d)
- }
- case "secretKeyRef":
- if r.TryDecodeAsNil() {
- if x.SecretKeyRef != nil {
- x.SecretKeyRef = nil
- }
- } else {
- if x.SecretKeyRef == nil {
- x.SecretKeyRef = new(SecretKeySelector)
- }
- x.SecretKeyRef.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EnvVarSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FieldRef != nil {
- x.FieldRef = nil
- }
- } else {
- if x.FieldRef == nil {
- x.FieldRef = new(ObjectFieldSelector)
- }
- x.FieldRef.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ResourceFieldRef != nil {
- x.ResourceFieldRef = nil
- }
- } else {
- if x.ResourceFieldRef == nil {
- x.ResourceFieldRef = new(ResourceFieldSelector)
- }
- x.ResourceFieldRef.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ConfigMapKeyRef != nil {
- x.ConfigMapKeyRef = nil
- }
- } else {
- if x.ConfigMapKeyRef == nil {
- x.ConfigMapKeyRef = new(ConfigMapKeySelector)
- }
- x.ConfigMapKeyRef.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecretKeyRef != nil {
- x.SecretKeyRef = nil
- }
- } else {
- if x.SecretKeyRef == nil {
- x.SecretKeyRef = new(SecretKeySelector)
- }
- x.SecretKeyRef.CodecDecodeSelf(d)
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ObjectFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fieldPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ObjectFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ObjectFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- case "fieldPath":
- if r.TryDecodeAsNil() {
- x.FieldPath = ""
- } else {
- x.FieldPath = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ObjectFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FieldPath = ""
- } else {
- x.FieldPath = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ResourceFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.ContainerName != ""
- yyq2[2] = true
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Resource))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resource"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Resource))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy10 := &x.Divisor
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else if z.HasExtensions() && z.EncExt(yy10) {
- } else if !yym11 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy10)
- } else {
- z.EncFallback(yy10)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("divisor"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy12 := &x.Divisor
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else if z.HasExtensions() && z.EncExt(yy12) {
- } else if !yym13 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy12)
- } else {
- z.EncFallback(yy12)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "containerName":
- if r.TryDecodeAsNil() {
- x.ContainerName = ""
- } else {
- x.ContainerName = string(r.DecodeString())
- }
- case "resource":
- if r.TryDecodeAsNil() {
- x.Resource = ""
- } else {
- x.Resource = string(r.DecodeString())
- }
- case "divisor":
- if r.TryDecodeAsNil() {
- x.Divisor = pkg3_resource.Quantity{}
- } else {
- yyv6 := &x.Divisor
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv6) {
- } else if !yym7 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv6)
- } else {
- z.DecFallback(yyv6, false)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerName = ""
- } else {
- x.ContainerName = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Resource = ""
- } else {
- x.Resource = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Divisor = pkg3_resource.Quantity{}
- } else {
- yyv11 := &x.Divisor
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else if !yym12 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv11)
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ConfigMapKeySelector) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Name != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ConfigMapKeySelector) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ConfigMapKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ConfigMapKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *SecretKeySelector) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Name != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SecretKeySelector) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SecretKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SecretKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *HTTPHeader) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("value"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *HTTPHeader) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *HTTPHeader) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "value":
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *HTTPHeader) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Path != ""
- yyq2[2] = x.Host != ""
- yyq2[3] = x.Scheme != ""
- yyq2[4] = len(x.HTTPHeaders) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy7 := &x.Port
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.EncExt(yy7) {
- } else if !yym8 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy7)
- } else {
- z.EncFallback(yy7)
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("port"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy9 := &x.Port
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else if z.HasExtensions() && z.EncExt(yy9) {
- } else if !yym10 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy9)
- } else {
- z.EncFallback(yy9)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Host))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("host"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Host))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.Scheme.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("scheme"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Scheme.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.HTTPHeaders == nil {
- r.EncodeNil()
- } else {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("httpHeaders"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.HTTPHeaders == nil {
- r.EncodeNil()
- } else {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *HTTPGetAction) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *HTTPGetAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "port":
- if r.TryDecodeAsNil() {
- x.Port = pkg4_intstr.IntOrString{}
- } else {
- yyv5 := &x.Port
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv5) {
- } else if !yym6 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv5)
- } else {
- z.DecFallback(yyv5, false)
- }
- }
- case "host":
- if r.TryDecodeAsNil() {
- x.Host = ""
- } else {
- x.Host = string(r.DecodeString())
- }
- case "scheme":
- if r.TryDecodeAsNil() {
- x.Scheme = ""
- } else {
- x.Scheme = URIScheme(r.DecodeString())
- }
- case "httpHeaders":
- if r.TryDecodeAsNil() {
- x.HTTPHeaders = nil
- } else {
- yyv9 := &x.HTTPHeaders
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSliceHTTPHeader((*[]HTTPHeader)(yyv9), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Port = pkg4_intstr.IntOrString{}
- } else {
- yyv13 := &x.Port
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv13) {
- } else if !yym14 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv13)
- } else {
- z.DecFallback(yyv13, false)
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Host = ""
- } else {
- x.Host = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Scheme = ""
- } else {
- x.Scheme = URIScheme(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HTTPHeaders = nil
- } else {
- yyv17 := &x.HTTPHeaders
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- h.decSliceHTTPHeader((*[]HTTPHeader)(yyv17), d)
- }
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x URIScheme) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *URIScheme) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *TCPSocketAction) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy4 := &x.Port
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else if !yym5 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy4)
- } else {
- z.EncFallback(yy4)
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("port"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.Port
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else if !yym7 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy6)
- } else {
- z.EncFallback(yy6)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *TCPSocketAction) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *TCPSocketAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "port":
- if r.TryDecodeAsNil() {
- x.Port = pkg4_intstr.IntOrString{}
- } else {
- yyv4 := &x.Port
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else if !yym5 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv4)
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *TCPSocketAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Port = pkg4_intstr.IntOrString{}
- } else {
- yyv7 := &x.Port
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv7) {
- } else if !yym8 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv7)
- } else {
- z.DecFallback(yyv7, false)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ExecAction) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Command) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("command"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ExecAction) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ExecAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "command":
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv4 := &x.Command
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- z.F.DecSliceStringX(yyv4, false, d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ExecAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv7 := &x.Command
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- z.F.DecSliceStringX(yyv7, false, d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [8]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.InitialDelaySeconds != 0
- yyq2[1] = x.TimeoutSeconds != 0
- yyq2[2] = x.PeriodSeconds != 0
- yyq2[3] = x.SuccessThreshold != 0
- yyq2[4] = x.FailureThreshold != 0
- yyq2[5] = x.Handler.Exec != nil && x.Exec != nil
- yyq2[6] = x.Handler.HTTPGet != nil && x.HTTPGet != nil
- yyq2[7] = x.Handler.TCPSocket != nil && x.TCPSocket != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(8)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.InitialDelaySeconds))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("initialDelaySeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.InitialDelaySeconds))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.TimeoutSeconds))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.TimeoutSeconds))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.PeriodSeconds))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("periodSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.PeriodSeconds))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeInt(int64(x.SuccessThreshold))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("successThreshold"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeInt(int64(x.SuccessThreshold))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeInt(int64(x.FailureThreshold))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("failureThreshold"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeInt(int64(x.FailureThreshold))
- }
- }
- }
- var yyn18 bool
- if x.Handler.Exec == nil {
- yyn18 = true
- goto LABEL18
- }
- LABEL18:
- if yyr2 || yy2arr2 {
- if yyn18 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.Exec == nil {
- r.EncodeNil()
- } else {
- x.Exec.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("exec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn18 {
- r.EncodeNil()
- } else {
- if x.Exec == nil {
- r.EncodeNil()
- } else {
- x.Exec.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn21 bool
- if x.Handler.HTTPGet == nil {
- yyn21 = true
- goto LABEL21
- }
- LABEL21:
- if yyr2 || yy2arr2 {
- if yyn21 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.HTTPGet == nil {
- r.EncodeNil()
- } else {
- x.HTTPGet.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("httpGet"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn21 {
- r.EncodeNil()
- } else {
- if x.HTTPGet == nil {
- r.EncodeNil()
- } else {
- x.HTTPGet.CodecEncodeSelf(e)
- }
- }
- }
- }
- var yyn24 bool
- if x.Handler.TCPSocket == nil {
- yyn24 = true
- goto LABEL24
- }
- LABEL24:
- if yyr2 || yy2arr2 {
- if yyn24 {
- r.EncodeNil()
- } else {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.TCPSocket == nil {
- r.EncodeNil()
- } else {
- x.TCPSocket.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tcpSocket"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyn24 {
- r.EncodeNil()
- } else {
- if x.TCPSocket == nil {
- r.EncodeNil()
- } else {
- x.TCPSocket.CodecEncodeSelf(e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Probe) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Probe) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "initialDelaySeconds":
- if r.TryDecodeAsNil() {
- x.InitialDelaySeconds = 0
- } else {
- x.InitialDelaySeconds = int32(r.DecodeInt(32))
- }
- case "timeoutSeconds":
- if r.TryDecodeAsNil() {
- x.TimeoutSeconds = 0
- } else {
- x.TimeoutSeconds = int32(r.DecodeInt(32))
- }
- case "periodSeconds":
- if r.TryDecodeAsNil() {
- x.PeriodSeconds = 0
- } else {
- x.PeriodSeconds = int32(r.DecodeInt(32))
- }
- case "successThreshold":
- if r.TryDecodeAsNil() {
- x.SuccessThreshold = 0
- } else {
- x.SuccessThreshold = int32(r.DecodeInt(32))
- }
- case "failureThreshold":
- if r.TryDecodeAsNil() {
- x.FailureThreshold = 0
- } else {
- x.FailureThreshold = int32(r.DecodeInt(32))
- }
- case "exec":
- if x.Handler.Exec == nil {
- x.Handler.Exec = new(ExecAction)
- }
- if r.TryDecodeAsNil() {
- if x.Exec != nil {
- x.Exec = nil
- }
- } else {
- if x.Exec == nil {
- x.Exec = new(ExecAction)
- }
- x.Exec.CodecDecodeSelf(d)
- }
- case "httpGet":
- if x.Handler.HTTPGet == nil {
- x.Handler.HTTPGet = new(HTTPGetAction)
- }
- if r.TryDecodeAsNil() {
- if x.HTTPGet != nil {
- x.HTTPGet = nil
- }
- } else {
- if x.HTTPGet == nil {
- x.HTTPGet = new(HTTPGetAction)
- }
- x.HTTPGet.CodecDecodeSelf(d)
- }
- case "tcpSocket":
- if x.Handler.TCPSocket == nil {
- x.Handler.TCPSocket = new(TCPSocketAction)
- }
- if r.TryDecodeAsNil() {
- if x.TCPSocket != nil {
- x.TCPSocket = nil
- }
- } else {
- if x.TCPSocket == nil {
- x.TCPSocket = new(TCPSocketAction)
- }
- x.TCPSocket.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.InitialDelaySeconds = 0
- } else {
- x.InitialDelaySeconds = int32(r.DecodeInt(32))
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TimeoutSeconds = 0
- } else {
- x.TimeoutSeconds = int32(r.DecodeInt(32))
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PeriodSeconds = 0
- } else {
- x.PeriodSeconds = int32(r.DecodeInt(32))
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SuccessThreshold = 0
- } else {
- x.SuccessThreshold = int32(r.DecodeInt(32))
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FailureThreshold = 0
- } else {
- x.FailureThreshold = int32(r.DecodeInt(32))
- }
- if x.Handler.Exec == nil {
- x.Handler.Exec = new(ExecAction)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Exec != nil {
- x.Exec = nil
- }
- } else {
- if x.Exec == nil {
- x.Exec = new(ExecAction)
- }
- x.Exec.CodecDecodeSelf(d)
- }
- if x.Handler.HTTPGet == nil {
- x.Handler.HTTPGet = new(HTTPGetAction)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HTTPGet != nil {
- x.HTTPGet = nil
- }
- } else {
- if x.HTTPGet == nil {
- x.HTTPGet = new(HTTPGetAction)
- }
- x.HTTPGet.CodecDecodeSelf(d)
- }
- if x.Handler.TCPSocket == nil {
- x.Handler.TCPSocket = new(TCPSocketAction)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TCPSocket != nil {
- x.TCPSocket = nil
- }
- } else {
- if x.TCPSocket == nil {
- x.TCPSocket = new(TCPSocketAction)
- }
- x.TCPSocket.CodecDecodeSelf(d)
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x PullPolicy) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PullPolicy) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x Capability) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *Capability) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Add) != 0
- yyq2[1] = len(x.Drop) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Add == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceCapability(([]Capability)(x.Add), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("add"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Add == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceCapability(([]Capability)(x.Add), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Drop == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceCapability(([]Capability)(x.Drop), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("drop"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Drop == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceCapability(([]Capability)(x.Drop), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Capabilities) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Capabilities) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "add":
- if r.TryDecodeAsNil() {
- x.Add = nil
- } else {
- yyv4 := &x.Add
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceCapability((*[]Capability)(yyv4), d)
- }
- }
- case "drop":
- if r.TryDecodeAsNil() {
- x.Drop = nil
- } else {
- yyv6 := &x.Drop
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceCapability((*[]Capability)(yyv6), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Capabilities) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Add = nil
- } else {
- yyv9 := &x.Add
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSliceCapability((*[]Capability)(yyv9), d)
- }
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Drop = nil
- } else {
- yyv11 := &x.Drop
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceCapability((*[]Capability)(yyv11), d)
- }
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Limits) != 0
- yyq2[1] = len(x.Requests) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Limits == nil {
- r.EncodeNil()
- } else {
- x.Limits.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("limits"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Limits == nil {
- r.EncodeNil()
- } else {
- x.Limits.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Requests == nil {
- r.EncodeNil()
- } else {
- x.Requests.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("requests"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Requests == nil {
- r.EncodeNil()
- } else {
- x.Requests.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceRequirements) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceRequirements) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "limits":
- if r.TryDecodeAsNil() {
- x.Limits = nil
- } else {
- yyv4 := &x.Limits
- yyv4.CodecDecodeSelf(d)
- }
- case "requests":
- if r.TryDecodeAsNil() {
- x.Requests = nil
- } else {
- yyv5 := &x.Requests
- yyv5.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceRequirements) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Limits = nil
- } else {
- yyv7 := &x.Limits
- yyv7.CodecDecodeSelf(d)
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Requests = nil
- } else {
- yyv8 := &x.Requests
- yyv8.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [18]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Image != ""
- yyq2[2] = len(x.Command) != 0
- yyq2[3] = len(x.Args) != 0
- yyq2[4] = x.WorkingDir != ""
- yyq2[5] = len(x.Ports) != 0
- yyq2[6] = len(x.Env) != 0
- yyq2[7] = true
- yyq2[8] = len(x.VolumeMounts) != 0
- yyq2[9] = x.LivenessProbe != nil
- yyq2[10] = x.ReadinessProbe != nil
- yyq2[11] = x.Lifecycle != nil
- yyq2[12] = x.TerminationMessagePath != ""
- yyq2[13] = x.ImagePullPolicy != ""
- yyq2[14] = x.SecurityContext != nil
- yyq2[15] = x.Stdin != false
- yyq2[16] = x.StdinOnce != false
- yyq2[17] = x.TTY != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(18)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Image))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("image"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Image))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("command"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.Args == nil {
- r.EncodeNil()
- } else {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- z.F.EncSliceStringV(x.Args, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("args"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Args == nil {
- r.EncodeNil()
- } else {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- z.F.EncSliceStringV(x.Args, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("workingDir"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- h.encSliceContainerPort(([]ContainerPort)(x.Ports), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ports"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- h.encSliceContainerPort(([]ContainerPort)(x.Ports), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.Env == nil {
- r.EncodeNil()
- } else {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- h.encSliceEnvVar(([]EnvVar)(x.Env), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("env"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Env == nil {
- r.EncodeNil()
- } else {
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- h.encSliceEnvVar(([]EnvVar)(x.Env), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yy25 := &x.Resources
- yy25.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resources"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy27 := &x.Resources
- yy27.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.VolumeMounts == nil {
- r.EncodeNil()
- } else {
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else {
- h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumeMounts"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.VolumeMounts == nil {
- r.EncodeNil()
- } else {
- yym31 := z.EncBinary()
- _ = yym31
- if false {
- } else {
- h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.LivenessProbe == nil {
- r.EncodeNil()
- } else {
- x.LivenessProbe.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("livenessProbe"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.LivenessProbe == nil {
- r.EncodeNil()
- } else {
- x.LivenessProbe.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- if x.ReadinessProbe == nil {
- r.EncodeNil()
- } else {
- x.ReadinessProbe.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readinessProbe"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ReadinessProbe == nil {
- r.EncodeNil()
- } else {
- x.ReadinessProbe.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- if x.Lifecycle == nil {
- r.EncodeNil()
- } else {
- x.Lifecycle.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lifecycle"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Lifecycle == nil {
- r.EncodeNil()
- } else {
- x.Lifecycle.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- yym42 := z.EncBinary()
- _ = yym42
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("terminationMessagePath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym43 := z.EncBinary()
- _ = yym43
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- x.ImagePullPolicy.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("imagePullPolicy"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.ImagePullPolicy.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[14] {
- if x.SecurityContext == nil {
- r.EncodeNil()
- } else {
- x.SecurityContext.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[14] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("securityContext"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecurityContext == nil {
- r.EncodeNil()
- } else {
- x.SecurityContext.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[15] {
- yym51 := z.EncBinary()
- _ = yym51
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[15] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdin"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym52 := z.EncBinary()
- _ = yym52
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[16] {
- yym54 := z.EncBinary()
- _ = yym54
- if false {
- } else {
- r.EncodeBool(bool(x.StdinOnce))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[16] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdinOnce"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym55 := z.EncBinary()
- _ = yym55
- if false {
- } else {
- r.EncodeBool(bool(x.StdinOnce))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[17] {
- yym57 := z.EncBinary()
- _ = yym57
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[17] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tty"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym58 := z.EncBinary()
- _ = yym58
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Container) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Container) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "image":
- if r.TryDecodeAsNil() {
- x.Image = ""
- } else {
- x.Image = string(r.DecodeString())
- }
- case "command":
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv6 := &x.Command
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- z.F.DecSliceStringX(yyv6, false, d)
- }
- }
- case "args":
- if r.TryDecodeAsNil() {
- x.Args = nil
- } else {
- yyv8 := &x.Args
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- z.F.DecSliceStringX(yyv8, false, d)
- }
- }
- case "workingDir":
- if r.TryDecodeAsNil() {
- x.WorkingDir = ""
- } else {
- x.WorkingDir = string(r.DecodeString())
- }
- case "ports":
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv11 := &x.Ports
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceContainerPort((*[]ContainerPort)(yyv11), d)
- }
- }
- case "env":
- if r.TryDecodeAsNil() {
- x.Env = nil
- } else {
- yyv13 := &x.Env
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceEnvVar((*[]EnvVar)(yyv13), d)
- }
- }
- case "resources":
- if r.TryDecodeAsNil() {
- x.Resources = ResourceRequirements{}
- } else {
- yyv15 := &x.Resources
- yyv15.CodecDecodeSelf(d)
- }
- case "volumeMounts":
- if r.TryDecodeAsNil() {
- x.VolumeMounts = nil
- } else {
- yyv16 := &x.VolumeMounts
- yym17 := z.DecBinary()
- _ = yym17
- if false {
- } else {
- h.decSliceVolumeMount((*[]VolumeMount)(yyv16), d)
- }
- }
- case "livenessProbe":
- if r.TryDecodeAsNil() {
- if x.LivenessProbe != nil {
- x.LivenessProbe = nil
- }
- } else {
- if x.LivenessProbe == nil {
- x.LivenessProbe = new(Probe)
- }
- x.LivenessProbe.CodecDecodeSelf(d)
- }
- case "readinessProbe":
- if r.TryDecodeAsNil() {
- if x.ReadinessProbe != nil {
- x.ReadinessProbe = nil
- }
- } else {
- if x.ReadinessProbe == nil {
- x.ReadinessProbe = new(Probe)
- }
- x.ReadinessProbe.CodecDecodeSelf(d)
- }
- case "lifecycle":
- if r.TryDecodeAsNil() {
- if x.Lifecycle != nil {
- x.Lifecycle = nil
- }
- } else {
- if x.Lifecycle == nil {
- x.Lifecycle = new(Lifecycle)
- }
- x.Lifecycle.CodecDecodeSelf(d)
- }
- case "terminationMessagePath":
- if r.TryDecodeAsNil() {
- x.TerminationMessagePath = ""
- } else {
- x.TerminationMessagePath = string(r.DecodeString())
- }
- case "imagePullPolicy":
- if r.TryDecodeAsNil() {
- x.ImagePullPolicy = ""
- } else {
- x.ImagePullPolicy = PullPolicy(r.DecodeString())
- }
- case "securityContext":
- if r.TryDecodeAsNil() {
- if x.SecurityContext != nil {
- x.SecurityContext = nil
- }
- } else {
- if x.SecurityContext == nil {
- x.SecurityContext = new(SecurityContext)
- }
- x.SecurityContext.CodecDecodeSelf(d)
- }
- case "stdin":
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- case "stdinOnce":
- if r.TryDecodeAsNil() {
- x.StdinOnce = false
- } else {
- x.StdinOnce = bool(r.DecodeBool())
- }
- case "tty":
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj27 int
- var yyb27 bool
- var yyhl27 bool = l >= 0
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Image = ""
- } else {
- x.Image = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv30 := &x.Command
- yym31 := z.DecBinary()
- _ = yym31
- if false {
- } else {
- z.F.DecSliceStringX(yyv30, false, d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Args = nil
- } else {
- yyv32 := &x.Args
- yym33 := z.DecBinary()
- _ = yym33
- if false {
- } else {
- z.F.DecSliceStringX(yyv32, false, d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.WorkingDir = ""
- } else {
- x.WorkingDir = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv35 := &x.Ports
- yym36 := z.DecBinary()
- _ = yym36
- if false {
- } else {
- h.decSliceContainerPort((*[]ContainerPort)(yyv35), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Env = nil
- } else {
- yyv37 := &x.Env
- yym38 := z.DecBinary()
- _ = yym38
- if false {
- } else {
- h.decSliceEnvVar((*[]EnvVar)(yyv37), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Resources = ResourceRequirements{}
- } else {
- yyv39 := &x.Resources
- yyv39.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumeMounts = nil
- } else {
- yyv40 := &x.VolumeMounts
- yym41 := z.DecBinary()
- _ = yym41
- if false {
- } else {
- h.decSliceVolumeMount((*[]VolumeMount)(yyv40), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.LivenessProbe != nil {
- x.LivenessProbe = nil
- }
- } else {
- if x.LivenessProbe == nil {
- x.LivenessProbe = new(Probe)
- }
- x.LivenessProbe.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ReadinessProbe != nil {
- x.ReadinessProbe = nil
- }
- } else {
- if x.ReadinessProbe == nil {
- x.ReadinessProbe = new(Probe)
- }
- x.ReadinessProbe.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Lifecycle != nil {
- x.Lifecycle = nil
- }
- } else {
- if x.Lifecycle == nil {
- x.Lifecycle = new(Lifecycle)
- }
- x.Lifecycle.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TerminationMessagePath = ""
- } else {
- x.TerminationMessagePath = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ImagePullPolicy = ""
- } else {
- x.ImagePullPolicy = PullPolicy(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecurityContext != nil {
- x.SecurityContext = nil
- }
- } else {
- if x.SecurityContext == nil {
- x.SecurityContext = new(SecurityContext)
- }
- x.SecurityContext.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.StdinOnce = false
- } else {
- x.StdinOnce = bool(r.DecodeBool())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- for {
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj27-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Exec != nil
- yyq2[1] = x.HTTPGet != nil
- yyq2[2] = x.TCPSocket != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Exec == nil {
- r.EncodeNil()
- } else {
- x.Exec.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("exec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Exec == nil {
- r.EncodeNil()
- } else {
- x.Exec.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.HTTPGet == nil {
- r.EncodeNil()
- } else {
- x.HTTPGet.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("httpGet"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.HTTPGet == nil {
- r.EncodeNil()
- } else {
- x.HTTPGet.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.TCPSocket == nil {
- r.EncodeNil()
- } else {
- x.TCPSocket.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tcpSocket"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TCPSocket == nil {
- r.EncodeNil()
- } else {
- x.TCPSocket.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Handler) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Handler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "exec":
- if r.TryDecodeAsNil() {
- if x.Exec != nil {
- x.Exec = nil
- }
- } else {
- if x.Exec == nil {
- x.Exec = new(ExecAction)
- }
- x.Exec.CodecDecodeSelf(d)
- }
- case "httpGet":
- if r.TryDecodeAsNil() {
- if x.HTTPGet != nil {
- x.HTTPGet = nil
- }
- } else {
- if x.HTTPGet == nil {
- x.HTTPGet = new(HTTPGetAction)
- }
- x.HTTPGet.CodecDecodeSelf(d)
- }
- case "tcpSocket":
- if r.TryDecodeAsNil() {
- if x.TCPSocket != nil {
- x.TCPSocket = nil
- }
- } else {
- if x.TCPSocket == nil {
- x.TCPSocket = new(TCPSocketAction)
- }
- x.TCPSocket.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Handler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Exec != nil {
- x.Exec = nil
- }
- } else {
- if x.Exec == nil {
- x.Exec = new(ExecAction)
- }
- x.Exec.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.HTTPGet != nil {
- x.HTTPGet = nil
- }
- } else {
- if x.HTTPGet == nil {
- x.HTTPGet = new(HTTPGetAction)
- }
- x.HTTPGet.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TCPSocket != nil {
- x.TCPSocket = nil
- }
- } else {
- if x.TCPSocket == nil {
- x.TCPSocket = new(TCPSocketAction)
- }
- x.TCPSocket.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.PostStart != nil
- yyq2[1] = x.PreStop != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.PostStart == nil {
- r.EncodeNil()
- } else {
- x.PostStart.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("postStart"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PostStart == nil {
- r.EncodeNil()
- } else {
- x.PostStart.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.PreStop == nil {
- r.EncodeNil()
- } else {
- x.PreStop.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preStop"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PreStop == nil {
- r.EncodeNil()
- } else {
- x.PreStop.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Lifecycle) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Lifecycle) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "postStart":
- if r.TryDecodeAsNil() {
- if x.PostStart != nil {
- x.PostStart = nil
- }
- } else {
- if x.PostStart == nil {
- x.PostStart = new(Handler)
- }
- x.PostStart.CodecDecodeSelf(d)
- }
- case "preStop":
- if r.TryDecodeAsNil() {
- if x.PreStop != nil {
- x.PreStop = nil
- }
- } else {
- if x.PreStop == nil {
- x.PreStop = new(Handler)
- }
- x.PreStop.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Lifecycle) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PostStart != nil {
- x.PostStart = nil
- }
- } else {
- if x.PostStart == nil {
- x.PostStart = new(Handler)
- }
- x.PostStart.CodecDecodeSelf(d)
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PreStop != nil {
- x.PreStop = nil
- }
- } else {
- if x.PreStop == nil {
- x.PreStop = new(Handler)
- }
- x.PreStop.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x ConditionStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ConditionStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *ContainerStateWaiting) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Reason != ""
- yyq2[1] = x.Message != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerStateWaiting) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerStateWaiting) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerStateWaiting) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerStateRunning) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.StartedAt
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else if yym5 {
- z.EncBinaryMarshal(yy4)
- } else if !yym5 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy4)
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("startedAt"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.StartedAt
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else if yym7 {
- z.EncBinaryMarshal(yy6)
- } else if !yym7 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy6)
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerStateRunning) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerStateRunning) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "startedAt":
- if r.TryDecodeAsNil() {
- x.StartedAt = pkg2_unversioned.Time{}
- } else {
- yyv4 := &x.StartedAt
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else if yym5 {
- z.DecBinaryUnmarshal(yyv4)
- } else if !yym5 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv4)
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerStateRunning) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.StartedAt = pkg2_unversioned.Time{}
- } else {
- yyv7 := &x.StartedAt
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv7) {
- } else if yym8 {
- z.DecBinaryUnmarshal(yyv7)
- } else if !yym8 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv7)
- } else {
- z.DecFallback(yyv7, false)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [7]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Signal != 0
- yyq2[2] = x.Reason != ""
- yyq2[3] = x.Message != ""
- yyq2[4] = true
- yyq2[5] = true
- yyq2[6] = x.ContainerID != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(7)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.ExitCode))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("exitCode"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.ExitCode))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.Signal))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("signal"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.Signal))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yy16 := &x.StartedAt
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else if z.HasExtensions() && z.EncExt(yy16) {
- } else if yym17 {
- z.EncBinaryMarshal(yy16)
- } else if !yym17 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy16)
- } else {
- z.EncFallback(yy16)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("startedAt"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy18 := &x.StartedAt
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else if z.HasExtensions() && z.EncExt(yy18) {
- } else if yym19 {
- z.EncBinaryMarshal(yy18)
- } else if !yym19 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy18)
- } else {
- z.EncFallback(yy18)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yy21 := &x.FinishedAt
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else if z.HasExtensions() && z.EncExt(yy21) {
- } else if yym22 {
- z.EncBinaryMarshal(yy21)
- } else if !yym22 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy21)
- } else {
- z.EncFallback(yy21)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("finishedAt"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy23 := &x.FinishedAt
- yym24 := z.EncBinary()
- _ = yym24
- if false {
- } else if z.HasExtensions() && z.EncExt(yy23) {
- } else if yym24 {
- z.EncBinaryMarshal(yy23)
- } else if !yym24 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy23)
- } else {
- z.EncFallback(yy23)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym27 := z.EncBinary()
- _ = yym27
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerStateTerminated) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerStateTerminated) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "exitCode":
- if r.TryDecodeAsNil() {
- x.ExitCode = 0
- } else {
- x.ExitCode = int32(r.DecodeInt(32))
- }
- case "signal":
- if r.TryDecodeAsNil() {
- x.Signal = 0
- } else {
- x.Signal = int32(r.DecodeInt(32))
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- case "startedAt":
- if r.TryDecodeAsNil() {
- x.StartedAt = pkg2_unversioned.Time{}
- } else {
- yyv8 := &x.StartedAt
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv8) {
- } else if yym9 {
- z.DecBinaryUnmarshal(yyv8)
- } else if !yym9 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv8)
- } else {
- z.DecFallback(yyv8, false)
- }
- }
- case "finishedAt":
- if r.TryDecodeAsNil() {
- x.FinishedAt = pkg2_unversioned.Time{}
- } else {
- yyv10 := &x.FinishedAt
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv10) {
- } else if yym11 {
- z.DecBinaryUnmarshal(yyv10)
- } else if !yym11 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv10)
- } else {
- z.DecFallback(yyv10, false)
- }
- }
- case "containerID":
- if r.TryDecodeAsNil() {
- x.ContainerID = ""
- } else {
- x.ContainerID = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj13 int
- var yyb13 bool
- var yyhl13 bool = l >= 0
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ExitCode = 0
- } else {
- x.ExitCode = int32(r.DecodeInt(32))
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Signal = 0
- } else {
- x.Signal = int32(r.DecodeInt(32))
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.StartedAt = pkg2_unversioned.Time{}
- } else {
- yyv18 := &x.StartedAt
- yym19 := z.DecBinary()
- _ = yym19
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv18) {
- } else if yym19 {
- z.DecBinaryUnmarshal(yyv18)
- } else if !yym19 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv18)
- } else {
- z.DecFallback(yyv18, false)
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FinishedAt = pkg2_unversioned.Time{}
- } else {
- yyv20 := &x.FinishedAt
- yym21 := z.DecBinary()
- _ = yym21
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv20) {
- } else if yym21 {
- z.DecBinaryUnmarshal(yyv20)
- } else if !yym21 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv20)
- } else {
- z.DecFallback(yyv20, false)
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerID = ""
- } else {
- x.ContainerID = string(r.DecodeString())
- }
- for {
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj13-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Waiting != nil
- yyq2[1] = x.Running != nil
- yyq2[2] = x.Terminated != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Waiting == nil {
- r.EncodeNil()
- } else {
- x.Waiting.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("waiting"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Waiting == nil {
- r.EncodeNil()
- } else {
- x.Waiting.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Running == nil {
- r.EncodeNil()
- } else {
- x.Running.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("running"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Running == nil {
- r.EncodeNil()
- } else {
- x.Running.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Terminated == nil {
- r.EncodeNil()
- } else {
- x.Terminated.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("terminated"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Terminated == nil {
- r.EncodeNil()
- } else {
- x.Terminated.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerState) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "waiting":
- if r.TryDecodeAsNil() {
- if x.Waiting != nil {
- x.Waiting = nil
- }
- } else {
- if x.Waiting == nil {
- x.Waiting = new(ContainerStateWaiting)
- }
- x.Waiting.CodecDecodeSelf(d)
- }
- case "running":
- if r.TryDecodeAsNil() {
- if x.Running != nil {
- x.Running = nil
- }
- } else {
- if x.Running == nil {
- x.Running = new(ContainerStateRunning)
- }
- x.Running.CodecDecodeSelf(d)
- }
- case "terminated":
- if r.TryDecodeAsNil() {
- if x.Terminated != nil {
- x.Terminated = nil
- }
- } else {
- if x.Terminated == nil {
- x.Terminated = new(ContainerStateTerminated)
- }
- x.Terminated.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Waiting != nil {
- x.Waiting = nil
- }
- } else {
- if x.Waiting == nil {
- x.Waiting = new(ContainerStateWaiting)
- }
- x.Waiting.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Running != nil {
- x.Running = nil
- }
- } else {
- if x.Running == nil {
- x.Running = new(ContainerStateRunning)
- }
- x.Running.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Terminated != nil {
- x.Terminated = nil
- }
- } else {
- if x.Terminated == nil {
- x.Terminated = new(ContainerStateTerminated)
- }
- x.Terminated.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [8]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = true
- yyq2[2] = true
- yyq2[7] = x.ContainerID != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(8)
- } else {
- yynn2 = 5
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy7 := &x.State
- yy7.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("state"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy9 := &x.State
- yy9.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy12 := &x.LastTerminationState
- yy12.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastState"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy14 := &x.LastTerminationState
- yy14.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeBool(bool(x.Ready))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ready"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeBool(bool(x.Ready))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeInt(int64(x.RestartCount))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("restartCount"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeInt(int64(x.RestartCount))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Image))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("image"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym24 := z.EncBinary()
- _ = yym24
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Image))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ImageID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("imageID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym27 := z.EncBinary()
- _ = yym27
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ImageID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym29 := z.EncBinary()
- _ = yym29
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "state":
- if r.TryDecodeAsNil() {
- x.State = ContainerState{}
- } else {
- yyv5 := &x.State
- yyv5.CodecDecodeSelf(d)
- }
- case "lastState":
- if r.TryDecodeAsNil() {
- x.LastTerminationState = ContainerState{}
- } else {
- yyv6 := &x.LastTerminationState
- yyv6.CodecDecodeSelf(d)
- }
- case "ready":
- if r.TryDecodeAsNil() {
- x.Ready = false
- } else {
- x.Ready = bool(r.DecodeBool())
- }
- case "restartCount":
- if r.TryDecodeAsNil() {
- x.RestartCount = 0
- } else {
- x.RestartCount = int32(r.DecodeInt(32))
- }
- case "image":
- if r.TryDecodeAsNil() {
- x.Image = ""
- } else {
- x.Image = string(r.DecodeString())
- }
- case "imageID":
- if r.TryDecodeAsNil() {
- x.ImageID = ""
- } else {
- x.ImageID = string(r.DecodeString())
- }
- case "containerID":
- if r.TryDecodeAsNil() {
- x.ContainerID = ""
- } else {
- x.ContainerID = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.State = ContainerState{}
- } else {
- yyv14 := &x.State
- yyv14.CodecDecodeSelf(d)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastTerminationState = ContainerState{}
- } else {
- yyv15 := &x.LastTerminationState
- yyv15.CodecDecodeSelf(d)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Ready = false
- } else {
- x.Ready = bool(r.DecodeBool())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RestartCount = 0
- } else {
- x.RestartCount = int32(r.DecodeInt(32))
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Image = ""
- } else {
- x.Image = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ImageID = ""
- } else {
- x.ImageID = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerID = ""
- } else {
- x.ContainerID = string(r.DecodeString())
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x PodPhase) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PodPhase) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x PodConditionType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *PodConditionType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = true
- yyq2[3] = true
- yyq2[4] = x.Reason != ""
- yyq2[5] = x.Message != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Type.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Status.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Status.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy10 := &x.LastProbeTime
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else if z.HasExtensions() && z.EncExt(yy10) {
- } else if yym11 {
- z.EncBinaryMarshal(yy10)
- } else if !yym11 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy10)
- } else {
- z.EncFallback(yy10)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy12 := &x.LastProbeTime
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else if z.HasExtensions() && z.EncExt(yy12) {
- } else if yym13 {
- z.EncBinaryMarshal(yy12)
- } else if !yym13 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy12)
- } else {
- z.EncFallback(yy12)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yy15 := &x.LastTransitionTime
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.EncExt(yy15) {
- } else if yym16 {
- z.EncBinaryMarshal(yy15)
- } else if !yym16 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy15)
- } else {
- z.EncFallback(yy15)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy17 := &x.LastTransitionTime
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else if z.HasExtensions() && z.EncExt(yy17) {
- } else if yym18 {
- z.EncBinaryMarshal(yy17)
- } else if !yym18 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy17)
- } else {
- z.EncFallback(yy17)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym24 := z.EncBinary()
- _ = yym24
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodCondition) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = PodConditionType(r.DecodeString())
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- case "lastProbeTime":
- if r.TryDecodeAsNil() {
- x.LastProbeTime = pkg2_unversioned.Time{}
- } else {
- yyv6 := &x.LastProbeTime
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv6) {
- } else if yym7 {
- z.DecBinaryUnmarshal(yyv6)
- } else if !yym7 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv6)
- } else {
- z.DecFallback(yyv6, false)
- }
- }
- case "lastTransitionTime":
- if r.TryDecodeAsNil() {
- x.LastTransitionTime = pkg2_unversioned.Time{}
- } else {
- yyv8 := &x.LastTransitionTime
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv8) {
- } else if yym9 {
- z.DecBinaryUnmarshal(yyv8)
- } else if !yym9 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv8)
- } else {
- z.DecFallback(yyv8, false)
- }
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = PodConditionType(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastProbeTime = pkg2_unversioned.Time{}
- } else {
- yyv15 := &x.LastProbeTime
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv15) {
- } else if yym16 {
- z.DecBinaryUnmarshal(yyv15)
- } else if !yym16 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv15)
- } else {
- z.DecFallback(yyv15, false)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastTransitionTime = pkg2_unversioned.Time{}
- } else {
- yyv17 := &x.LastTransitionTime
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv17) {
- } else if yym18 {
- z.DecBinaryUnmarshal(yyv17)
- } else if !yym18 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv17)
- } else {
- z.DecFallback(yyv17, false)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *RestartPolicy) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x DNSPolicy) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *DNSPolicy) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *NodeSelector) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.NodeSelectorTerms == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodeSelectorTerms"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NodeSelectorTerms == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeSelector) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "nodeSelectorTerms":
- if r.TryDecodeAsNil() {
- x.NodeSelectorTerms = nil
- } else {
- yyv4 := &x.NodeSelectorTerms
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NodeSelectorTerms = nil
- } else {
- yyv7 := &x.NodeSelectorTerms
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeSelectorTerm) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.MatchExpressions == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("matchExpressions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.MatchExpressions == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeSelectorTerm) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeSelectorTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "matchExpressions":
- if r.TryDecodeAsNil() {
- x.MatchExpressions = nil
- } else {
- yyv4 := &x.MatchExpressions
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeSelectorTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.MatchExpressions = nil
- } else {
- yyv7 := &x.MatchExpressions
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = len(x.Values) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Operator.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("operator"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Operator.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Values == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- z.F.EncSliceStringV(x.Values, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("values"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Values == nil {
- r.EncodeNil()
- } else {
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- z.F.EncSliceStringV(x.Values, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeSelectorRequirement) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeSelectorRequirement) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "operator":
- if r.TryDecodeAsNil() {
- x.Operator = ""
- } else {
- x.Operator = NodeSelectorOperator(r.DecodeString())
- }
- case "values":
- if r.TryDecodeAsNil() {
- x.Values = nil
- } else {
- yyv6 := &x.Values
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- z.F.DecSliceStringX(yyv6, false, d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeSelectorRequirement) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Operator = ""
- } else {
- x.Operator = NodeSelectorOperator(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Values = nil
- } else {
- yyv11 := &x.Values
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- z.F.DecSliceStringX(yyv11, false, d)
- }
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x NodeSelectorOperator) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *NodeSelectorOperator) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.NodeAffinity != nil
- yyq2[1] = x.PodAffinity != nil
- yyq2[2] = x.PodAntiAffinity != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.NodeAffinity == nil {
- r.EncodeNil()
- } else {
- x.NodeAffinity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodeAffinity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NodeAffinity == nil {
- r.EncodeNil()
- } else {
- x.NodeAffinity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.PodAffinity == nil {
- r.EncodeNil()
- } else {
- x.PodAffinity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("podAffinity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PodAffinity == nil {
- r.EncodeNil()
- } else {
- x.PodAffinity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.PodAntiAffinity == nil {
- r.EncodeNil()
- } else {
- x.PodAntiAffinity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("podAntiAffinity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PodAntiAffinity == nil {
- r.EncodeNil()
- } else {
- x.PodAntiAffinity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Affinity) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Affinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "nodeAffinity":
- if r.TryDecodeAsNil() {
- if x.NodeAffinity != nil {
- x.NodeAffinity = nil
- }
- } else {
- if x.NodeAffinity == nil {
- x.NodeAffinity = new(NodeAffinity)
- }
- x.NodeAffinity.CodecDecodeSelf(d)
- }
- case "podAffinity":
- if r.TryDecodeAsNil() {
- if x.PodAffinity != nil {
- x.PodAffinity = nil
- }
- } else {
- if x.PodAffinity == nil {
- x.PodAffinity = new(PodAffinity)
- }
- x.PodAffinity.CodecDecodeSelf(d)
- }
- case "podAntiAffinity":
- if r.TryDecodeAsNil() {
- if x.PodAntiAffinity != nil {
- x.PodAntiAffinity = nil
- }
- } else {
- if x.PodAntiAffinity == nil {
- x.PodAntiAffinity = new(PodAntiAffinity)
- }
- x.PodAntiAffinity.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Affinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.NodeAffinity != nil {
- x.NodeAffinity = nil
- }
- } else {
- if x.NodeAffinity == nil {
- x.NodeAffinity = new(NodeAffinity)
- }
- x.NodeAffinity.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PodAffinity != nil {
- x.PodAffinity = nil
- }
- } else {
- if x.PodAffinity == nil {
- x.PodAffinity = new(PodAffinity)
- }
- x.PodAffinity.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.PodAntiAffinity != nil {
- x.PodAntiAffinity = nil
- }
- } else {
- if x.PodAntiAffinity == nil {
- x.PodAntiAffinity = new(PodAntiAffinity)
- }
- x.PodAntiAffinity.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0
- yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodAffinity) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "requiredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv4 := &x.RequiredDuringSchedulingIgnoredDuringExecution
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv4), d)
- }
- }
- case "preferredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv6 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv6), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv9 := &x.RequiredDuringSchedulingIgnoredDuringExecution
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv9), d)
- }
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv11 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv11), d)
- }
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0
- yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodAntiAffinity) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodAntiAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "requiredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv4 := &x.RequiredDuringSchedulingIgnoredDuringExecution
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv4), d)
- }
- }
- case "preferredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv6 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv6), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodAntiAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv9 := &x.RequiredDuringSchedulingIgnoredDuringExecution
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv9), d)
- }
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv11 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv11), d)
- }
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *WeightedPodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.Weight))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("weight"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.Weight))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy7 := &x.PodAffinityTerm
- yy7.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("podAffinityTerm"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy9 := &x.PodAffinityTerm
- yy9.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *WeightedPodAffinityTerm) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *WeightedPodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "weight":
- if r.TryDecodeAsNil() {
- x.Weight = 0
- } else {
- x.Weight = int32(r.DecodeInt(32))
- }
- case "podAffinityTerm":
- if r.TryDecodeAsNil() {
- x.PodAffinityTerm = PodAffinityTerm{}
- } else {
- yyv5 := &x.PodAffinityTerm
- yyv5.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *WeightedPodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Weight = 0
- } else {
- x.Weight = int32(r.DecodeInt(32))
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PodAffinityTerm = PodAffinityTerm{}
- } else {
- yyv8 := &x.PodAffinityTerm
- yyv8.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.LabelSelector != nil
- yyq2[2] = x.TopologyKey != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.LabelSelector == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else if z.HasExtensions() && z.EncExt(x.LabelSelector) {
- } else {
- z.EncFallback(x.LabelSelector)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("labelSelector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.LabelSelector == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(x.LabelSelector) {
- } else {
- z.EncFallback(x.LabelSelector)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Namespaces == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- z.F.EncSliceStringV(x.Namespaces, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("namespaces"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Namespaces == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- z.F.EncSliceStringV(x.Namespaces, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("topologyKey"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodAffinityTerm) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "labelSelector":
- if r.TryDecodeAsNil() {
- if x.LabelSelector != nil {
- x.LabelSelector = nil
- }
- } else {
- if x.LabelSelector == nil {
- x.LabelSelector = new(pkg2_unversioned.LabelSelector)
- }
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(x.LabelSelector) {
- } else {
- z.DecFallback(x.LabelSelector, false)
- }
- }
- case "namespaces":
- if r.TryDecodeAsNil() {
- x.Namespaces = nil
- } else {
- yyv6 := &x.Namespaces
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- z.F.DecSliceStringX(yyv6, false, d)
- }
- }
- case "topologyKey":
- if r.TryDecodeAsNil() {
- x.TopologyKey = ""
- } else {
- x.TopologyKey = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.LabelSelector != nil {
- x.LabelSelector = nil
- }
- } else {
- if x.LabelSelector == nil {
- x.LabelSelector = new(pkg2_unversioned.LabelSelector)
- }
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else if z.HasExtensions() && z.DecExt(x.LabelSelector) {
- } else {
- z.DecFallback(x.LabelSelector, false)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Namespaces = nil
- } else {
- yyv12 := &x.Namespaces
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- z.F.DecSliceStringX(yyv12, false, d)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TopologyKey = ""
- } else {
- x.TopologyKey = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.RequiredDuringSchedulingIgnoredDuringExecution != nil
- yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- x.RequiredDuringSchedulingIgnoredDuringExecution.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- x.RequiredDuringSchedulingIgnoredDuringExecution.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.PreferredDuringSchedulingIgnoredDuringExecution == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeAffinity) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "requiredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- if x.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- } else {
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- x.RequiredDuringSchedulingIgnoredDuringExecution = new(NodeSelector)
- }
- x.RequiredDuringSchedulingIgnoredDuringExecution.CodecDecodeSelf(d)
- }
- case "preferredDuringSchedulingIgnoredDuringExecution":
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv5 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv5), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RequiredDuringSchedulingIgnoredDuringExecution != nil {
- x.RequiredDuringSchedulingIgnoredDuringExecution = nil
- }
- } else {
- if x.RequiredDuringSchedulingIgnoredDuringExecution == nil {
- x.RequiredDuringSchedulingIgnoredDuringExecution = new(NodeSelector)
- }
- x.RequiredDuringSchedulingIgnoredDuringExecution.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PreferredDuringSchedulingIgnoredDuringExecution = nil
- } else {
- yyv9 := &x.PreferredDuringSchedulingIgnoredDuringExecution
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv9), d)
- }
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PreferredSchedulingTerm) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.Weight))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("weight"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.Weight))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy7 := &x.Preference
- yy7.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preference"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy9 := &x.Preference
- yy9.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PreferredSchedulingTerm) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PreferredSchedulingTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "weight":
- if r.TryDecodeAsNil() {
- x.Weight = 0
- } else {
- x.Weight = int32(r.DecodeInt(32))
- }
- case "preference":
- if r.TryDecodeAsNil() {
- x.Preference = NodeSelectorTerm{}
- } else {
- yyv5 := &x.Preference
- yyv5.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PreferredSchedulingTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Weight = 0
- } else {
- x.Weight = int32(r.DecodeInt(32))
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Preference = NodeSelectorTerm{}
- } else {
- yyv8 := &x.Preference
- yyv8.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Taint) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Value != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("value"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Effect.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("effect"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Effect.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Taint) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Taint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "value":
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- case "effect":
- if r.TryDecodeAsNil() {
- x.Effect = ""
- } else {
- x.Effect = TaintEffect(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Taint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Effect = ""
- } else {
- x.Effect = TaintEffect(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x TaintEffect) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *TaintEffect) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *Toleration) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Key != ""
- yyq2[1] = x.Operator != ""
- yyq2[2] = x.Value != ""
- yyq2[3] = x.Effect != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("key"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Key))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- x.Operator.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("operator"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Operator.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("value"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Value))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.Effect.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("effect"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Effect.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Toleration) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Toleration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "key":
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- case "operator":
- if r.TryDecodeAsNil() {
- x.Operator = ""
- } else {
- x.Operator = TolerationOperator(r.DecodeString())
- }
- case "value":
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- case "effect":
- if r.TryDecodeAsNil() {
- x.Effect = ""
- } else {
- x.Effect = TaintEffect(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Key = ""
- } else {
- x.Key = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Operator = ""
- } else {
- x.Operator = TolerationOperator(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Value = ""
- } else {
- x.Value = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Effect = ""
- } else {
- x.Effect = TaintEffect(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x TolerationOperator) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *TolerationOperator) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [17]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Volumes) != 0
- yyq2[2] = x.RestartPolicy != ""
- yyq2[3] = x.TerminationGracePeriodSeconds != nil
- yyq2[4] = x.ActiveDeadlineSeconds != nil
- yyq2[5] = x.DNSPolicy != ""
- yyq2[6] = len(x.NodeSelector) != 0
- yyq2[7] = x.ServiceAccountName != ""
- yyq2[8] = x.DeprecatedServiceAccount != ""
- yyq2[9] = x.NodeName != ""
- yyq2[10] = x.HostNetwork != false
- yyq2[11] = x.HostPID != false
- yyq2[12] = x.HostIPC != false
- yyq2[13] = x.SecurityContext != nil
- yyq2[14] = len(x.ImagePullSecrets) != 0
- yyq2[15] = x.Hostname != ""
- yyq2[16] = x.Subdomain != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(17)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Volumes == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceVolume(([]Volume)(x.Volumes), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Volumes == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceVolume(([]Volume)(x.Volumes), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Containers == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceContainer(([]Container)(x.Containers), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containers"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Containers == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceContainer(([]Container)(x.Containers), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- x.RestartPolicy.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("restartPolicy"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.RestartPolicy.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.TerminationGracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy13 := *x.TerminationGracePeriodSeconds
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeInt(int64(yy13))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("terminationGracePeriodSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TerminationGracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy15 := *x.TerminationGracePeriodSeconds
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeInt(int64(yy15))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.ActiveDeadlineSeconds == nil {
- r.EncodeNil()
- } else {
- yy18 := *x.ActiveDeadlineSeconds
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeInt(int64(yy18))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ActiveDeadlineSeconds == nil {
- r.EncodeNil()
- } else {
- yy20 := *x.ActiveDeadlineSeconds
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeInt(int64(yy20))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- x.DNSPolicy.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("dnsPolicy"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.DNSPolicy.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.NodeSelector == nil {
- r.EncodeNil()
- } else {
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- z.F.EncMapStringStringV(x.NodeSelector, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodeSelector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NodeSelector == nil {
- r.EncodeNil()
- } else {
- yym27 := z.EncBinary()
- _ = yym27
- if false {
- } else {
- z.F.EncMapStringStringV(x.NodeSelector, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym29 := z.EncBinary()
- _ = yym29
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("serviceAccountName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- yym32 := z.EncBinary()
- _ = yym32
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("serviceAccount"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym33 := z.EncBinary()
- _ = yym33
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- yym35 := z.EncBinary()
- _ = yym35
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.NodeName))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodeName"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym36 := z.EncBinary()
- _ = yym36
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.NodeName))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- yym38 := z.EncBinary()
- _ = yym38
- if false {
- } else {
- r.EncodeBool(bool(x.HostNetwork))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostNetwork"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym39 := z.EncBinary()
- _ = yym39
- if false {
- } else {
- r.EncodeBool(bool(x.HostNetwork))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[11] {
- yym41 := z.EncBinary()
- _ = yym41
- if false {
- } else {
- r.EncodeBool(bool(x.HostPID))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[11] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostPID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym42 := z.EncBinary()
- _ = yym42
- if false {
- } else {
- r.EncodeBool(bool(x.HostPID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[12] {
- yym44 := z.EncBinary()
- _ = yym44
- if false {
- } else {
- r.EncodeBool(bool(x.HostIPC))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[12] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostIPC"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym45 := z.EncBinary()
- _ = yym45
- if false {
- } else {
- r.EncodeBool(bool(x.HostIPC))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[13] {
- if x.SecurityContext == nil {
- r.EncodeNil()
- } else {
- x.SecurityContext.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[13] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("securityContext"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SecurityContext == nil {
- r.EncodeNil()
- } else {
- x.SecurityContext.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[14] {
- if x.ImagePullSecrets == nil {
- r.EncodeNil()
- } else {
- yym50 := z.EncBinary()
- _ = yym50
- if false {
- } else {
- h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[14] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ImagePullSecrets == nil {
- r.EncodeNil()
- } else {
- yym51 := z.EncBinary()
- _ = yym51
- if false {
- } else {
- h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[15] {
- yym53 := z.EncBinary()
- _ = yym53
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[15] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostname"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym54 := z.EncBinary()
- _ = yym54
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[16] {
- yym56 := z.EncBinary()
- _ = yym56
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[16] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("subdomain"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym57 := z.EncBinary()
- _ = yym57
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "volumes":
- if r.TryDecodeAsNil() {
- x.Volumes = nil
- } else {
- yyv4 := &x.Volumes
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceVolume((*[]Volume)(yyv4), d)
- }
- }
- case "containers":
- if r.TryDecodeAsNil() {
- x.Containers = nil
- } else {
- yyv6 := &x.Containers
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceContainer((*[]Container)(yyv6), d)
- }
- }
- case "restartPolicy":
- if r.TryDecodeAsNil() {
- x.RestartPolicy = ""
- } else {
- x.RestartPolicy = RestartPolicy(r.DecodeString())
- }
- case "terminationGracePeriodSeconds":
- if r.TryDecodeAsNil() {
- if x.TerminationGracePeriodSeconds != nil {
- x.TerminationGracePeriodSeconds = nil
- }
- } else {
- if x.TerminationGracePeriodSeconds == nil {
- x.TerminationGracePeriodSeconds = new(int64)
- }
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "activeDeadlineSeconds":
- if r.TryDecodeAsNil() {
- if x.ActiveDeadlineSeconds != nil {
- x.ActiveDeadlineSeconds = nil
- }
- } else {
- if x.ActiveDeadlineSeconds == nil {
- x.ActiveDeadlineSeconds = new(int64)
- }
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "dnsPolicy":
- if r.TryDecodeAsNil() {
- x.DNSPolicy = ""
- } else {
- x.DNSPolicy = DNSPolicy(r.DecodeString())
- }
- case "nodeSelector":
- if r.TryDecodeAsNil() {
- x.NodeSelector = nil
- } else {
- yyv14 := &x.NodeSelector
- yym15 := z.DecBinary()
- _ = yym15
- if false {
- } else {
- z.F.DecMapStringStringX(yyv14, false, d)
- }
- }
- case "serviceAccountName":
- if r.TryDecodeAsNil() {
- x.ServiceAccountName = ""
- } else {
- x.ServiceAccountName = string(r.DecodeString())
- }
- case "serviceAccount":
- if r.TryDecodeAsNil() {
- x.DeprecatedServiceAccount = ""
- } else {
- x.DeprecatedServiceAccount = string(r.DecodeString())
- }
- case "nodeName":
- if r.TryDecodeAsNil() {
- x.NodeName = ""
- } else {
- x.NodeName = string(r.DecodeString())
- }
- case "hostNetwork":
- if r.TryDecodeAsNil() {
- x.HostNetwork = false
- } else {
- x.HostNetwork = bool(r.DecodeBool())
- }
- case "hostPID":
- if r.TryDecodeAsNil() {
- x.HostPID = false
- } else {
- x.HostPID = bool(r.DecodeBool())
- }
- case "hostIPC":
- if r.TryDecodeAsNil() {
- x.HostIPC = false
- } else {
- x.HostIPC = bool(r.DecodeBool())
- }
- case "securityContext":
- if r.TryDecodeAsNil() {
- if x.SecurityContext != nil {
- x.SecurityContext = nil
- }
- } else {
- if x.SecurityContext == nil {
- x.SecurityContext = new(PodSecurityContext)
- }
- x.SecurityContext.CodecDecodeSelf(d)
- }
- case "imagePullSecrets":
- if r.TryDecodeAsNil() {
- x.ImagePullSecrets = nil
- } else {
- yyv23 := &x.ImagePullSecrets
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else {
- h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv23), d)
- }
- }
- case "hostname":
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- case "subdomain":
- if r.TryDecodeAsNil() {
- x.Subdomain = ""
- } else {
- x.Subdomain = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj27 int
- var yyb27 bool
- var yyhl27 bool = l >= 0
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Volumes = nil
- } else {
- yyv28 := &x.Volumes
- yym29 := z.DecBinary()
- _ = yym29
- if false {
- } else {
- h.decSliceVolume((*[]Volume)(yyv28), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Containers = nil
- } else {
- yyv30 := &x.Containers
- yym31 := z.DecBinary()
- _ = yym31
- if false {
- } else {
- h.decSliceContainer((*[]Container)(yyv30), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.RestartPolicy = ""
- } else {
- x.RestartPolicy = RestartPolicy(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TerminationGracePeriodSeconds != nil {
- x.TerminationGracePeriodSeconds = nil
- }
- } else {
- if x.TerminationGracePeriodSeconds == nil {
- x.TerminationGracePeriodSeconds = new(int64)
- }
- yym34 := z.DecBinary()
- _ = yym34
- if false {
- } else {
- *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ActiveDeadlineSeconds != nil {
- x.ActiveDeadlineSeconds = nil
- }
- } else {
- if x.ActiveDeadlineSeconds == nil {
- x.ActiveDeadlineSeconds = new(int64)
- }
- yym36 := z.DecBinary()
- _ = yym36
- if false {
- } else {
- *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DNSPolicy = ""
- } else {
- x.DNSPolicy = DNSPolicy(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NodeSelector = nil
- } else {
- yyv38 := &x.NodeSelector
- yym39 := z.DecBinary()
- _ = yym39
- if false {
- } else {
- z.F.DecMapStringStringX(yyv38, false, d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ServiceAccountName = ""
- } else {
- x.ServiceAccountName = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DeprecatedServiceAccount = ""
- } else {
- x.DeprecatedServiceAccount = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NodeName = ""
- } else {
- x.NodeName = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostNetwork = false
- } else {
- x.HostNetwork = bool(r.DecodeBool())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostPID = false
- } else {
- x.HostPID = bool(r.DecodeBool())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostIPC = false
- } else {
- x.HostIPC = bool(r.DecodeBool())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SecurityContext != nil {
- x.SecurityContext = nil
- }
- } else {
- if x.SecurityContext == nil {
- x.SecurityContext = new(PodSecurityContext)
- }
- x.SecurityContext.CodecDecodeSelf(d)
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ImagePullSecrets = nil
- } else {
- yyv47 := &x.ImagePullSecrets
- yym48 := z.DecBinary()
- _ = yym48
- if false {
- } else {
- h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv47), d)
- }
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Subdomain = ""
- } else {
- x.Subdomain = string(r.DecodeString())
- }
- for {
- yyj27++
- if yyhl27 {
- yyb27 = yyj27 > l
- } else {
- yyb27 = r.CheckBreak()
- }
- if yyb27 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj27-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.SELinuxOptions != nil
- yyq2[1] = x.RunAsUser != nil
- yyq2[2] = x.RunAsNonRoot != nil
- yyq2[3] = len(x.SupplementalGroups) != 0
- yyq2[4] = x.FSGroup != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.SELinuxOptions == nil {
- r.EncodeNil()
- } else {
- x.SELinuxOptions.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("seLinuxOptions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SELinuxOptions == nil {
- r.EncodeNil()
- } else {
- x.SELinuxOptions.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.RunAsUser == nil {
- r.EncodeNil()
- } else {
- yy7 := *x.RunAsUser
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(yy7))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("runAsUser"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RunAsUser == nil {
- r.EncodeNil()
- } else {
- yy9 := *x.RunAsUser
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(yy9))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.RunAsNonRoot == nil {
- r.EncodeNil()
- } else {
- yy12 := *x.RunAsNonRoot
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(yy12))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RunAsNonRoot == nil {
- r.EncodeNil()
- } else {
- yy14 := *x.RunAsNonRoot
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeBool(bool(yy14))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.SupplementalGroups == nil {
- r.EncodeNil()
- } else {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- z.F.EncSliceInt64V(x.SupplementalGroups, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SupplementalGroups == nil {
- r.EncodeNil()
- } else {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- z.F.EncSliceInt64V(x.SupplementalGroups, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.FSGroup == nil {
- r.EncodeNil()
- } else {
- yy20 := *x.FSGroup
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeInt(int64(yy20))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fsGroup"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FSGroup == nil {
- r.EncodeNil()
- } else {
- yy22 := *x.FSGroup
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeInt(int64(yy22))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodSecurityContext) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "seLinuxOptions":
- if r.TryDecodeAsNil() {
- if x.SELinuxOptions != nil {
- x.SELinuxOptions = nil
- }
- } else {
- if x.SELinuxOptions == nil {
- x.SELinuxOptions = new(SELinuxOptions)
- }
- x.SELinuxOptions.CodecDecodeSelf(d)
- }
- case "runAsUser":
- if r.TryDecodeAsNil() {
- if x.RunAsUser != nil {
- x.RunAsUser = nil
- }
- } else {
- if x.RunAsUser == nil {
- x.RunAsUser = new(int64)
- }
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64))
- }
- }
- case "runAsNonRoot":
- if r.TryDecodeAsNil() {
- if x.RunAsNonRoot != nil {
- x.RunAsNonRoot = nil
- }
- } else {
- if x.RunAsNonRoot == nil {
- x.RunAsNonRoot = new(bool)
- }
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- *((*bool)(x.RunAsNonRoot)) = r.DecodeBool()
- }
- }
- case "supplementalGroups":
- if r.TryDecodeAsNil() {
- x.SupplementalGroups = nil
- } else {
- yyv9 := &x.SupplementalGroups
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- z.F.DecSliceInt64X(yyv9, false, d)
- }
- }
- case "fsGroup":
- if r.TryDecodeAsNil() {
- if x.FSGroup != nil {
- x.FSGroup = nil
- }
- } else {
- if x.FSGroup == nil {
- x.FSGroup = new(int64)
- }
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64))
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj13 int
- var yyb13 bool
- var yyhl13 bool = l >= 0
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SELinuxOptions != nil {
- x.SELinuxOptions = nil
- }
- } else {
- if x.SELinuxOptions == nil {
- x.SELinuxOptions = new(SELinuxOptions)
- }
- x.SELinuxOptions.CodecDecodeSelf(d)
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RunAsUser != nil {
- x.RunAsUser = nil
- }
- } else {
- if x.RunAsUser == nil {
- x.RunAsUser = new(int64)
- }
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64))
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RunAsNonRoot != nil {
- x.RunAsNonRoot = nil
- }
- } else {
- if x.RunAsNonRoot == nil {
- x.RunAsNonRoot = new(bool)
- }
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- *((*bool)(x.RunAsNonRoot)) = r.DecodeBool()
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SupplementalGroups = nil
- } else {
- yyv19 := &x.SupplementalGroups
- yym20 := z.DecBinary()
- _ = yym20
- if false {
- } else {
- z.F.DecSliceInt64X(yyv19, false, d)
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FSGroup != nil {
- x.FSGroup = nil
- }
- } else {
- if x.FSGroup == nil {
- x.FSGroup = new(int64)
- }
- yym22 := z.DecBinary()
- _ = yym22
- if false {
- } else {
- *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64))
- }
- }
- for {
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj13-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [8]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Phase != ""
- yyq2[1] = len(x.Conditions) != 0
- yyq2[2] = x.Message != ""
- yyq2[3] = x.Reason != ""
- yyq2[4] = x.HostIP != ""
- yyq2[5] = x.PodIP != ""
- yyq2[6] = x.StartTime != nil
- yyq2[7] = len(x.ContainerStatuses) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(8)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Phase.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("phase"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Phase.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSlicePodCondition(([]PodCondition)(x.Conditions), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("conditions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSlicePodCondition(([]PodCondition)(x.Conditions), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.HostIP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostIP"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.HostIP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PodIP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("podIP"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PodIP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.StartTime == nil {
- r.EncodeNil()
- } else {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else if z.HasExtensions() && z.EncExt(x.StartTime) {
- } else if yym22 {
- z.EncBinaryMarshal(x.StartTime)
- } else if !yym22 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.StartTime)
- } else {
- z.EncFallback(x.StartTime)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("startTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.StartTime == nil {
- r.EncodeNil()
- } else {
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else if z.HasExtensions() && z.EncExt(x.StartTime) {
- } else if yym23 {
- z.EncBinaryMarshal(x.StartTime)
- } else if !yym23 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.StartTime)
- } else {
- z.EncFallback(x.StartTime)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.ContainerStatuses == nil {
- r.EncodeNil()
- } else {
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerStatuses"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ContainerStatuses == nil {
- r.EncodeNil()
- } else {
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "phase":
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PodPhase(r.DecodeString())
- }
- case "conditions":
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv5 := &x.Conditions
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSlicePodCondition((*[]PodCondition)(yyv5), d)
- }
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "hostIP":
- if r.TryDecodeAsNil() {
- x.HostIP = ""
- } else {
- x.HostIP = string(r.DecodeString())
- }
- case "podIP":
- if r.TryDecodeAsNil() {
- x.PodIP = ""
- } else {
- x.PodIP = string(r.DecodeString())
- }
- case "startTime":
- if r.TryDecodeAsNil() {
- if x.StartTime != nil {
- x.StartTime = nil
- }
- } else {
- if x.StartTime == nil {
- x.StartTime = new(pkg2_unversioned.Time)
- }
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(x.StartTime) {
- } else if yym12 {
- z.DecBinaryUnmarshal(x.StartTime)
- } else if !yym12 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.StartTime)
- } else {
- z.DecFallback(x.StartTime, false)
- }
- }
- case "containerStatuses":
- if r.TryDecodeAsNil() {
- x.ContainerStatuses = nil
- } else {
- yyv13 := &x.ContainerStatuses
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceContainerStatus((*[]ContainerStatus)(yyv13), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj15 int
- var yyb15 bool
- var yyhl15 bool = l >= 0
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = PodPhase(r.DecodeString())
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv17 := &x.Conditions
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- h.decSlicePodCondition((*[]PodCondition)(yyv17), d)
- }
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.HostIP = ""
- } else {
- x.HostIP = string(r.DecodeString())
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PodIP = ""
- } else {
- x.PodIP = string(r.DecodeString())
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.StartTime != nil {
- x.StartTime = nil
- }
- } else {
- if x.StartTime == nil {
- x.StartTime = new(pkg2_unversioned.Time)
- }
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else if z.HasExtensions() && z.DecExt(x.StartTime) {
- } else if yym24 {
- z.DecBinaryUnmarshal(x.StartTime)
- } else if !yym24 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.StartTime)
- } else {
- z.DecFallback(x.StartTime, false)
- }
- }
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerStatuses = nil
- } else {
- yyv25 := &x.ContainerStatuses
- yym26 := z.DecBinary()
- _ = yym26
- if false {
- } else {
- h.decSliceContainerStatus((*[]ContainerStatus)(yyv25), d)
- }
- }
- for {
- yyj15++
- if yyhl15 {
- yyb15 = yyj15 > l
- } else {
- yyb15 = r.CheckBreak()
- }
- if yyb15 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj15-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodStatusResult) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Status
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Status
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodStatusResult) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodStatusResult) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = PodStatus{}
- } else {
- yyv5 := &x.Status
- yyv5.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodStatusResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv9 := &x.ObjectMeta
- yyv9.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = PodStatus{}
- } else {
- yyv10 := &x.Status
- yyv10.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Pod) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Pod) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Pod) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = PodSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = PodStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = PodSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = PodStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSlicePod(([]Pod)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSlicePod(([]Pod)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSlicePod((*[]Pod)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSlicePod((*[]Pod)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodTemplateSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodTemplateSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = PodSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv7 := &x.ObjectMeta
- yyv7.CodecDecodeSelf(d)
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = PodSpec{}
- } else {
- yyv8 := &x.Spec
- yyv8.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodTemplate) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Template
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("template"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Template
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodTemplate) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "template":
- if r.TryDecodeAsNil() {
- x.Template = PodTemplateSpec{}
- } else {
- yyv5 := &x.Template
- yyv5.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv9 := &x.ObjectMeta
- yyv9.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Template = PodTemplateSpec{}
- } else {
- yyv10 := &x.Template
- yyv10.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodTemplateList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSlicePodTemplate(([]PodTemplate)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSlicePodTemplate(([]PodTemplate)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodTemplateList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodTemplateList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSlicePodTemplate((*[]PodTemplate)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodTemplateList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSlicePodTemplate((*[]PodTemplate)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Replicas != nil
- yyq2[1] = len(x.Selector) != 0
- yyq2[2] = x.Template != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Replicas == nil {
- r.EncodeNil()
- } else {
- yy4 := *x.Replicas
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(yy4))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("replicas"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Replicas == nil {
- r.EncodeNil()
- } else {
- yy6 := *x.Replicas
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(yy6))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- z.F.EncMapStringStringV(x.Selector, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("selector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- z.F.EncMapStringStringV(x.Selector, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Template == nil {
- r.EncodeNil()
- } else {
- x.Template.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("template"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Template == nil {
- r.EncodeNil()
- } else {
- x.Template.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ReplicationControllerSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "replicas":
- if r.TryDecodeAsNil() {
- if x.Replicas != nil {
- x.Replicas = nil
- }
- } else {
- if x.Replicas == nil {
- x.Replicas = new(int32)
- }
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- *((*int32)(x.Replicas)) = int32(r.DecodeInt(32))
- }
- }
- case "selector":
- if r.TryDecodeAsNil() {
- x.Selector = nil
- } else {
- yyv6 := &x.Selector
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- z.F.DecMapStringStringX(yyv6, false, d)
- }
- }
- case "template":
- if r.TryDecodeAsNil() {
- if x.Template != nil {
- x.Template = nil
- }
- } else {
- if x.Template == nil {
- x.Template = new(PodTemplateSpec)
- }
- x.Template.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Replicas != nil {
- x.Replicas = nil
- }
- } else {
- if x.Replicas == nil {
- x.Replicas = new(int32)
- }
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else {
- *((*int32)(x.Replicas)) = int32(r.DecodeInt(32))
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Selector = nil
- } else {
- yyv12 := &x.Selector
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- z.F.DecMapStringStringX(yyv12, false, d)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Template != nil {
- x.Template = nil
- }
- } else {
- if x.Template == nil {
- x.Template = new(PodTemplateSpec)
- }
- x.Template.CodecDecodeSelf(d)
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FullyLabeledReplicas != 0
- yyq2[2] = x.ObservedGeneration != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.Replicas))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("replicas"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.Replicas))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.FullyLabeledReplicas))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.FullyLabeledReplicas))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.ObservedGeneration))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("observedGeneration"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.ObservedGeneration))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ReplicationControllerStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ReplicationControllerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "replicas":
- if r.TryDecodeAsNil() {
- x.Replicas = 0
- } else {
- x.Replicas = int32(r.DecodeInt(32))
- }
- case "fullyLabeledReplicas":
- if r.TryDecodeAsNil() {
- x.FullyLabeledReplicas = 0
- } else {
- x.FullyLabeledReplicas = int32(r.DecodeInt(32))
- }
- case "observedGeneration":
- if r.TryDecodeAsNil() {
- x.ObservedGeneration = 0
- } else {
- x.ObservedGeneration = int64(r.DecodeInt(64))
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Replicas = 0
- } else {
- x.Replicas = int32(r.DecodeInt(32))
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FullyLabeledReplicas = 0
- } else {
- x.FullyLabeledReplicas = int32(r.DecodeInt(32))
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObservedGeneration = 0
- } else {
- x.ObservedGeneration = int64(r.DecodeInt(64))
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ReplicationController) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ReplicationController) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ReplicationController) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = ReplicationControllerSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ReplicationControllerStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = ReplicationControllerSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ReplicationControllerStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ReplicationControllerList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceReplicationController(([]ReplicationController)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceReplicationController(([]ReplicationController)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ReplicationControllerList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ReplicationControllerList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceReplicationController((*[]ReplicationController)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ReplicationControllerList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceReplicationController((*[]ReplicationController)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x ServiceAffinity) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ServiceAffinity) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x ServiceType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ServiceType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *ServiceStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.LoadBalancer
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("loadBalancer"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.LoadBalancer
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "loadBalancer":
- if r.TryDecodeAsNil() {
- x.LoadBalancer = LoadBalancerStatus{}
- } else {
- yyv4 := &x.LoadBalancer
- yyv4.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LoadBalancer = LoadBalancerStatus{}
- } else {
- yyv6 := &x.LoadBalancer
- yyv6.CodecDecodeSelf(d)
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LoadBalancerStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Ingress) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Ingress == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ingress"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Ingress == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LoadBalancerStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LoadBalancerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "ingress":
- if r.TryDecodeAsNil() {
- x.Ingress = nil
- } else {
- yyv4 := &x.Ingress
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LoadBalancerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Ingress = nil
- } else {
- yyv7 := &x.Ingress
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LoadBalancerIngress) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.IP != ""
- yyq2[1] = x.Hostname != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ip"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostname"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LoadBalancerIngress) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LoadBalancerIngress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "ip":
- if r.TryDecodeAsNil() {
- x.IP = ""
- } else {
- x.IP = string(r.DecodeString())
- }
- case "hostname":
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LoadBalancerIngress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.IP = ""
- } else {
- x.IP = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [9]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = len(x.Selector) != 0
- yyq2[2] = x.ClusterIP != ""
- yyq2[3] = x.Type != ""
- yyq2[4] = len(x.ExternalIPs) != 0
- yyq2[5] = len(x.DeprecatedPublicIPs) != 0
- yyq2[6] = x.SessionAffinity != ""
- yyq2[7] = x.LoadBalancerIP != ""
- yyq2[8] = len(x.LoadBalancerSourceRanges) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(9)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceServicePort(([]ServicePort)(x.Ports), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ports"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceServicePort(([]ServicePort)(x.Ports), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- z.F.EncMapStringStringV(x.Selector, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("selector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Selector == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- z.F.EncMapStringStringV(x.Selector, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("clusterIP"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.Type.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.ExternalIPs == nil {
- r.EncodeNil()
- } else {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- z.F.EncSliceStringV(x.ExternalIPs, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("externalIPs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ExternalIPs == nil {
- r.EncodeNil()
- } else {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- z.F.EncSliceStringV(x.ExternalIPs, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.DeprecatedPublicIPs == nil {
- r.EncodeNil()
- } else {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("deprecatedPublicIPs"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.DeprecatedPublicIPs == nil {
- r.EncodeNil()
- } else {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- x.SessionAffinity.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("sessionAffinity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.SessionAffinity.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("loadBalancerIP"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.LoadBalancerSourceRanges == nil {
- r.EncodeNil()
- } else {
- yym28 := z.EncBinary()
- _ = yym28
- if false {
- } else {
- z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("loadBalancerSourceRanges"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.LoadBalancerSourceRanges == nil {
- r.EncodeNil()
- } else {
- yym29 := z.EncBinary()
- _ = yym29
- if false {
- } else {
- z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "ports":
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv4 := &x.Ports
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceServicePort((*[]ServicePort)(yyv4), d)
- }
- }
- case "selector":
- if r.TryDecodeAsNil() {
- x.Selector = nil
- } else {
- yyv6 := &x.Selector
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- z.F.DecMapStringStringX(yyv6, false, d)
- }
- }
- case "clusterIP":
- if r.TryDecodeAsNil() {
- x.ClusterIP = ""
- } else {
- x.ClusterIP = string(r.DecodeString())
- }
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = ServiceType(r.DecodeString())
- }
- case "externalIPs":
- if r.TryDecodeAsNil() {
- x.ExternalIPs = nil
- } else {
- yyv10 := &x.ExternalIPs
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else {
- z.F.DecSliceStringX(yyv10, false, d)
- }
- }
- case "deprecatedPublicIPs":
- if r.TryDecodeAsNil() {
- x.DeprecatedPublicIPs = nil
- } else {
- yyv12 := &x.DeprecatedPublicIPs
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- z.F.DecSliceStringX(yyv12, false, d)
- }
- }
- case "sessionAffinity":
- if r.TryDecodeAsNil() {
- x.SessionAffinity = ""
- } else {
- x.SessionAffinity = ServiceAffinity(r.DecodeString())
- }
- case "loadBalancerIP":
- if r.TryDecodeAsNil() {
- x.LoadBalancerIP = ""
- } else {
- x.LoadBalancerIP = string(r.DecodeString())
- }
- case "loadBalancerSourceRanges":
- if r.TryDecodeAsNil() {
- x.LoadBalancerSourceRanges = nil
- } else {
- yyv16 := &x.LoadBalancerSourceRanges
- yym17 := z.DecBinary()
- _ = yym17
- if false {
- } else {
- z.F.DecSliceStringX(yyv16, false, d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj18 int
- var yyb18 bool
- var yyhl18 bool = l >= 0
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv19 := &x.Ports
- yym20 := z.DecBinary()
- _ = yym20
- if false {
- } else {
- h.decSliceServicePort((*[]ServicePort)(yyv19), d)
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Selector = nil
- } else {
- yyv21 := &x.Selector
- yym22 := z.DecBinary()
- _ = yym22
- if false {
- } else {
- z.F.DecMapStringStringX(yyv21, false, d)
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ClusterIP = ""
- } else {
- x.ClusterIP = string(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = ServiceType(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ExternalIPs = nil
- } else {
- yyv25 := &x.ExternalIPs
- yym26 := z.DecBinary()
- _ = yym26
- if false {
- } else {
- z.F.DecSliceStringX(yyv25, false, d)
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DeprecatedPublicIPs = nil
- } else {
- yyv27 := &x.DeprecatedPublicIPs
- yym28 := z.DecBinary()
- _ = yym28
- if false {
- } else {
- z.F.DecSliceStringX(yyv27, false, d)
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SessionAffinity = ""
- } else {
- x.SessionAffinity = ServiceAffinity(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LoadBalancerIP = ""
- } else {
- x.LoadBalancerIP = string(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LoadBalancerSourceRanges = nil
- } else {
- yyv31 := &x.LoadBalancerSourceRanges
- yym32 := z.DecBinary()
- _ = yym32
- if false {
- } else {
- z.F.DecSliceStringX(yyv31, false, d)
- }
- }
- for {
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj18-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServicePort) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Name != ""
- yyq2[1] = x.Protocol != ""
- yyq2[3] = true
- yyq2[4] = x.NodePort != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- x.Protocol.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("protocol"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Protocol.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("port"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yy13 := &x.TargetPort
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.EncExt(yy13) {
- } else if !yym14 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy13)
- } else {
- z.EncFallback(yy13)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("targetPort"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy15 := &x.TargetPort
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.EncExt(yy15) {
- } else if !yym16 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy15)
- } else {
- z.EncFallback(yy15)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeInt(int64(x.NodePort))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodePort"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeInt(int64(x.NodePort))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServicePort) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServicePort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "protocol":
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- case "port":
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- case "targetPort":
- if r.TryDecodeAsNil() {
- x.TargetPort = pkg4_intstr.IntOrString{}
- } else {
- yyv7 := &x.TargetPort
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv7) {
- } else if !yym8 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv7)
- } else {
- z.DecFallback(yyv7, false)
- }
- }
- case "nodePort":
- if r.TryDecodeAsNil() {
- x.NodePort = 0
- } else {
- x.NodePort = int32(r.DecodeInt(32))
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TargetPort = pkg4_intstr.IntOrString{}
- } else {
- yyv14 := &x.TargetPort
- yym15 := z.DecBinary()
- _ = yym15
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv14) {
- } else if !yym15 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv14)
- } else {
- z.DecFallback(yyv14, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NodePort = 0
- } else {
- x.NodePort = int32(r.DecodeInt(32))
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Service) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Service) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = ServiceSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ServiceStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = ServiceSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ServiceStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServiceList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceService(([]Service)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceService(([]Service)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceService((*[]Service)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceService((*[]Service)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = len(x.Secrets) != 0
- yyq2[2] = len(x.ImagePullSecrets) != 0
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Secrets == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("secrets"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Secrets == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.ImagePullSecrets == nil {
- r.EncodeNil()
- } else {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ImagePullSecrets == nil {
- r.EncodeNil()
- } else {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceAccount) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceAccount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "secrets":
- if r.TryDecodeAsNil() {
- x.Secrets = nil
- } else {
- yyv5 := &x.Secrets
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSliceObjectReference((*[]ObjectReference)(yyv5), d)
- }
- }
- case "imagePullSecrets":
- if r.TryDecodeAsNil() {
- x.ImagePullSecrets = nil
- } else {
- yyv7 := &x.ImagePullSecrets
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv7), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv12 := &x.ObjectMeta
- yyv12.CodecDecodeSelf(d)
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Secrets = nil
- } else {
- yyv13 := &x.Secrets
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceObjectReference((*[]ObjectReference)(yyv13), d)
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ImagePullSecrets = nil
- } else {
- yyv15 := &x.ImagePullSecrets
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv15), d)
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServiceAccountList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceAccountList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceAccountList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceServiceAccount((*[]ServiceAccount)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceAccountList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceServiceAccount((*[]ServiceAccount)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Endpoints) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Subsets == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("subsets"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Subsets == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Endpoints) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Endpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "subsets":
- if r.TryDecodeAsNil() {
- x.Subsets = nil
- } else {
- yyv5 := &x.Subsets
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSliceEndpointSubset((*[]EndpointSubset)(yyv5), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Endpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Subsets = nil
- } else {
- yyv11 := &x.Subsets
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceEndpointSubset((*[]EndpointSubset)(yyv11), d)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Addresses) != 0
- yyq2[1] = len(x.NotReadyAddresses) != 0
- yyq2[2] = len(x.Ports) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Addresses == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("addresses"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Addresses == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.NotReadyAddresses == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("notReadyAddresses"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.NotReadyAddresses == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ports"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Ports == nil {
- r.EncodeNil()
- } else {
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EndpointSubset) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EndpointSubset) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "addresses":
- if r.TryDecodeAsNil() {
- x.Addresses = nil
- } else {
- yyv4 := &x.Addresses
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceEndpointAddress((*[]EndpointAddress)(yyv4), d)
- }
- }
- case "notReadyAddresses":
- if r.TryDecodeAsNil() {
- x.NotReadyAddresses = nil
- } else {
- yyv6 := &x.NotReadyAddresses
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceEndpointAddress((*[]EndpointAddress)(yyv6), d)
- }
- }
- case "ports":
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv8 := &x.Ports
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- h.decSliceEndpointPort((*[]EndpointPort)(yyv8), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EndpointSubset) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Addresses = nil
- } else {
- yyv11 := &x.Addresses
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceEndpointAddress((*[]EndpointAddress)(yyv11), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NotReadyAddresses = nil
- } else {
- yyv13 := &x.NotReadyAddresses
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceEndpointAddress((*[]EndpointAddress)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Ports = nil
- } else {
- yyv15 := &x.Ports
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- h.decSliceEndpointPort((*[]EndpointPort)(yyv15), d)
- }
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.Hostname != ""
- yyq2[2] = x.TargetRef != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IP))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("ip"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.IP))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hostname"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Hostname))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.TargetRef == nil {
- r.EncodeNil()
- } else {
- x.TargetRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("targetRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TargetRef == nil {
- r.EncodeNil()
- } else {
- x.TargetRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EndpointAddress) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EndpointAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "ip":
- if r.TryDecodeAsNil() {
- x.IP = ""
- } else {
- x.IP = string(r.DecodeString())
- }
- case "hostname":
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- case "targetRef":
- if r.TryDecodeAsNil() {
- if x.TargetRef != nil {
- x.TargetRef = nil
- }
- } else {
- if x.TargetRef == nil {
- x.TargetRef = new(ObjectReference)
- }
- x.TargetRef.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.IP = ""
- } else {
- x.IP = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Hostname = ""
- } else {
- x.Hostname = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TargetRef != nil {
- x.TargetRef = nil
- }
- } else {
- if x.TargetRef == nil {
- x.TargetRef = new(ObjectReference)
- }
- x.TargetRef.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EndpointPort) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Name != ""
- yyq2[2] = x.Protocol != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("port"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- x.Protocol.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("protocol"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Protocol.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EndpointPort) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EndpointPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "port":
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- case "protocol":
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EndpointPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Protocol = ""
- } else {
- x.Protocol = Protocol(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EndpointsList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceEndpoints(([]Endpoints)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceEndpoints(([]Endpoints)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EndpointsList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EndpointsList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceEndpoints((*[]Endpoints)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EndpointsList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceEndpoints((*[]Endpoints)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.PodCIDR != ""
- yyq2[1] = x.ExternalID != ""
- yyq2[2] = x.ProviderID != ""
- yyq2[3] = x.Unschedulable != false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("podCIDR"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("externalID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("providerID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.Unschedulable))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("unschedulable"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.Unschedulable))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "podCIDR":
- if r.TryDecodeAsNil() {
- x.PodCIDR = ""
- } else {
- x.PodCIDR = string(r.DecodeString())
- }
- case "externalID":
- if r.TryDecodeAsNil() {
- x.ExternalID = ""
- } else {
- x.ExternalID = string(r.DecodeString())
- }
- case "providerID":
- if r.TryDecodeAsNil() {
- x.ProviderID = ""
- } else {
- x.ProviderID = string(r.DecodeString())
- }
- case "unschedulable":
- if r.TryDecodeAsNil() {
- x.Unschedulable = false
- } else {
- x.Unschedulable = bool(r.DecodeBool())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.PodCIDR = ""
- } else {
- x.PodCIDR = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ExternalID = ""
- } else {
- x.ExternalID = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ProviderID = ""
- } else {
- x.ProviderID = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Unschedulable = false
- } else {
- x.Unschedulable = bool(r.DecodeBool())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *DaemonEndpoint) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("Port"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(x.Port))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *DaemonEndpoint) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *DaemonEndpoint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "Port":
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *DaemonEndpoint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Port = 0
- } else {
- x.Port = int32(r.DecodeInt(32))
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeDaemonEndpoints) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.KubeletEndpoint
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kubeletEndpoint"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.KubeletEndpoint
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeDaemonEndpoints) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeDaemonEndpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "kubeletEndpoint":
- if r.TryDecodeAsNil() {
- x.KubeletEndpoint = DaemonEndpoint{}
- } else {
- yyv4 := &x.KubeletEndpoint
- yyv4.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeDaemonEndpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.KubeletEndpoint = DaemonEndpoint{}
- } else {
- yyv6 := &x.KubeletEndpoint
- yyv6.CodecDecodeSelf(d)
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [10]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(10)
- } else {
- yynn2 = 10
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.MachineID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("machineID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.MachineID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("systemUUID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.BootID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("bootID"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.BootID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kernelVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.OSImage))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("osImage"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.OSImage))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("containerRuntimeVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kubeletVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kubeProxyVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym28 := z.EncBinary()
- _ = yym28
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("operatingSystem"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym29 := z.EncBinary()
- _ = yym29
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym31 := z.EncBinary()
- _ = yym31
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Architecture))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("architecture"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym32 := z.EncBinary()
- _ = yym32
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Architecture))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeSystemInfo) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeSystemInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "machineID":
- if r.TryDecodeAsNil() {
- x.MachineID = ""
- } else {
- x.MachineID = string(r.DecodeString())
- }
- case "systemUUID":
- if r.TryDecodeAsNil() {
- x.SystemUUID = ""
- } else {
- x.SystemUUID = string(r.DecodeString())
- }
- case "bootID":
- if r.TryDecodeAsNil() {
- x.BootID = ""
- } else {
- x.BootID = string(r.DecodeString())
- }
- case "kernelVersion":
- if r.TryDecodeAsNil() {
- x.KernelVersion = ""
- } else {
- x.KernelVersion = string(r.DecodeString())
- }
- case "osImage":
- if r.TryDecodeAsNil() {
- x.OSImage = ""
- } else {
- x.OSImage = string(r.DecodeString())
- }
- case "containerRuntimeVersion":
- if r.TryDecodeAsNil() {
- x.ContainerRuntimeVersion = ""
- } else {
- x.ContainerRuntimeVersion = string(r.DecodeString())
- }
- case "kubeletVersion":
- if r.TryDecodeAsNil() {
- x.KubeletVersion = ""
- } else {
- x.KubeletVersion = string(r.DecodeString())
- }
- case "kubeProxyVersion":
- if r.TryDecodeAsNil() {
- x.KubeProxyVersion = ""
- } else {
- x.KubeProxyVersion = string(r.DecodeString())
- }
- case "operatingSystem":
- if r.TryDecodeAsNil() {
- x.OperatingSystem = ""
- } else {
- x.OperatingSystem = string(r.DecodeString())
- }
- case "architecture":
- if r.TryDecodeAsNil() {
- x.Architecture = ""
- } else {
- x.Architecture = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj14 int
- var yyb14 bool
- var yyhl14 bool = l >= 0
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.MachineID = ""
- } else {
- x.MachineID = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SystemUUID = ""
- } else {
- x.SystemUUID = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.BootID = ""
- } else {
- x.BootID = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.KernelVersion = ""
- } else {
- x.KernelVersion = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.OSImage = ""
- } else {
- x.OSImage = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ContainerRuntimeVersion = ""
- } else {
- x.ContainerRuntimeVersion = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.KubeletVersion = ""
- } else {
- x.KubeletVersion = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.KubeProxyVersion = ""
- } else {
- x.KubeProxyVersion = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.OperatingSystem = ""
- } else {
- x.OperatingSystem = string(r.DecodeString())
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Architecture = ""
- } else {
- x.Architecture = string(r.DecodeString())
- }
- for {
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj14-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [10]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Capacity) != 0
- yyq2[1] = len(x.Allocatable) != 0
- yyq2[2] = x.Phase != ""
- yyq2[3] = len(x.Conditions) != 0
- yyq2[4] = len(x.Addresses) != 0
- yyq2[5] = true
- yyq2[6] = true
- yyq2[7] = len(x.Images) != 0
- yyq2[8] = len(x.VolumesInUse) != 0
- yyq2[9] = len(x.VolumesAttached) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(10)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("capacity"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Capacity == nil {
- r.EncodeNil()
- } else {
- x.Capacity.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Allocatable == nil {
- r.EncodeNil()
- } else {
- x.Allocatable.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("allocatable"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Allocatable == nil {
- r.EncodeNil()
- } else {
- x.Allocatable.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- x.Phase.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("phase"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Phase.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("conditions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.Addresses == nil {
- r.EncodeNil()
- } else {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("addresses"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Addresses == nil {
- r.EncodeNil()
- } else {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yy19 := &x.DaemonEndpoints
- yy19.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("daemonEndpoints"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy21 := &x.DaemonEndpoints
- yy21.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yy24 := &x.NodeInfo
- yy24.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("nodeInfo"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy26 := &x.NodeInfo
- yy26.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.Images == nil {
- r.EncodeNil()
- } else {
- yym29 := z.EncBinary()
- _ = yym29
- if false {
- } else {
- h.encSliceContainerImage(([]ContainerImage)(x.Images), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("images"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Images == nil {
- r.EncodeNil()
- } else {
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else {
- h.encSliceContainerImage(([]ContainerImage)(x.Images), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- if x.VolumesInUse == nil {
- r.EncodeNil()
- } else {
- yym32 := z.EncBinary()
- _ = yym32
- if false {
- } else {
- h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumesInUse"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.VolumesInUse == nil {
- r.EncodeNil()
- } else {
- yym33 := z.EncBinary()
- _ = yym33
- if false {
- } else {
- h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- if x.VolumesAttached == nil {
- r.EncodeNil()
- } else {
- yym35 := z.EncBinary()
- _ = yym35
- if false {
- } else {
- h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("volumesAttached"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.VolumesAttached == nil {
- r.EncodeNil()
- } else {
- yym36 := z.EncBinary()
- _ = yym36
- if false {
- } else {
- h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "capacity":
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv4 := &x.Capacity
- yyv4.CodecDecodeSelf(d)
- }
- case "allocatable":
- if r.TryDecodeAsNil() {
- x.Allocatable = nil
- } else {
- yyv5 := &x.Allocatable
- yyv5.CodecDecodeSelf(d)
- }
- case "phase":
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = NodePhase(r.DecodeString())
- }
- case "conditions":
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv7 := &x.Conditions
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceNodeCondition((*[]NodeCondition)(yyv7), d)
- }
- }
- case "addresses":
- if r.TryDecodeAsNil() {
- x.Addresses = nil
- } else {
- yyv9 := &x.Addresses
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSliceNodeAddress((*[]NodeAddress)(yyv9), d)
- }
- }
- case "daemonEndpoints":
- if r.TryDecodeAsNil() {
- x.DaemonEndpoints = NodeDaemonEndpoints{}
- } else {
- yyv11 := &x.DaemonEndpoints
- yyv11.CodecDecodeSelf(d)
- }
- case "nodeInfo":
- if r.TryDecodeAsNil() {
- x.NodeInfo = NodeSystemInfo{}
- } else {
- yyv12 := &x.NodeInfo
- yyv12.CodecDecodeSelf(d)
- }
- case "images":
- if r.TryDecodeAsNil() {
- x.Images = nil
- } else {
- yyv13 := &x.Images
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceContainerImage((*[]ContainerImage)(yyv13), d)
- }
- }
- case "volumesInUse":
- if r.TryDecodeAsNil() {
- x.VolumesInUse = nil
- } else {
- yyv15 := &x.VolumesInUse
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv15), d)
- }
- }
- case "volumesAttached":
- if r.TryDecodeAsNil() {
- x.VolumesAttached = nil
- } else {
- yyv17 := &x.VolumesAttached
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- h.decSliceAttachedVolume((*[]AttachedVolume)(yyv17), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj19 int
- var yyb19 bool
- var yyhl19 bool = l >= 0
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Capacity = nil
- } else {
- yyv20 := &x.Capacity
- yyv20.CodecDecodeSelf(d)
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Allocatable = nil
- } else {
- yyv21 := &x.Allocatable
- yyv21.CodecDecodeSelf(d)
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = NodePhase(r.DecodeString())
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv23 := &x.Conditions
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else {
- h.decSliceNodeCondition((*[]NodeCondition)(yyv23), d)
- }
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Addresses = nil
- } else {
- yyv25 := &x.Addresses
- yym26 := z.DecBinary()
- _ = yym26
- if false {
- } else {
- h.decSliceNodeAddress((*[]NodeAddress)(yyv25), d)
- }
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DaemonEndpoints = NodeDaemonEndpoints{}
- } else {
- yyv27 := &x.DaemonEndpoints
- yyv27.CodecDecodeSelf(d)
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.NodeInfo = NodeSystemInfo{}
- } else {
- yyv28 := &x.NodeInfo
- yyv28.CodecDecodeSelf(d)
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Images = nil
- } else {
- yyv29 := &x.Images
- yym30 := z.DecBinary()
- _ = yym30
- if false {
- } else {
- h.decSliceContainerImage((*[]ContainerImage)(yyv29), d)
- }
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumesInUse = nil
- } else {
- yyv31 := &x.VolumesInUse
- yym32 := z.DecBinary()
- _ = yym32
- if false {
- } else {
- h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv31), d)
- }
- }
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.VolumesAttached = nil
- } else {
- yyv33 := &x.VolumesAttached
- yym34 := z.DecBinary()
- _ = yym34
- if false {
- } else {
- h.decSliceAttachedVolume((*[]AttachedVolume)(yyv33), d)
- }
- }
- for {
- yyj19++
- if yyhl19 {
- yyb19 = yyj19 > l
- } else {
- yyb19 = r.CheckBreak()
- }
- if yyb19 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj19-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x UniqueVolumeName) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *UniqueVolumeName) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *AttachedVolume) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Name.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Name.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("devicePath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *AttachedVolume) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *AttachedVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = UniqueVolumeName(r.DecodeString())
- }
- case "devicePath":
- if r.TryDecodeAsNil() {
- x.DevicePath = ""
- } else {
- x.DevicePath = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *AttachedVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = UniqueVolumeName(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DevicePath = ""
- } else {
- x.DevicePath = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ContainerImage) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.SizeBytes != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Names == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- z.F.EncSliceStringV(x.Names, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("names"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Names == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- z.F.EncSliceStringV(x.Names, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(x.SizeBytes))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("sizeBytes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeInt(int64(x.SizeBytes))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ContainerImage) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ContainerImage) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "names":
- if r.TryDecodeAsNil() {
- x.Names = nil
- } else {
- yyv4 := &x.Names
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- z.F.DecSliceStringX(yyv4, false, d)
- }
- }
- case "sizeBytes":
- if r.TryDecodeAsNil() {
- x.SizeBytes = 0
- } else {
- x.SizeBytes = int64(r.DecodeInt(64))
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ContainerImage) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Names = nil
- } else {
- yyv8 := &x.Names
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- z.F.DecSliceStringX(yyv8, false, d)
- }
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.SizeBytes = 0
- } else {
- x.SizeBytes = int64(r.DecodeInt(64))
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x NodePhase) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *NodePhase) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x NodeConditionType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *NodeConditionType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = true
- yyq2[3] = true
- yyq2[4] = x.Reason != ""
- yyq2[5] = x.Message != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Type.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Status.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Status.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy10 := &x.LastHeartbeatTime
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else if z.HasExtensions() && z.EncExt(yy10) {
- } else if yym11 {
- z.EncBinaryMarshal(yy10)
- } else if !yym11 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy10)
- } else {
- z.EncFallback(yy10)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastHeartbeatTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy12 := &x.LastHeartbeatTime
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else if z.HasExtensions() && z.EncExt(yy12) {
- } else if yym13 {
- z.EncBinaryMarshal(yy12)
- } else if !yym13 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy12)
- } else {
- z.EncFallback(yy12)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yy15 := &x.LastTransitionTime
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.EncExt(yy15) {
- } else if yym16 {
- z.EncBinaryMarshal(yy15)
- } else if !yym16 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy15)
- } else {
- z.EncFallback(yy15)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy17 := &x.LastTransitionTime
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else if z.HasExtensions() && z.EncExt(yy17) {
- } else if yym18 {
- z.EncBinaryMarshal(yy17)
- } else if !yym18 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy17)
- } else {
- z.EncFallback(yy17)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym24 := z.EncBinary()
- _ = yym24
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeCondition) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = NodeConditionType(r.DecodeString())
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- case "lastHeartbeatTime":
- if r.TryDecodeAsNil() {
- x.LastHeartbeatTime = pkg2_unversioned.Time{}
- } else {
- yyv6 := &x.LastHeartbeatTime
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv6) {
- } else if yym7 {
- z.DecBinaryUnmarshal(yyv6)
- } else if !yym7 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv6)
- } else {
- z.DecFallback(yyv6, false)
- }
- }
- case "lastTransitionTime":
- if r.TryDecodeAsNil() {
- x.LastTransitionTime = pkg2_unversioned.Time{}
- } else {
- yyv8 := &x.LastTransitionTime
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv8) {
- } else if yym9 {
- z.DecBinaryUnmarshal(yyv8)
- } else if !yym9 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv8)
- } else {
- z.DecFallback(yyv8, false)
- }
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = NodeConditionType(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastHeartbeatTime = pkg2_unversioned.Time{}
- } else {
- yyv15 := &x.LastHeartbeatTime
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv15) {
- } else if yym16 {
- z.DecBinaryUnmarshal(yyv15)
- } else if !yym16 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv15)
- } else {
- z.DecFallback(yyv15, false)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastTransitionTime = pkg2_unversioned.Time{}
- } else {
- yyv17 := &x.LastTransitionTime
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv17) {
- } else if yym18 {
- z.DecBinaryUnmarshal(yyv17)
- } else if !yym18 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv17)
- } else {
- z.DecFallback(yyv17, false)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x NodeAddressType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *NodeAddressType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *NodeAddress) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Type.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Address))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("address"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Address))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeAddress) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = NodeAddressType(r.DecodeString())
- }
- case "address":
- if r.TryDecodeAsNil() {
- x.Address = ""
- } else {
- x.Address = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = NodeAddressType(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Address = ""
- } else {
- x.Address = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x ResourceName) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ResourceName) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x ResourceList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- h.encResourceList((ResourceList)(x), e)
- }
- }
-}
-
-func (x *ResourceList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- h.decResourceList((*ResourceList)(x), d)
- }
-}
-
-func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Node) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = NodeSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = NodeStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = NodeSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = NodeStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceNode(([]Node)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceNode(([]Node)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceNode((*[]Node)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceNode((*[]Node)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x FinalizerName) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *FinalizerName) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *NamespaceSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Finalizers) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Finalizers == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("finalizers"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Finalizers == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NamespaceSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NamespaceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "finalizers":
- if r.TryDecodeAsNil() {
- x.Finalizers = nil
- } else {
- yyv4 := &x.Finalizers
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceFinalizerName((*[]FinalizerName)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NamespaceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Finalizers = nil
- } else {
- yyv7 := &x.Finalizers
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceFinalizerName((*[]FinalizerName)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NamespaceStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Phase != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Phase.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("phase"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Phase.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NamespaceStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NamespaceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "phase":
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = NamespacePhase(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NamespaceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Phase = ""
- } else {
- x.Phase = NamespacePhase(r.DecodeString())
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x NamespacePhase) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *NamespacePhase) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *Namespace) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Namespace) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Namespace) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = NamespaceSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = NamespaceStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = NamespaceSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = NamespaceStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NamespaceList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceNamespace(([]Namespace)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceNamespace(([]Namespace)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NamespaceList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NamespaceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceNamespace((*[]Namespace)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NamespaceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceNamespace((*[]Namespace)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Binding) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy9 := &x.Target
- yy9.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("target"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Target
- yy11.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Binding) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Binding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "target":
- if r.TryDecodeAsNil() {
- x.Target = ObjectReference{}
- } else {
- yyv5 := &x.Target
- yyv5.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Binding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv9 := &x.ObjectMeta
- yyv9.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Target = ObjectReference{}
- } else {
- yyv10 := &x.Target
- yyv10.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Preconditions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.UID != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.UID == nil {
- r.EncodeNil()
- } else {
- yy4 := *x.UID
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(yy4))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("uid"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.UID == nil {
- r.EncodeNil()
- } else {
- yy6 := *x.UID
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(yy6))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Preconditions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Preconditions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "uid":
- if r.TryDecodeAsNil() {
- if x.UID != nil {
- x.UID = nil
- }
- } else {
- if x.UID == nil {
- x.UID = new(pkg1_types.UID)
- }
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(x.UID) {
- } else {
- *((*string)(x.UID)) = r.DecodeString()
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Preconditions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.UID != nil {
- x.UID = nil
- }
- } else {
- if x.UID == nil {
- x.UID = new(pkg1_types.UID)
- }
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else if z.HasExtensions() && z.DecExt(x.UID) {
- } else {
- *((*string)(x.UID)) = r.DecodeString()
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.GracePeriodSeconds != nil
- yyq2[1] = x.Preconditions != nil
- yyq2[2] = x.OrphanDependents != nil
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.GracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy4 := *x.GracePeriodSeconds
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeInt(int64(yy4))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("gracePeriodSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.GracePeriodSeconds == nil {
- r.EncodeNil()
- } else {
- yy6 := *x.GracePeriodSeconds
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeInt(int64(yy6))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Preconditions == nil {
- r.EncodeNil()
- } else {
- x.Preconditions.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("preconditions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Preconditions == nil {
- r.EncodeNil()
- } else {
- x.Preconditions.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.OrphanDependents == nil {
- r.EncodeNil()
- } else {
- yy12 := *x.OrphanDependents
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(yy12))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("orphanDependents"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.OrphanDependents == nil {
- r.EncodeNil()
- } else {
- yy14 := *x.OrphanDependents
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeBool(bool(yy14))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *DeleteOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "gracePeriodSeconds":
- if r.TryDecodeAsNil() {
- if x.GracePeriodSeconds != nil {
- x.GracePeriodSeconds = nil
- }
- } else {
- if x.GracePeriodSeconds == nil {
- x.GracePeriodSeconds = new(int64)
- }
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "preconditions":
- if r.TryDecodeAsNil() {
- if x.Preconditions != nil {
- x.Preconditions = nil
- }
- } else {
- if x.Preconditions == nil {
- x.Preconditions = new(Preconditions)
- }
- x.Preconditions.CodecDecodeSelf(d)
- }
- case "orphanDependents":
- if r.TryDecodeAsNil() {
- if x.OrphanDependents != nil {
- x.OrphanDependents = nil
- }
- } else {
- if x.OrphanDependents == nil {
- x.OrphanDependents = new(bool)
- }
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- *((*bool)(x.OrphanDependents)) = r.DecodeBool()
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.GracePeriodSeconds != nil {
- x.GracePeriodSeconds = nil
- }
- } else {
- if x.GracePeriodSeconds == nil {
- x.GracePeriodSeconds = new(int64)
- }
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Preconditions != nil {
- x.Preconditions = nil
- }
- } else {
- if x.Preconditions == nil {
- x.Preconditions = new(Preconditions)
- }
- x.Preconditions.CodecDecodeSelf(d)
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.OrphanDependents != nil {
- x.OrphanDependents = nil
- }
- } else {
- if x.OrphanDependents == nil {
- x.OrphanDependents = new(bool)
- }
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- *((*bool)(x.OrphanDependents)) = r.DecodeBool()
- }
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ExportOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeBool(bool(x.Export))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("export"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeBool(bool(x.Export))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.Exact))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("exact"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.Exact))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ExportOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ExportOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "export":
- if r.TryDecodeAsNil() {
- x.Export = false
- } else {
- x.Export = bool(r.DecodeBool())
- }
- case "exact":
- if r.TryDecodeAsNil() {
- x.Exact = false
- } else {
- x.Exact = bool(r.DecodeBool())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ExportOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Export = false
- } else {
- x.Export = bool(r.DecodeBool())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Exact = false
- } else {
- x.Exact = bool(r.DecodeBool())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [7]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.LabelSelector != ""
- yyq2[1] = x.FieldSelector != ""
- yyq2[2] = x.Watch != false
- yyq2[3] = x.ResourceVersion != ""
- yyq2[4] = x.TimeoutSeconds != nil
- yyq2[5] = x.Kind != ""
- yyq2[6] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(7)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("labelSelector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fieldSelector"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.Watch))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("watch"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.Watch))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resourceVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.TimeoutSeconds == nil {
- r.EncodeNil()
- } else {
- yy16 := *x.TimeoutSeconds
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeInt(int64(yy16))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TimeoutSeconds == nil {
- r.EncodeNil()
- } else {
- yy18 := *x.TimeoutSeconds
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeInt(int64(yy18))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym24 := z.EncBinary()
- _ = yym24
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ListOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ListOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "labelSelector":
- if r.TryDecodeAsNil() {
- x.LabelSelector = ""
- } else {
- x.LabelSelector = string(r.DecodeString())
- }
- case "fieldSelector":
- if r.TryDecodeAsNil() {
- x.FieldSelector = ""
- } else {
- x.FieldSelector = string(r.DecodeString())
- }
- case "watch":
- if r.TryDecodeAsNil() {
- x.Watch = false
- } else {
- x.Watch = bool(r.DecodeBool())
- }
- case "resourceVersion":
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- case "timeoutSeconds":
- if r.TryDecodeAsNil() {
- if x.TimeoutSeconds != nil {
- x.TimeoutSeconds = nil
- }
- } else {
- if x.TimeoutSeconds == nil {
- x.TimeoutSeconds = new(int64)
- }
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LabelSelector = ""
- } else {
- x.LabelSelector = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FieldSelector = ""
- } else {
- x.FieldSelector = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Watch = false
- } else {
- x.Watch = bool(r.DecodeBool())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TimeoutSeconds != nil {
- x.TimeoutSeconds = nil
- }
- } else {
- if x.TimeoutSeconds == nil {
- x.TimeoutSeconds = new(int64)
- }
- yym18 := z.DecBinary()
- _ = yym18
- if false {
- } else {
- *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [10]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Container != ""
- yyq2[1] = x.Follow != false
- yyq2[2] = x.Previous != false
- yyq2[3] = x.SinceSeconds != nil
- yyq2[4] = x.SinceTime != nil
- yyq2[5] = x.Timestamps != false
- yyq2[6] = x.TailLines != nil
- yyq2[7] = x.LimitBytes != nil
- yyq2[8] = x.Kind != ""
- yyq2[9] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(10)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("container"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.Follow))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("follow"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.Follow))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.Previous))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("previous"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.Previous))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.SinceSeconds == nil {
- r.EncodeNil()
- } else {
- yy13 := *x.SinceSeconds
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeInt(int64(yy13))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("sinceSeconds"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SinceSeconds == nil {
- r.EncodeNil()
- } else {
- yy15 := *x.SinceSeconds
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeInt(int64(yy15))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.SinceTime == nil {
- r.EncodeNil()
- } else {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else if z.HasExtensions() && z.EncExt(x.SinceTime) {
- } else if yym18 {
- z.EncBinaryMarshal(x.SinceTime)
- } else if !yym18 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.SinceTime)
- } else {
- z.EncFallback(x.SinceTime)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("sinceTime"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SinceTime == nil {
- r.EncodeNil()
- } else {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else if z.HasExtensions() && z.EncExt(x.SinceTime) {
- } else if yym19 {
- z.EncBinaryMarshal(x.SinceTime)
- } else if !yym19 && z.IsJSONHandle() {
- z.EncJSONMarshal(x.SinceTime)
- } else {
- z.EncFallback(x.SinceTime)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeBool(bool(x.Timestamps))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("timestamps"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeBool(bool(x.Timestamps))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- if x.TailLines == nil {
- r.EncodeNil()
- } else {
- yy24 := *x.TailLines
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeInt(int64(yy24))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tailLines"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.TailLines == nil {
- r.EncodeNil()
- } else {
- yy26 := *x.TailLines
- yym27 := z.EncBinary()
- _ = yym27
- if false {
- } else {
- r.EncodeInt(int64(yy26))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- if x.LimitBytes == nil {
- r.EncodeNil()
- } else {
- yy29 := *x.LimitBytes
- yym30 := z.EncBinary()
- _ = yym30
- if false {
- } else {
- r.EncodeInt(int64(yy29))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("limitBytes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.LimitBytes == nil {
- r.EncodeNil()
- } else {
- yy31 := *x.LimitBytes
- yym32 := z.EncBinary()
- _ = yym32
- if false {
- } else {
- r.EncodeInt(int64(yy31))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- yym34 := z.EncBinary()
- _ = yym34
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym35 := z.EncBinary()
- _ = yym35
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- yym37 := z.EncBinary()
- _ = yym37
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym38 := z.EncBinary()
- _ = yym38
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodLogOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "container":
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- case "follow":
- if r.TryDecodeAsNil() {
- x.Follow = false
- } else {
- x.Follow = bool(r.DecodeBool())
- }
- case "previous":
- if r.TryDecodeAsNil() {
- x.Previous = false
- } else {
- x.Previous = bool(r.DecodeBool())
- }
- case "sinceSeconds":
- if r.TryDecodeAsNil() {
- if x.SinceSeconds != nil {
- x.SinceSeconds = nil
- }
- } else {
- if x.SinceSeconds == nil {
- x.SinceSeconds = new(int64)
- }
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64))
- }
- }
- case "sinceTime":
- if r.TryDecodeAsNil() {
- if x.SinceTime != nil {
- x.SinceTime = nil
- }
- } else {
- if x.SinceTime == nil {
- x.SinceTime = new(pkg2_unversioned.Time)
- }
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else if z.HasExtensions() && z.DecExt(x.SinceTime) {
- } else if yym10 {
- z.DecBinaryUnmarshal(x.SinceTime)
- } else if !yym10 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.SinceTime)
- } else {
- z.DecFallback(x.SinceTime, false)
- }
- }
- case "timestamps":
- if r.TryDecodeAsNil() {
- x.Timestamps = false
- } else {
- x.Timestamps = bool(r.DecodeBool())
- }
- case "tailLines":
- if r.TryDecodeAsNil() {
- if x.TailLines != nil {
- x.TailLines = nil
- }
- } else {
- if x.TailLines == nil {
- x.TailLines = new(int64)
- }
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- *((*int64)(x.TailLines)) = int64(r.DecodeInt(64))
- }
- }
- case "limitBytes":
- if r.TryDecodeAsNil() {
- if x.LimitBytes != nil {
- x.LimitBytes = nil
- }
- } else {
- if x.LimitBytes == nil {
- x.LimitBytes = new(int64)
- }
- yym15 := z.DecBinary()
- _ = yym15
- if false {
- } else {
- *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64))
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj18 int
- var yyb18 bool
- var yyhl18 bool = l >= 0
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Follow = false
- } else {
- x.Follow = bool(r.DecodeBool())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Previous = false
- } else {
- x.Previous = bool(r.DecodeBool())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SinceSeconds != nil {
- x.SinceSeconds = nil
- }
- } else {
- if x.SinceSeconds == nil {
- x.SinceSeconds = new(int64)
- }
- yym23 := z.DecBinary()
- _ = yym23
- if false {
- } else {
- *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64))
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SinceTime != nil {
- x.SinceTime = nil
- }
- } else {
- if x.SinceTime == nil {
- x.SinceTime = new(pkg2_unversioned.Time)
- }
- yym25 := z.DecBinary()
- _ = yym25
- if false {
- } else if z.HasExtensions() && z.DecExt(x.SinceTime) {
- } else if yym25 {
- z.DecBinaryUnmarshal(x.SinceTime)
- } else if !yym25 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(x.SinceTime)
- } else {
- z.DecFallback(x.SinceTime, false)
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Timestamps = false
- } else {
- x.Timestamps = bool(r.DecodeBool())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.TailLines != nil {
- x.TailLines = nil
- }
- } else {
- if x.TailLines == nil {
- x.TailLines = new(int64)
- }
- yym28 := z.DecBinary()
- _ = yym28
- if false {
- } else {
- *((*int64)(x.TailLines)) = int64(r.DecodeInt(64))
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.LimitBytes != nil {
- x.LimitBytes = nil
- }
- } else {
- if x.LimitBytes == nil {
- x.LimitBytes = new(int64)
- }
- yym30 := z.DecBinary()
- _ = yym30
- if false {
- } else {
- *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64))
- }
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj18++
- if yyhl18 {
- yyb18 = yyj18 > l
- } else {
- yyb18 = r.CheckBreak()
- }
- if yyb18 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj18-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [7]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Stdin != false
- yyq2[1] = x.Stdout != false
- yyq2[2] = x.Stderr != false
- yyq2[3] = x.TTY != false
- yyq2[4] = x.Container != ""
- yyq2[5] = x.Kind != ""
- yyq2[6] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(7)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdin"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.Stdout))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdout"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.Stdout))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.Stderr))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stderr"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.Stderr))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tty"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("container"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodAttachOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodAttachOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "stdin":
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- case "stdout":
- if r.TryDecodeAsNil() {
- x.Stdout = false
- } else {
- x.Stdout = bool(r.DecodeBool())
- }
- case "stderr":
- if r.TryDecodeAsNil() {
- x.Stderr = false
- } else {
- x.Stderr = bool(r.DecodeBool())
- }
- case "tty":
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- case "container":
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stdout = false
- } else {
- x.Stdout = bool(r.DecodeBool())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stderr = false
- } else {
- x.Stderr = bool(r.DecodeBool())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [8]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Stdin != false
- yyq2[1] = x.Stdout != false
- yyq2[2] = x.Stderr != false
- yyq2[3] = x.TTY != false
- yyq2[4] = x.Container != ""
- yyq2[6] = x.Kind != ""
- yyq2[7] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(8)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdin"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeBool(bool(x.Stdin))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeBool(bool(x.Stdout))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stdout"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(x.Stdout))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(x.Stderr))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stderr"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeBool(bool(x.Stderr))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- } else {
- r.EncodeBool(false)
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("tty"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeBool(bool(x.TTY))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("container"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Container))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("command"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Command == nil {
- r.EncodeNil()
- } else {
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- z.F.EncSliceStringV(x.Command, false, e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym25 := z.EncBinary()
- _ = yym25
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodExecOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodExecOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "stdin":
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- case "stdout":
- if r.TryDecodeAsNil() {
- x.Stdout = false
- } else {
- x.Stdout = bool(r.DecodeBool())
- }
- case "stderr":
- if r.TryDecodeAsNil() {
- x.Stderr = false
- } else {
- x.Stderr = bool(r.DecodeBool())
- }
- case "tty":
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- case "container":
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- case "command":
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv9 := &x.Command
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- z.F.DecSliceStringX(yyv9, false, d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj13 int
- var yyb13 bool
- var yyhl13 bool = l >= 0
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stdin = false
- } else {
- x.Stdin = bool(r.DecodeBool())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stdout = false
- } else {
- x.Stdout = bool(r.DecodeBool())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Stderr = false
- } else {
- x.Stderr = bool(r.DecodeBool())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.TTY = false
- } else {
- x.TTY = bool(r.DecodeBool())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Container = ""
- } else {
- x.Container = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Command = nil
- } else {
- yyv19 := &x.Command
- yym20 := z.DecBinary()
- _ = yym20
- if false {
- } else {
- z.F.DecSliceStringX(yyv19, false, d)
- }
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj13++
- if yyhl13 {
- yyb13 = yyj13 > l
- } else {
- yyb13 = r.CheckBreak()
- }
- if yyb13 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj13-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *PodProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Path != ""
- yyq2[1] = x.Kind != ""
- yyq2[2] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *PodProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *PodProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *PodProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *NodeProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Path != ""
- yyq2[1] = x.Kind != ""
- yyq2[2] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *NodeProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *NodeProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *NodeProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ServiceProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Path != ""
- yyq2[1] = x.Kind != ""
- yyq2[2] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ServiceProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ServiceProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ServiceProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *OwnerReference) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[4] = x.Controller != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 4
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("uid"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.Controller == nil {
- r.EncodeNil()
- } else {
- yy16 := *x.Controller
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeBool(bool(yy16))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("controller"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Controller == nil {
- r.EncodeNil()
- } else {
- yy18 := *x.Controller
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeBool(bool(yy18))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *OwnerReference) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *OwnerReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "uid":
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- case "controller":
- if r.TryDecodeAsNil() {
- if x.Controller != nil {
- x.Controller = nil
- }
- } else {
- if x.Controller == nil {
- x.Controller = new(bool)
- }
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- *((*bool)(x.Controller)) = r.DecodeBool()
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *OwnerReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Controller != nil {
- x.Controller = nil
- }
- } else {
- if x.Controller == nil {
- x.Controller = new(bool)
- }
- yym16 := z.DecBinary()
- _ = yym16
- if false {
- } else {
- *((*bool)(x.Controller)) = r.DecodeBool()
- }
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [7]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Kind != ""
- yyq2[1] = x.Namespace != ""
- yyq2[2] = x.Name != ""
- yyq2[3] = x.UID != ""
- yyq2[4] = x.APIVersion != ""
- yyq2[5] = x.ResourceVersion != ""
- yyq2[6] = x.FieldPath != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(7)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Namespace))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("namespace"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Namespace))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("uid"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else if z.HasExtensions() && z.EncExt(x.UID) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.UID))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resourceVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fieldPath"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ObjectReference) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "namespace":
- if r.TryDecodeAsNil() {
- x.Namespace = ""
- } else {
- x.Namespace = string(r.DecodeString())
- }
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- case "uid":
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- case "resourceVersion":
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- case "fieldPath":
- if r.TryDecodeAsNil() {
- x.FieldPath = ""
- } else {
- x.FieldPath = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj11 int
- var yyb11 bool
- var yyhl11 bool = l >= 0
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Namespace = ""
- } else {
- x.Namespace = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.UID = ""
- } else {
- x.UID = pkg1_types.UID(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ResourceVersion = ""
- } else {
- x.ResourceVersion = string(r.DecodeString())
- }
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FieldPath = ""
- } else {
- x.FieldPath = string(r.DecodeString())
- }
- for {
- yyj11++
- if yyhl11 {
- yyb11 = yyj11 > l
- } else {
- yyb11 = r.CheckBreak()
- }
- if yyb11 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj11-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LocalObjectReference) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Name != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("name"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Name))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LocalObjectReference) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LocalObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "name":
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LocalObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj5 int
- var yyb5 bool
- var yyhl5 bool = l >= 0
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Name = ""
- } else {
- x.Name = string(r.DecodeString())
- }
- for {
- yyj5++
- if yyhl5 {
- yyb5 = yyj5 > l
- } else {
- yyb5 = r.CheckBreak()
- }
- if yyb5 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj5-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *SerializedReference) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = x.Kind != ""
- yyq2[2] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.Reference
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reference"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.Reference
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SerializedReference) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SerializedReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "reference":
- if r.TryDecodeAsNil() {
- x.Reference = ObjectReference{}
- } else {
- yyv4 := &x.Reference
- yyv4.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SerializedReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reference = ObjectReference{}
- } else {
- yyv8 := &x.Reference
- yyv8.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EventSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Component != ""
- yyq2[1] = x.Host != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Component))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("component"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Component))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Host))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("host"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Host))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EventSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EventSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "component":
- if r.TryDecodeAsNil() {
- x.Component = ""
- } else {
- x.Component = string(r.DecodeString())
- }
- case "host":
- if r.TryDecodeAsNil() {
- x.Host = ""
- } else {
- x.Host = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EventSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Component = ""
- } else {
- x.Component = string(r.DecodeString())
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Host = ""
- } else {
- x.Host = string(r.DecodeString())
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [11]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.Reason != ""
- yyq2[3] = x.Message != ""
- yyq2[4] = true
- yyq2[5] = true
- yyq2[6] = true
- yyq2[7] = x.Count != 0
- yyq2[8] = x.Type != ""
- yyq2[9] = x.Kind != ""
- yyq2[10] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(11)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy9 := &x.InvolvedObject
- yy9.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("involvedObject"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.InvolvedObject
- yy11.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("reason"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Reason))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yy20 := &x.Source
- yy20.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("source"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy22 := &x.Source
- yy22.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yy25 := &x.FirstTimestamp
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else if z.HasExtensions() && z.EncExt(yy25) {
- } else if yym26 {
- z.EncBinaryMarshal(yy25)
- } else if !yym26 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy25)
- } else {
- z.EncFallback(yy25)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("firstTimestamp"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy27 := &x.FirstTimestamp
- yym28 := z.EncBinary()
- _ = yym28
- if false {
- } else if z.HasExtensions() && z.EncExt(yy27) {
- } else if yym28 {
- z.EncBinaryMarshal(yy27)
- } else if !yym28 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy27)
- } else {
- z.EncFallback(yy27)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[6] {
- yy30 := &x.LastTimestamp
- yym31 := z.EncBinary()
- _ = yym31
- if false {
- } else if z.HasExtensions() && z.EncExt(yy30) {
- } else if yym31 {
- z.EncBinaryMarshal(yy30)
- } else if !yym31 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy30)
- } else {
- z.EncFallback(yy30)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[6] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("lastTimestamp"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy32 := &x.LastTimestamp
- yym33 := z.EncBinary()
- _ = yym33
- if false {
- } else if z.HasExtensions() && z.EncExt(yy32) {
- } else if yym33 {
- z.EncBinaryMarshal(yy32)
- } else if !yym33 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy32)
- } else {
- z.EncFallback(yy32)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[7] {
- yym35 := z.EncBinary()
- _ = yym35
- if false {
- } else {
- r.EncodeInt(int64(x.Count))
- }
- } else {
- r.EncodeInt(0)
- }
- } else {
- if yyq2[7] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("count"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym36 := z.EncBinary()
- _ = yym36
- if false {
- } else {
- r.EncodeInt(int64(x.Count))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[8] {
- yym38 := z.EncBinary()
- _ = yym38
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Type))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[8] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym39 := z.EncBinary()
- _ = yym39
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Type))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[9] {
- yym41 := z.EncBinary()
- _ = yym41
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[9] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym42 := z.EncBinary()
- _ = yym42
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[10] {
- yym44 := z.EncBinary()
- _ = yym44
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[10] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym45 := z.EncBinary()
- _ = yym45
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Event) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Event) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "involvedObject":
- if r.TryDecodeAsNil() {
- x.InvolvedObject = ObjectReference{}
- } else {
- yyv5 := &x.InvolvedObject
- yyv5.CodecDecodeSelf(d)
- }
- case "reason":
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- case "source":
- if r.TryDecodeAsNil() {
- x.Source = EventSource{}
- } else {
- yyv8 := &x.Source
- yyv8.CodecDecodeSelf(d)
- }
- case "firstTimestamp":
- if r.TryDecodeAsNil() {
- x.FirstTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv9 := &x.FirstTimestamp
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv9) {
- } else if yym10 {
- z.DecBinaryUnmarshal(yyv9)
- } else if !yym10 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv9)
- } else {
- z.DecFallback(yyv9, false)
- }
- }
- case "lastTimestamp":
- if r.TryDecodeAsNil() {
- x.LastTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv11 := &x.LastTimestamp
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else if yym12 {
- z.DecBinaryUnmarshal(yyv11)
- } else if !yym12 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv11)
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- case "count":
- if r.TryDecodeAsNil() {
- x.Count = 0
- } else {
- x.Count = int32(r.DecodeInt(32))
- }
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = string(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj17 int
- var yyb17 bool
- var yyhl17 bool = l >= 0
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv18 := &x.ObjectMeta
- yyv18.CodecDecodeSelf(d)
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.InvolvedObject = ObjectReference{}
- } else {
- yyv19 := &x.InvolvedObject
- yyv19.CodecDecodeSelf(d)
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Reason = ""
- } else {
- x.Reason = string(r.DecodeString())
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Source = EventSource{}
- } else {
- yyv22 := &x.Source
- yyv22.CodecDecodeSelf(d)
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.FirstTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv23 := &x.FirstTimestamp
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv23) {
- } else if yym24 {
- z.DecBinaryUnmarshal(yyv23)
- } else if !yym24 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv23)
- } else {
- z.DecFallback(yyv23, false)
- }
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.LastTimestamp = pkg2_unversioned.Time{}
- } else {
- yyv25 := &x.LastTimestamp
- yym26 := z.DecBinary()
- _ = yym26
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv25) {
- } else if yym26 {
- z.DecBinaryUnmarshal(yyv25)
- } else if !yym26 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv25)
- } else {
- z.DecFallback(yyv25, false)
- }
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Count = 0
- } else {
- x.Count = int32(r.DecodeInt(32))
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = string(r.DecodeString())
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj17++
- if yyhl17 {
- yyb17 = yyj17 > l
- } else {
- yyb17 = r.CheckBreak()
- }
- if yyb17 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj17-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *EventList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceEvent(([]Event)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceEvent(([]Event)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *EventList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *EventList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceEvent((*[]Event)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *EventList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceEvent((*[]Event)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *List) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceruntime_RawExtension(([]pkg5_runtime.RawExtension)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceruntime_RawExtension(([]pkg5_runtime.RawExtension)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *List) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *List) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *List) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x LimitType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *LimitType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Type != ""
- yyq2[1] = len(x.Max) != 0
- yyq2[2] = len(x.Min) != 0
- yyq2[3] = len(x.Default) != 0
- yyq2[4] = len(x.DefaultRequest) != 0
- yyq2[5] = len(x.MaxLimitRequestRatio) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- x.Type.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Max == nil {
- r.EncodeNil()
- } else {
- x.Max.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("max"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Max == nil {
- r.EncodeNil()
- } else {
- x.Max.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.Min == nil {
- r.EncodeNil()
- } else {
- x.Min.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("min"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Min == nil {
- r.EncodeNil()
- } else {
- x.Min.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.Default == nil {
- r.EncodeNil()
- } else {
- x.Default.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("default"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Default == nil {
- r.EncodeNil()
- } else {
- x.Default.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.DefaultRequest == nil {
- r.EncodeNil()
- } else {
- x.DefaultRequest.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("defaultRequest"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.DefaultRequest == nil {
- r.EncodeNil()
- } else {
- x.DefaultRequest.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.MaxLimitRequestRatio == nil {
- r.EncodeNil()
- } else {
- x.MaxLimitRequestRatio.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("maxLimitRequestRatio"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.MaxLimitRequestRatio == nil {
- r.EncodeNil()
- } else {
- x.MaxLimitRequestRatio.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LimitRangeItem) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LimitRangeItem) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = LimitType(r.DecodeString())
- }
- case "max":
- if r.TryDecodeAsNil() {
- x.Max = nil
- } else {
- yyv5 := &x.Max
- yyv5.CodecDecodeSelf(d)
- }
- case "min":
- if r.TryDecodeAsNil() {
- x.Min = nil
- } else {
- yyv6 := &x.Min
- yyv6.CodecDecodeSelf(d)
- }
- case "default":
- if r.TryDecodeAsNil() {
- x.Default = nil
- } else {
- yyv7 := &x.Default
- yyv7.CodecDecodeSelf(d)
- }
- case "defaultRequest":
- if r.TryDecodeAsNil() {
- x.DefaultRequest = nil
- } else {
- yyv8 := &x.DefaultRequest
- yyv8.CodecDecodeSelf(d)
- }
- case "maxLimitRequestRatio":
- if r.TryDecodeAsNil() {
- x.MaxLimitRequestRatio = nil
- } else {
- yyv9 := &x.MaxLimitRequestRatio
- yyv9.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = LimitType(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Max = nil
- } else {
- yyv12 := &x.Max
- yyv12.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Min = nil
- } else {
- yyv13 := &x.Min
- yyv13.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Default = nil
- } else {
- yyv14 := &x.Default
- yyv14.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.DefaultRequest = nil
- } else {
- yyv15 := &x.DefaultRequest
- yyv15.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.MaxLimitRequestRatio = nil
- } else {
- yyv16 := &x.MaxLimitRequestRatio
- yyv16.CodecDecodeSelf(d)
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LimitRangeSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Limits == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("limits"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Limits == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LimitRangeSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LimitRangeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "limits":
- if r.TryDecodeAsNil() {
- x.Limits = nil
- } else {
- yyv4 := &x.Limits
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LimitRangeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Limits = nil
- } else {
- yyv7 := &x.Limits
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LimitRange) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym17 := z.EncBinary()
- _ = yym17
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LimitRange) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LimitRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = LimitRangeSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LimitRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv9 := &x.ObjectMeta
- yyv9.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = LimitRangeSpec{}
- } else {
- yyv10 := &x.Spec
- yyv10.CodecDecodeSelf(d)
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *LimitRangeList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceLimitRange(([]LimitRange)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceLimitRange(([]LimitRange)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *LimitRangeList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *LimitRangeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceLimitRange((*[]LimitRange)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceLimitRange((*[]LimitRange)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ResourceQuotaScope) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Hard) != 0
- yyq2[1] = len(x.Scopes) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Hard == nil {
- r.EncodeNil()
- } else {
- x.Hard.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hard"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Hard == nil {
- r.EncodeNil()
- } else {
- x.Hard.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Scopes == nil {
- r.EncodeNil()
- } else {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("scopes"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Scopes == nil {
- r.EncodeNil()
- } else {
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceQuotaSpec) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceQuotaSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "hard":
- if r.TryDecodeAsNil() {
- x.Hard = nil
- } else {
- yyv4 := &x.Hard
- yyv4.CodecDecodeSelf(d)
- }
- case "scopes":
- if r.TryDecodeAsNil() {
- x.Scopes = nil
- } else {
- yyv5 := &x.Scopes
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv5), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Hard = nil
- } else {
- yyv8 := &x.Hard
- yyv8.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Scopes = nil
- } else {
- yyv9 := &x.Scopes
- yym10 := z.DecBinary()
- _ = yym10
- if false {
- } else {
- h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv9), d)
- }
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [2]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Hard) != 0
- yyq2[1] = len(x.Used) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(2)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Hard == nil {
- r.EncodeNil()
- } else {
- x.Hard.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("hard"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Hard == nil {
- r.EncodeNil()
- } else {
- x.Hard.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Used == nil {
- r.EncodeNil()
- } else {
- x.Used.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("used"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Used == nil {
- r.EncodeNil()
- } else {
- x.Used.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceQuotaStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceQuotaStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "hard":
- if r.TryDecodeAsNil() {
- x.Hard = nil
- } else {
- yyv4 := &x.Hard
- yyv4.CodecDecodeSelf(d)
- }
- case "used":
- if r.TryDecodeAsNil() {
- x.Used = nil
- } else {
- yyv5 := &x.Used
- yyv5.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceQuotaStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Hard = nil
- } else {
- yyv7 := &x.Hard
- yyv7.CodecDecodeSelf(d)
- }
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Used = nil
- } else {
- yyv8 := &x.Used
- yyv8.CodecDecodeSelf(d)
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ResourceQuota) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = true
- yyq2[2] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yy9 := &x.Spec
- yy9.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("spec"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy11 := &x.Spec
- yy11.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yy14 := &x.Status
- yy14.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy16 := &x.Status
- yy16.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym20 := z.EncBinary()
- _ = yym20
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceQuota) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceQuota) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "spec":
- if r.TryDecodeAsNil() {
- x.Spec = ResourceQuotaSpec{}
- } else {
- yyv5 := &x.Spec
- yyv5.CodecDecodeSelf(d)
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ResourceQuotaStatus{}
- } else {
- yyv6 := &x.Status
- yyv6.CodecDecodeSelf(d)
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Spec = ResourceQuotaSpec{}
- } else {
- yyv11 := &x.Spec
- yyv11.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ResourceQuotaStatus{}
- } else {
- yyv12 := &x.Status
- yyv12.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ResourceQuotaList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ResourceQuotaList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ResourceQuotaList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceResourceQuota((*[]ResourceQuota)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ResourceQuotaList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceResourceQuota((*[]ResourceQuota)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = len(x.Data) != 0
- yyq2[2] = len(x.StringData) != 0
- yyq2[3] = x.Type != ""
- yyq2[4] = x.Kind != ""
- yyq2[5] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("data"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.StringData == nil {
- r.EncodeNil()
- } else {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- z.F.EncMapStringStringV(x.StringData, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("stringData"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.StringData == nil {
- r.EncodeNil()
- } else {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- z.F.EncMapStringStringV(x.StringData, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- x.Type.CodecEncodeSelf(e)
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym22 := z.EncBinary()
- _ = yym22
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *Secret) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *Secret) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "data":
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv5 := &x.Data
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decMapstringSliceuint8((*map[string][]uint8)(yyv5), d)
- }
- }
- case "stringData":
- if r.TryDecodeAsNil() {
- x.StringData = nil
- } else {
- yyv7 := &x.StringData
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- z.F.DecMapStringStringX(yyv7, false, d)
- }
- }
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = SecretType(r.DecodeString())
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj12 int
- var yyb12 bool
- var yyhl12 bool = l >= 0
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv13 := &x.ObjectMeta
- yyv13.CodecDecodeSelf(d)
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv14 := &x.Data
- yym15 := z.DecBinary()
- _ = yym15
- if false {
- } else {
- h.decMapstringSliceuint8((*map[string][]uint8)(yyv14), d)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.StringData = nil
- } else {
- yyv16 := &x.StringData
- yym17 := z.DecBinary()
- _ = yym17
- if false {
- } else {
- z.F.DecMapStringStringX(yyv16, false, d)
- }
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = SecretType(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj12++
- if yyhl12 {
- yyb12 = yyj12 > l
- } else {
- yyb12 = r.CheckBreak()
- }
- if yyb12 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj12-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x SecretType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *SecretType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *SecretList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceSecret(([]Secret)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceSecret(([]Secret)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SecretList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SecretList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceSecret((*[]Secret)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SecretList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceSecret((*[]Secret)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = len(x.Data) != 0
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- z.F.EncMapStringStringV(x.Data, false, e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("data"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- z.F.EncMapStringStringV(x.Data, false, e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ConfigMap) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ConfigMap) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "data":
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv5 := &x.Data
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- z.F.DecMapStringStringX(yyv5, false, d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ConfigMap) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv11 := &x.Data
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- z.F.DecMapStringStringX(yyv11, false, d)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ConfigMapList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceConfigMap(([]ConfigMap)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceConfigMap(([]ConfigMap)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ConfigMapList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ConfigMapList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceConfigMap((*[]ConfigMap)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ConfigMapList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceConfigMap((*[]ConfigMap)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x ComponentConditionType) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x))
- }
-}
-
-func (x *ComponentConditionType) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- *((*string)(x)) = r.DecodeString()
- }
-}
-
-func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[2] = x.Message != ""
- yyq2[3] = x.Error != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Type.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Type.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- x.Status.CodecEncodeSelf(e)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("status"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- x.Status.CodecEncodeSelf(e)
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("message"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Message))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Error))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("error"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Error))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ComponentCondition) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ComponentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = ComponentConditionType(r.DecodeString())
- }
- case "status":
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- case "message":
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- case "error":
- if r.TryDecodeAsNil() {
- x.Error = ""
- } else {
- x.Error = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = ComponentConditionType(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Status = ""
- } else {
- x.Status = ConditionStatus(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Message = ""
- } else {
- x.Message = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Error = ""
- } else {
- x.Error = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[1] = len(x.Conditions) != 0
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("conditions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Conditions == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ComponentStatus) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ComponentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "conditions":
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv5 := &x.Conditions
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- h.decSliceComponentCondition((*[]ComponentCondition)(yyv5), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ComponentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj9 int
- var yyb9 bool
- var yyhl9 bool = l >= 0
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv10 := &x.ObjectMeta
- yyv10.CodecDecodeSelf(d)
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Conditions = nil
- } else {
- yyv11 := &x.Conditions
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else {
- h.decSliceComponentCondition((*[]ComponentCondition)(yyv11), d)
- }
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj9++
- if yyhl9 {
- yyb9 = yyj9 > l
- } else {
- yyb9 = r.CheckBreak()
- }
- if yyb9 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj9-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *ComponentStatusList) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[2] = x.Kind != ""
- yyq2[3] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ListMeta
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.EncExt(yy4) {
- } else {
- z.EncFallback(yy4)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ListMeta
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.EncExt(yy6) {
- } else {
- z.EncFallback(yy6)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e)
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *ComponentStatusList) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *ComponentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv4 := &x.ListMeta
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else {
- z.DecFallback(yyv4, false)
- }
- }
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv6 := &x.Items
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- h.decSliceComponentStatus((*[]ComponentStatus)(yyv6), d)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *ComponentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ListMeta = pkg2_unversioned.ListMeta{}
- } else {
- yyv11 := &x.ListMeta
- yym12 := z.DecBinary()
- _ = yym12
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv11) {
- } else {
- z.DecFallback(yyv11, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv13 := &x.Items
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- h.decSliceComponentStatus((*[]ComponentStatus)(yyv13), d)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *DownwardAPIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [1]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = len(x.Items) != 0
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(1)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e)
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("items"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Items == nil {
- r.EncodeNil()
- } else {
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e)
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *DownwardAPIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *DownwardAPIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "items":
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv4 := &x.Items
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else {
- h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4), d)
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *DownwardAPIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj6 int
- var yyb6 bool
- var yyhl6 bool = l >= 0
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Items = nil
- } else {
- yyv7 := &x.Items
- yym8 := z.DecBinary()
- _ = yym8
- if false {
- } else {
- h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv7), d)
- }
- }
- for {
- yyj6++
- if yyhl6 {
- yyb6 = yyj6 > l
- } else {
- yyb6 = r.CheckBreak()
- }
- if yyb6 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj6-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [3]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[1] = x.FieldRef != nil
- yyq2[2] = x.ResourceFieldRef != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(3)
- } else {
- yynn2 = 1
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("path"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Path))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.FieldRef == nil {
- r.EncodeNil()
- } else {
- x.FieldRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("fieldRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.FieldRef == nil {
- r.EncodeNil()
- } else {
- x.FieldRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.ResourceFieldRef == nil {
- r.EncodeNil()
- } else {
- x.ResourceFieldRef.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("resourceFieldRef"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ResourceFieldRef == nil {
- r.EncodeNil()
- } else {
- x.ResourceFieldRef.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *DownwardAPIVolumeFile) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *DownwardAPIVolumeFile) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "path":
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- case "fieldRef":
- if r.TryDecodeAsNil() {
- if x.FieldRef != nil {
- x.FieldRef = nil
- }
- } else {
- if x.FieldRef == nil {
- x.FieldRef = new(ObjectFieldSelector)
- }
- x.FieldRef.CodecDecodeSelf(d)
- }
- case "resourceFieldRef":
- if r.TryDecodeAsNil() {
- if x.ResourceFieldRef != nil {
- x.ResourceFieldRef = nil
- }
- } else {
- if x.ResourceFieldRef == nil {
- x.ResourceFieldRef = new(ResourceFieldSelector)
- }
- x.ResourceFieldRef.CodecDecodeSelf(d)
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *DownwardAPIVolumeFile) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj7 int
- var yyb7 bool
- var yyhl7 bool = l >= 0
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Path = ""
- } else {
- x.Path = string(r.DecodeString())
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.FieldRef != nil {
- x.FieldRef = nil
- }
- } else {
- if x.FieldRef == nil {
- x.FieldRef = new(ObjectFieldSelector)
- }
- x.FieldRef.CodecDecodeSelf(d)
- }
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ResourceFieldRef != nil {
- x.ResourceFieldRef = nil
- }
- } else {
- if x.ResourceFieldRef == nil {
- x.ResourceFieldRef = new(ResourceFieldSelector)
- }
- x.ResourceFieldRef.CodecDecodeSelf(d)
- }
- for {
- yyj7++
- if yyhl7 {
- yyb7 = yyj7 > l
- } else {
- yyb7 = r.CheckBreak()
- }
- if yyb7 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj7-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [6]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.Capabilities != nil
- yyq2[1] = x.Privileged != nil
- yyq2[2] = x.SELinuxOptions != nil
- yyq2[3] = x.RunAsUser != nil
- yyq2[4] = x.RunAsNonRoot != nil
- yyq2[5] = x.ReadOnlyRootFilesystem != nil
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(6)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- if x.Capabilities == nil {
- r.EncodeNil()
- } else {
- x.Capabilities.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("capabilities"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Capabilities == nil {
- r.EncodeNil()
- } else {
- x.Capabilities.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- if x.Privileged == nil {
- r.EncodeNil()
- } else {
- yy7 := *x.Privileged
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeBool(bool(yy7))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("privileged"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Privileged == nil {
- r.EncodeNil()
- } else {
- yy9 := *x.Privileged
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeBool(bool(yy9))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- if x.SELinuxOptions == nil {
- r.EncodeNil()
- } else {
- x.SELinuxOptions.CodecEncodeSelf(e)
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("seLinuxOptions"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.SELinuxOptions == nil {
- r.EncodeNil()
- } else {
- x.SELinuxOptions.CodecEncodeSelf(e)
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- if x.RunAsUser == nil {
- r.EncodeNil()
- } else {
- yy15 := *x.RunAsUser
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeInt(int64(yy15))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("runAsUser"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RunAsUser == nil {
- r.EncodeNil()
- } else {
- yy17 := *x.RunAsUser
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeInt(int64(yy17))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- if x.RunAsNonRoot == nil {
- r.EncodeNil()
- } else {
- yy20 := *x.RunAsNonRoot
- yym21 := z.EncBinary()
- _ = yym21
- if false {
- } else {
- r.EncodeBool(bool(yy20))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.RunAsNonRoot == nil {
- r.EncodeNil()
- } else {
- yy22 := *x.RunAsNonRoot
- yym23 := z.EncBinary()
- _ = yym23
- if false {
- } else {
- r.EncodeBool(bool(yy22))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[5] {
- if x.ReadOnlyRootFilesystem == nil {
- r.EncodeNil()
- } else {
- yy25 := *x.ReadOnlyRootFilesystem
- yym26 := z.EncBinary()
- _ = yym26
- if false {
- } else {
- r.EncodeBool(bool(yy25))
- }
- }
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[5] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.ReadOnlyRootFilesystem == nil {
- r.EncodeNil()
- } else {
- yy27 := *x.ReadOnlyRootFilesystem
- yym28 := z.EncBinary()
- _ = yym28
- if false {
- } else {
- r.EncodeBool(bool(yy27))
- }
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SecurityContext) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "capabilities":
- if r.TryDecodeAsNil() {
- if x.Capabilities != nil {
- x.Capabilities = nil
- }
- } else {
- if x.Capabilities == nil {
- x.Capabilities = new(Capabilities)
- }
- x.Capabilities.CodecDecodeSelf(d)
- }
- case "privileged":
- if r.TryDecodeAsNil() {
- if x.Privileged != nil {
- x.Privileged = nil
- }
- } else {
- if x.Privileged == nil {
- x.Privileged = new(bool)
- }
- yym6 := z.DecBinary()
- _ = yym6
- if false {
- } else {
- *((*bool)(x.Privileged)) = r.DecodeBool()
- }
- }
- case "seLinuxOptions":
- if r.TryDecodeAsNil() {
- if x.SELinuxOptions != nil {
- x.SELinuxOptions = nil
- }
- } else {
- if x.SELinuxOptions == nil {
- x.SELinuxOptions = new(SELinuxOptions)
- }
- x.SELinuxOptions.CodecDecodeSelf(d)
- }
- case "runAsUser":
- if r.TryDecodeAsNil() {
- if x.RunAsUser != nil {
- x.RunAsUser = nil
- }
- } else {
- if x.RunAsUser == nil {
- x.RunAsUser = new(int64)
- }
- yym9 := z.DecBinary()
- _ = yym9
- if false {
- } else {
- *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64))
- }
- }
- case "runAsNonRoot":
- if r.TryDecodeAsNil() {
- if x.RunAsNonRoot != nil {
- x.RunAsNonRoot = nil
- }
- } else {
- if x.RunAsNonRoot == nil {
- x.RunAsNonRoot = new(bool)
- }
- yym11 := z.DecBinary()
- _ = yym11
- if false {
- } else {
- *((*bool)(x.RunAsNonRoot)) = r.DecodeBool()
- }
- }
- case "readOnlyRootFilesystem":
- if r.TryDecodeAsNil() {
- if x.ReadOnlyRootFilesystem != nil {
- x.ReadOnlyRootFilesystem = nil
- }
- } else {
- if x.ReadOnlyRootFilesystem == nil {
- x.ReadOnlyRootFilesystem = new(bool)
- }
- yym13 := z.DecBinary()
- _ = yym13
- if false {
- } else {
- *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool()
- }
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj14 int
- var yyb14 bool
- var yyhl14 bool = l >= 0
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Capabilities != nil {
- x.Capabilities = nil
- }
- } else {
- if x.Capabilities == nil {
- x.Capabilities = new(Capabilities)
- }
- x.Capabilities.CodecDecodeSelf(d)
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.Privileged != nil {
- x.Privileged = nil
- }
- } else {
- if x.Privileged == nil {
- x.Privileged = new(bool)
- }
- yym17 := z.DecBinary()
- _ = yym17
- if false {
- } else {
- *((*bool)(x.Privileged)) = r.DecodeBool()
- }
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.SELinuxOptions != nil {
- x.SELinuxOptions = nil
- }
- } else {
- if x.SELinuxOptions == nil {
- x.SELinuxOptions = new(SELinuxOptions)
- }
- x.SELinuxOptions.CodecDecodeSelf(d)
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RunAsUser != nil {
- x.RunAsUser = nil
- }
- } else {
- if x.RunAsUser == nil {
- x.RunAsUser = new(int64)
- }
- yym20 := z.DecBinary()
- _ = yym20
- if false {
- } else {
- *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64))
- }
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.RunAsNonRoot != nil {
- x.RunAsNonRoot = nil
- }
- } else {
- if x.RunAsNonRoot == nil {
- x.RunAsNonRoot = new(bool)
- }
- yym22 := z.DecBinary()
- _ = yym22
- if false {
- } else {
- *((*bool)(x.RunAsNonRoot)) = r.DecodeBool()
- }
- }
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- if x.ReadOnlyRootFilesystem != nil {
- x.ReadOnlyRootFilesystem = nil
- }
- } else {
- if x.ReadOnlyRootFilesystem == nil {
- x.ReadOnlyRootFilesystem = new(bool)
- }
- yym24 := z.DecBinary()
- _ = yym24
- if false {
- } else {
- *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool()
- }
- }
- for {
- yyj14++
- if yyhl14 {
- yyb14 = yyj14 > l
- } else {
- yyb14 = r.CheckBreak()
- }
- if yyb14 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj14-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [4]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = x.User != ""
- yyq2[1] = x.Role != ""
- yyq2[2] = x.Type != ""
- yyq2[3] = x.Level != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(4)
- } else {
- yynn2 = 0
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.User))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("user"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym5 := z.EncBinary()
- _ = yym5
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.User))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[1] {
- yym7 := z.EncBinary()
- _ = yym7
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Role))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[1] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("role"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym8 := z.EncBinary()
- _ = yym8
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Role))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[2] {
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Type))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[2] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("type"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym11 := z.EncBinary()
- _ = yym11
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Type))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Level))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("level"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym14 := z.EncBinary()
- _ = yym14
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Level))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *SELinuxOptions) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *SELinuxOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "user":
- if r.TryDecodeAsNil() {
- x.User = ""
- } else {
- x.User = string(r.DecodeString())
- }
- case "role":
- if r.TryDecodeAsNil() {
- x.Role = ""
- } else {
- x.Role = string(r.DecodeString())
- }
- case "type":
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = string(r.DecodeString())
- }
- case "level":
- if r.TryDecodeAsNil() {
- x.Level = ""
- } else {
- x.Level = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj8 int
- var yyb8 bool
- var yyhl8 bool = l >= 0
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.User = ""
- } else {
- x.User = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Role = ""
- } else {
- x.Role = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Type = ""
- } else {
- x.Type = string(r.DecodeString())
- }
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Level = ""
- } else {
- x.Level = string(r.DecodeString())
- }
- for {
- yyj8++
- if yyhl8 {
- yyb8 = yyj8 > l
- } else {
- yyb8 = r.CheckBreak()
- }
- if yyb8 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj8-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- if x == nil {
- r.EncodeNil()
- } else {
- yym1 := z.EncBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.EncExt(x) {
- } else {
- yysep2 := !z.EncBinary()
- yy2arr2 := z.EncBasicHandle().StructToArray
- var yyq2 [5]bool
- _, _, _ = yysep2, yyq2, yy2arr2
- const yyr2 bool = false
- yyq2[0] = true
- yyq2[3] = x.Kind != ""
- yyq2[4] = x.APIVersion != ""
- var yynn2 int
- if yyr2 || yy2arr2 {
- r.EncodeArrayStart(5)
- } else {
- yynn2 = 2
- for _, b := range yyq2 {
- if b {
- yynn2++
- }
- }
- r.EncodeMapStart(yynn2)
- yynn2 = 0
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[0] {
- yy4 := &x.ObjectMeta
- yy4.CodecEncodeSelf(e)
- } else {
- r.EncodeNil()
- }
- } else {
- if yyq2[0] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("metadata"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy6 := &x.ObjectMeta
- yy6.CodecEncodeSelf(e)
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym9 := z.EncBinary()
- _ = yym9
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Range))
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("range"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym10 := z.EncBinary()
- _ = yym10
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Range))
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym12 := z.EncBinary()
- _ = yym12
- if false {
- } else {
- r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data))
- }
- }
- } else {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("data"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if x.Data == nil {
- r.EncodeNil()
- } else {
- yym13 := z.EncBinary()
- _ = yym13
- if false {
- } else {
- r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[3] {
- yym15 := z.EncBinary()
- _ = yym15
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[3] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("kind"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym16 := z.EncBinary()
- _ = yym16
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.Kind))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- if yyq2[4] {
- yym18 := z.EncBinary()
- _ = yym18
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- } else {
- r.EncodeString(codecSelferC_UTF81234, "")
- }
- } else {
- if yyq2[4] {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- r.EncodeString(codecSelferC_UTF81234, string("apiVersion"))
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yym19 := z.EncBinary()
- _ = yym19
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion))
- }
- }
- }
- if yyr2 || yy2arr2 {
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
- }
- }
- }
-}
-
-func (x *RangeAllocation) CodecDecodeSelf(d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- yym1 := z.DecBinary()
- _ = yym1
- if false {
- } else if z.HasExtensions() && z.DecExt(x) {
- } else {
- yyct2 := r.ContainerType()
- if yyct2 == codecSelferValueTypeMap1234 {
- yyl2 := r.ReadMapStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
- } else {
- x.codecDecodeSelfFromMap(yyl2, d)
- }
- } else if yyct2 == codecSelferValueTypeArray1234 {
- yyl2 := r.ReadArrayStart()
- if yyl2 == 0 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- } else {
- x.codecDecodeSelfFromArray(yyl2, d)
- }
- } else {
- panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234)
- }
- }
-}
-
-func (x *RangeAllocation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yys3Slc = z.DecScratchBuffer() // default slice to decode into
- _ = yys3Slc
- var yyhl3 bool = l >= 0
- for yyj3 := 0; ; yyj3++ {
- if yyhl3 {
- if yyj3 >= l {
- break
- }
- } else {
- if r.CheckBreak() {
- break
- }
- }
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- yys3Slc = r.DecodeBytes(yys3Slc, true, true)
- yys3 := string(yys3Slc)
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- switch yys3 {
- case "metadata":
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv4 := &x.ObjectMeta
- yyv4.CodecDecodeSelf(d)
- }
- case "range":
- if r.TryDecodeAsNil() {
- x.Range = ""
- } else {
- x.Range = string(r.DecodeString())
- }
- case "data":
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv6 := &x.Data
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false)
- }
- }
- case "kind":
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- case "apiVersion":
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- default:
- z.DecStructFieldNotFound(-1, yys3)
- } // end switch yys3
- } // end for yyj3
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
- var yyj10 int
- var yyb10 bool
- var yyhl10 bool = l >= 0
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.ObjectMeta = ObjectMeta{}
- } else {
- yyv11 := &x.ObjectMeta
- yyv11.CodecDecodeSelf(d)
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Range = ""
- } else {
- x.Range = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Data = nil
- } else {
- yyv13 := &x.Data
- yym14 := z.DecBinary()
- _ = yym14
- if false {
- } else {
- *yyv13 = r.DecodeBytes(*(*[]byte)(yyv13), false, false)
- }
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.Kind = ""
- } else {
- x.Kind = string(r.DecodeString())
- }
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
- return
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- if r.TryDecodeAsNil() {
- x.APIVersion = ""
- } else {
- x.APIVersion = string(r.DecodeString())
- }
- for {
- yyj10++
- if yyhl10 {
- yyb10 = yyj10 > l
- } else {
- yyb10 = r.CheckBreak()
- }
- if yyb10 {
- break
- }
- z.DecSendContainerState(codecSelfer_containerArrayElem1234)
- z.DecStructFieldNotFound(yyj10-1, "")
- }
- z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) encSliceOwnerReference(v []OwnerReference, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceOwnerReference(v *[]OwnerReference, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []OwnerReference{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]OwnerReference, yyrl1)
- }
- } else {
- yyv1 = make([]OwnerReference, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = OwnerReference{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, OwnerReference{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = OwnerReference{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, OwnerReference{}) // var yyz1 OwnerReference
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = OwnerReference{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []OwnerReference{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePersistentVolumeAccessMode(v []PersistentVolumeAccessMode, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yyv1.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePersistentVolumeAccessMode(v *[]PersistentVolumeAccessMode, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PersistentVolumeAccessMode{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PersistentVolumeAccessMode, yyrl1)
- }
- } else {
- yyv1 = make([]PersistentVolumeAccessMode, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = PersistentVolumeAccessMode(r.DecodeString())
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, "")
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = PersistentVolumeAccessMode(r.DecodeString())
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, "") // var yyz1 PersistentVolumeAccessMode
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = PersistentVolumeAccessMode(r.DecodeString())
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PersistentVolumeAccessMode{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePersistentVolume(v []PersistentVolume, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePersistentVolume(v *[]PersistentVolume, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PersistentVolume{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 456)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PersistentVolume, yyrl1)
- }
- } else {
- yyv1 = make([]PersistentVolume, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolume{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PersistentVolume{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolume{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PersistentVolume{}) // var yyz1 PersistentVolume
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolume{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PersistentVolume{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePersistentVolumeClaim(v []PersistentVolumeClaim, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePersistentVolumeClaim(v *[]PersistentVolumeClaim, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PersistentVolumeClaim{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 352)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PersistentVolumeClaim, yyrl1)
- }
- } else {
- yyv1 = make([]PersistentVolumeClaim, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolumeClaim{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PersistentVolumeClaim{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolumeClaim{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PersistentVolumeClaim{}) // var yyz1 PersistentVolumeClaim
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PersistentVolumeClaim{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PersistentVolumeClaim{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceKeyToPath(v []KeyToPath, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceKeyToPath(v *[]KeyToPath, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []KeyToPath{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]KeyToPath, yyrl1)
- }
- } else {
- yyv1 = make([]KeyToPath, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = KeyToPath{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, KeyToPath{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = KeyToPath{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, KeyToPath{}) // var yyz1 KeyToPath
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = KeyToPath{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []KeyToPath{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceHTTPHeader(v []HTTPHeader, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceHTTPHeader(v *[]HTTPHeader, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []HTTPHeader{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]HTTPHeader, yyrl1)
- }
- } else {
- yyv1 = make([]HTTPHeader, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = HTTPHeader{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, HTTPHeader{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = HTTPHeader{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, HTTPHeader{}) // var yyz1 HTTPHeader
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = HTTPHeader{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []HTTPHeader{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceCapability(v []Capability, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yyv1.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceCapability(v *[]Capability, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Capability{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Capability, yyrl1)
- }
- } else {
- yyv1 = make([]Capability, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = Capability(r.DecodeString())
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, "")
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = Capability(r.DecodeString())
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, "") // var yyz1 Capability
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = Capability(r.DecodeString())
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Capability{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceContainerPort(v []ContainerPort, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceContainerPort(v *[]ContainerPort, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ContainerPort{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ContainerPort, yyrl1)
- }
- } else {
- yyv1 = make([]ContainerPort, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerPort{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ContainerPort{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerPort{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ContainerPort{}) // var yyz1 ContainerPort
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerPort{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ContainerPort{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEnvVar(v []EnvVar, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEnvVar(v *[]EnvVar, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []EnvVar{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]EnvVar, yyrl1)
- }
- } else {
- yyv1 = make([]EnvVar, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EnvVar{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, EnvVar{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EnvVar{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, EnvVar{}) // var yyz1 EnvVar
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EnvVar{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []EnvVar{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceVolumeMount(v []VolumeMount, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceVolumeMount(v *[]VolumeMount, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []VolumeMount{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]VolumeMount, yyrl1)
- }
- } else {
- yyv1 = make([]VolumeMount, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = VolumeMount{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, VolumeMount{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = VolumeMount{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, VolumeMount{}) // var yyz1 VolumeMount
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = VolumeMount{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []VolumeMount{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceNodeSelectorTerm(v []NodeSelectorTerm, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNodeSelectorTerm(v *[]NodeSelectorTerm, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []NodeSelectorTerm{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]NodeSelectorTerm, yyrl1)
- }
- } else {
- yyv1 = make([]NodeSelectorTerm, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorTerm{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, NodeSelectorTerm{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorTerm{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, NodeSelectorTerm{}) // var yyz1 NodeSelectorTerm
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorTerm{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []NodeSelectorTerm{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceNodeSelectorRequirement(v []NodeSelectorRequirement, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNodeSelectorRequirement(v *[]NodeSelectorRequirement, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []NodeSelectorRequirement{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]NodeSelectorRequirement, yyrl1)
- }
- } else {
- yyv1 = make([]NodeSelectorRequirement, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorRequirement{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, NodeSelectorRequirement{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorRequirement{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, NodeSelectorRequirement{}) // var yyz1 NodeSelectorRequirement
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeSelectorRequirement{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []NodeSelectorRequirement{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePodAffinityTerm(v []PodAffinityTerm, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePodAffinityTerm(v *[]PodAffinityTerm, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PodAffinityTerm{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PodAffinityTerm, yyrl1)
- }
- } else {
- yyv1 = make([]PodAffinityTerm, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodAffinityTerm{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PodAffinityTerm{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodAffinityTerm{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PodAffinityTerm{}) // var yyz1 PodAffinityTerm
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodAffinityTerm{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PodAffinityTerm{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceWeightedPodAffinityTerm(v []WeightedPodAffinityTerm, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceWeightedPodAffinityTerm(v *[]WeightedPodAffinityTerm, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []WeightedPodAffinityTerm{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]WeightedPodAffinityTerm, yyrl1)
- }
- } else {
- yyv1 = make([]WeightedPodAffinityTerm, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = WeightedPodAffinityTerm{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, WeightedPodAffinityTerm{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = WeightedPodAffinityTerm{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, WeightedPodAffinityTerm{}) // var yyz1 WeightedPodAffinityTerm
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = WeightedPodAffinityTerm{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []WeightedPodAffinityTerm{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePreferredSchedulingTerm(v []PreferredSchedulingTerm, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePreferredSchedulingTerm(v *[]PreferredSchedulingTerm, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PreferredSchedulingTerm{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PreferredSchedulingTerm, yyrl1)
- }
- } else {
- yyv1 = make([]PreferredSchedulingTerm, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PreferredSchedulingTerm{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PreferredSchedulingTerm{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PreferredSchedulingTerm{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PreferredSchedulingTerm{}) // var yyz1 PreferredSchedulingTerm
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PreferredSchedulingTerm{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PreferredSchedulingTerm{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceVolume(v []Volume, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceVolume(v *[]Volume, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Volume{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 176)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Volume, yyrl1)
- }
- } else {
- yyv1 = make([]Volume, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Volume{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Volume{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Volume{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Volume{}) // var yyz1 Volume
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Volume{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Volume{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceContainer(v []Container, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceContainer(v *[]Container, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Container{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 256)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Container, yyrl1)
- }
- } else {
- yyv1 = make([]Container, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Container{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Container{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Container{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Container{}) // var yyz1 Container
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Container{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Container{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceLocalObjectReference(v []LocalObjectReference, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceLocalObjectReference(v *[]LocalObjectReference, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []LocalObjectReference{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]LocalObjectReference, yyrl1)
- }
- } else {
- yyv1 = make([]LocalObjectReference, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LocalObjectReference{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, LocalObjectReference{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LocalObjectReference{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, LocalObjectReference{}) // var yyz1 LocalObjectReference
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LocalObjectReference{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []LocalObjectReference{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePodCondition(v []PodCondition, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePodCondition(v *[]PodCondition, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PodCondition{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PodCondition, yyrl1)
- }
- } else {
- yyv1 = make([]PodCondition, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodCondition{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PodCondition{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodCondition{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PodCondition{}) // var yyz1 PodCondition
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodCondition{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PodCondition{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceContainerStatus(v []ContainerStatus, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceContainerStatus(v *[]ContainerStatus, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ContainerStatus{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 120)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ContainerStatus, yyrl1)
- }
- } else {
- yyv1 = make([]ContainerStatus, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerStatus{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ContainerStatus{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerStatus{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ContainerStatus{}) // var yyz1 ContainerStatus
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerStatus{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ContainerStatus{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePod(v []Pod, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePod(v *[]Pod, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Pod{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 648)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Pod, yyrl1)
- }
- } else {
- yyv1 = make([]Pod, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Pod{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Pod{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Pod{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Pod{}) // var yyz1 Pod
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Pod{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Pod{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSlicePodTemplate(v []PodTemplate, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSlicePodTemplate(v *[]PodTemplate, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []PodTemplate{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 696)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]PodTemplate, yyrl1)
- }
- } else {
- yyv1 = make([]PodTemplate, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodTemplate{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, PodTemplate{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodTemplate{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, PodTemplate{}) // var yyz1 PodTemplate
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = PodTemplate{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []PodTemplate{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceReplicationController(v []ReplicationController, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceReplicationController(v *[]ReplicationController, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ReplicationController{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 280)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ReplicationController, yyrl1)
- }
- } else {
- yyv1 = make([]ReplicationController, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ReplicationController{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ReplicationController{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ReplicationController{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ReplicationController{}) // var yyz1 ReplicationController
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ReplicationController{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ReplicationController{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceLoadBalancerIngress(v []LoadBalancerIngress, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceLoadBalancerIngress(v *[]LoadBalancerIngress, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []LoadBalancerIngress{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]LoadBalancerIngress, yyrl1)
- }
- } else {
- yyv1 = make([]LoadBalancerIngress, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LoadBalancerIngress{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, LoadBalancerIngress{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LoadBalancerIngress{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, LoadBalancerIngress{}) // var yyz1 LoadBalancerIngress
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LoadBalancerIngress{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []LoadBalancerIngress{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceServicePort(v []ServicePort, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceServicePort(v *[]ServicePort, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ServicePort{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 80)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ServicePort, yyrl1)
- }
- } else {
- yyv1 = make([]ServicePort, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServicePort{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ServicePort{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServicePort{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ServicePort{}) // var yyz1 ServicePort
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServicePort{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ServicePort{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceService(v []Service, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceService(v *[]Service, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Service{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 432)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Service, yyrl1)
- }
- } else {
- yyv1 = make([]Service, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Service{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Service{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Service{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Service{}) // var yyz1 Service
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Service{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Service{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceObjectReference(v []ObjectReference, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceObjectReference(v *[]ObjectReference, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ObjectReference{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ObjectReference, yyrl1)
- }
- } else {
- yyv1 = make([]ObjectReference, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ObjectReference{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ObjectReference{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ObjectReference{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ObjectReference{}) // var yyz1 ObjectReference
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ObjectReference{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ObjectReference{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceServiceAccount(v []ServiceAccount, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceServiceAccount(v *[]ServiceAccount, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ServiceAccount{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ServiceAccount, yyrl1)
- }
- } else {
- yyv1 = make([]ServiceAccount, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServiceAccount{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ServiceAccount{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServiceAccount{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ServiceAccount{}) // var yyz1 ServiceAccount
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ServiceAccount{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ServiceAccount{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEndpointSubset(v []EndpointSubset, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEndpointSubset(v *[]EndpointSubset, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []EndpointSubset{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]EndpointSubset, yyrl1)
- }
- } else {
- yyv1 = make([]EndpointSubset, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointSubset{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, EndpointSubset{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointSubset{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, EndpointSubset{}) // var yyz1 EndpointSubset
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointSubset{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []EndpointSubset{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEndpointAddress(v []EndpointAddress, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEndpointAddress(v *[]EndpointAddress, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []EndpointAddress{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]EndpointAddress, yyrl1)
- }
- } else {
- yyv1 = make([]EndpointAddress, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointAddress{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, EndpointAddress{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointAddress{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, EndpointAddress{}) // var yyz1 EndpointAddress
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointAddress{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []EndpointAddress{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEndpointPort(v []EndpointPort, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEndpointPort(v *[]EndpointPort, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []EndpointPort{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]EndpointPort, yyrl1)
- }
- } else {
- yyv1 = make([]EndpointPort, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointPort{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, EndpointPort{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointPort{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, EndpointPort{}) // var yyz1 EndpointPort
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = EndpointPort{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []EndpointPort{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEndpoints(v []Endpoints, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEndpoints(v *[]Endpoints, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Endpoints{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 264)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Endpoints, yyrl1)
- }
- } else {
- yyv1 = make([]Endpoints, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Endpoints{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Endpoints{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Endpoints{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Endpoints{}) // var yyz1 Endpoints
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Endpoints{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Endpoints{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceNodeCondition(v []NodeCondition, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNodeCondition(v *[]NodeCondition, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []NodeCondition{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]NodeCondition, yyrl1)
- }
- } else {
- yyv1 = make([]NodeCondition, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeCondition{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, NodeCondition{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeCondition{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, NodeCondition{}) // var yyz1 NodeCondition
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeCondition{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []NodeCondition{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceNodeAddress(v []NodeAddress, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNodeAddress(v *[]NodeAddress, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []NodeAddress{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]NodeAddress, yyrl1)
- }
- } else {
- yyv1 = make([]NodeAddress, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeAddress{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, NodeAddress{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeAddress{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, NodeAddress{}) // var yyz1 NodeAddress
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = NodeAddress{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []NodeAddress{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceContainerImage(v []ContainerImage, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceContainerImage(v *[]ContainerImage, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ContainerImage{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ContainerImage, yyrl1)
- }
- } else {
- yyv1 = make([]ContainerImage, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerImage{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ContainerImage{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerImage{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ContainerImage{}) // var yyz1 ContainerImage
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ContainerImage{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ContainerImage{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceUniqueVolumeName(v []UniqueVolumeName, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yyv1.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceUniqueVolumeName(v *[]UniqueVolumeName, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []UniqueVolumeName{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]UniqueVolumeName, yyrl1)
- }
- } else {
- yyv1 = make([]UniqueVolumeName, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = UniqueVolumeName(r.DecodeString())
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, "")
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = UniqueVolumeName(r.DecodeString())
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, "") // var yyz1 UniqueVolumeName
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = UniqueVolumeName(r.DecodeString())
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []UniqueVolumeName{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceAttachedVolume(v []AttachedVolume, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceAttachedVolume(v *[]AttachedVolume, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []AttachedVolume{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]AttachedVolume, yyrl1)
- }
- } else {
- yyv1 = make([]AttachedVolume, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = AttachedVolume{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, AttachedVolume{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = AttachedVolume{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, AttachedVolume{}) // var yyz1 AttachedVolume
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = AttachedVolume{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []AttachedVolume{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encResourceList(v ResourceList, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeMapStart(len(v))
- for yyk1, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- yyk1.CodecEncodeSelf(e)
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- yy3 := &yyv1
- yym4 := z.EncBinary()
- _ = yym4
- if false {
- } else if z.HasExtensions() && z.EncExt(yy3) {
- } else if !yym4 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy3)
- } else {
- z.EncFallback(yy3)
- }
- }
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x codecSelfer1234) decResourceList(v *ResourceList, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyl1 := r.ReadMapStart()
- yybh1 := z.DecBasicHandle()
- if yyv1 == nil {
- yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 72)
- yyv1 = make(map[ResourceName]pkg3_resource.Quantity, yyrl1)
- *v = yyv1
- }
- var yymk1 ResourceName
- var yymv1 pkg3_resource.Quantity
- var yymg1 bool
- if yybh1.MapValueReset {
- yymg1 = true
- }
- if yyl1 > 0 {
- for yyj1 := 0; yyj1 < yyl1; yyj1++ {
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- if r.TryDecodeAsNil() {
- yymk1 = ""
- } else {
- yymk1 = ResourceName(r.DecodeString())
- }
-
- if yymg1 {
- yymv1 = yyv1[yymk1]
- } else {
- yymv1 = pkg3_resource.Quantity{}
- }
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- if r.TryDecodeAsNil() {
- yymv1 = pkg3_resource.Quantity{}
- } else {
- yyv3 := &yymv1
- yym4 := z.DecBinary()
- _ = yym4
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv3) {
- } else if !yym4 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv3)
- } else {
- z.DecFallback(yyv3, false)
- }
- }
-
- if yyv1 != nil {
- yyv1[yymk1] = yymv1
- }
- }
- } else if yyl1 < 0 {
- for yyj1 := 0; !r.CheckBreak(); yyj1++ {
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- if r.TryDecodeAsNil() {
- yymk1 = ""
- } else {
- yymk1 = ResourceName(r.DecodeString())
- }
-
- if yymg1 {
- yymv1 = yyv1[yymk1]
- } else {
- yymv1 = pkg3_resource.Quantity{}
- }
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- if r.TryDecodeAsNil() {
- yymv1 = pkg3_resource.Quantity{}
- } else {
- yyv6 := &yymv1
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv6) {
- } else if !yym7 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv6)
- } else {
- z.DecFallback(yyv6, false)
- }
- }
-
- if yyv1 != nil {
- yyv1[yymk1] = yymv1
- }
- }
- } // else len==0: TODO: Should we clear map entries?
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x codecSelfer1234) encSliceNode(v []Node, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNode(v *[]Node, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Node{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 616)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Node, yyrl1)
- }
- } else {
- yyv1 = make([]Node, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Node{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Node{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Node{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Node{}) // var yyz1 Node
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Node{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Node{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceFinalizerName(v []FinalizerName, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yyv1.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceFinalizerName(v *[]FinalizerName, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []FinalizerName{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]FinalizerName, yyrl1)
- }
- } else {
- yyv1 = make([]FinalizerName, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = FinalizerName(r.DecodeString())
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, "")
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = FinalizerName(r.DecodeString())
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, "") // var yyz1 FinalizerName
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = FinalizerName(r.DecodeString())
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []FinalizerName{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceNamespace(v []Namespace, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceNamespace(v *[]Namespace, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Namespace{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 280)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Namespace, yyrl1)
- }
- } else {
- yyv1 = make([]Namespace, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Namespace{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Namespace{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Namespace{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Namespace{}) // var yyz1 Namespace
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Namespace{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Namespace{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceEvent(v []Event, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceEvent(v *[]Event, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Event{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 488)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Event, yyrl1)
- }
- } else {
- yyv1 = make([]Event, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Event{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Event{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Event{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Event{}) // var yyz1 Event
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Event{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Event{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceruntime_RawExtension(v []pkg5_runtime.RawExtension, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yym3 := z.EncBinary()
- _ = yym3
- if false {
- } else if z.HasExtensions() && z.EncExt(yy2) {
- } else if !yym3 && z.IsJSONHandle() {
- z.EncJSONMarshal(yy2)
- } else {
- z.EncFallback(yy2)
- }
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceruntime_RawExtension(v *[]pkg5_runtime.RawExtension, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []pkg5_runtime.RawExtension{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]pkg5_runtime.RawExtension, yyrl1)
- }
- } else {
- yyv1 = make([]pkg5_runtime.RawExtension, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = pkg5_runtime.RawExtension{}
- } else {
- yyv2 := &yyv1[yyj1]
- yym3 := z.DecBinary()
- _ = yym3
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv2) {
- } else if !yym3 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv2)
- } else {
- z.DecFallback(yyv2, false)
- }
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, pkg5_runtime.RawExtension{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = pkg5_runtime.RawExtension{}
- } else {
- yyv4 := &yyv1[yyj1]
- yym5 := z.DecBinary()
- _ = yym5
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv4) {
- } else if !yym5 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv4)
- } else {
- z.DecFallback(yyv4, false)
- }
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, pkg5_runtime.RawExtension{}) // var yyz1 pkg5_runtime.RawExtension
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = pkg5_runtime.RawExtension{}
- } else {
- yyv6 := &yyv1[yyj1]
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else if z.HasExtensions() && z.DecExt(yyv6) {
- } else if !yym7 && z.IsJSONHandle() {
- z.DecJSONUnmarshal(yyv6)
- } else {
- z.DecFallback(yyv6, false)
- }
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []pkg5_runtime.RawExtension{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceLimitRangeItem(v []LimitRangeItem, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceLimitRangeItem(v *[]LimitRangeItem, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []LimitRangeItem{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]LimitRangeItem, yyrl1)
- }
- } else {
- yyv1 = make([]LimitRangeItem, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRangeItem{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, LimitRangeItem{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRangeItem{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, LimitRangeItem{}) // var yyz1 LimitRangeItem
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRangeItem{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []LimitRangeItem{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceLimitRange(v []LimitRange, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceLimitRange(v *[]LimitRange, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []LimitRange{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 264)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]LimitRange, yyrl1)
- }
- } else {
- yyv1 = make([]LimitRange, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRange{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, LimitRange{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRange{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, LimitRange{}) // var yyz1 LimitRange
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = LimitRange{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []LimitRange{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceResourceQuotaScope(v []ResourceQuotaScope, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yyv1.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceResourceQuotaScope(v *[]ResourceQuotaScope, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ResourceQuotaScope{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ResourceQuotaScope, yyrl1)
- }
- } else {
- yyv1 = make([]ResourceQuotaScope, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, "")
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, "") // var yyz1 ResourceQuotaScope
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ""
- } else {
- yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ResourceQuotaScope{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceResourceQuota(v *[]ResourceQuota, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ResourceQuota{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ResourceQuota, yyrl1)
- }
- } else {
- yyv1 = make([]ResourceQuota, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ResourceQuota{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ResourceQuota{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ResourceQuota{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ResourceQuota{}) // var yyz1 ResourceQuota
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ResourceQuota{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ResourceQuota{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encMapstringSliceuint8(v map[string][]uint8, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeMapStart(len(v))
- for yyk1, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerMapKey1234)
- yym2 := z.EncBinary()
- _ = yym2
- if false {
- } else {
- r.EncodeString(codecSelferC_UTF81234, string(yyk1))
- }
- z.EncSendContainerState(codecSelfer_containerMapValue1234)
- if yyv1 == nil {
- r.EncodeNil()
- } else {
- yym3 := z.EncBinary()
- _ = yym3
- if false {
- } else {
- r.EncodeStringBytes(codecSelferC_RAW1234, []byte(yyv1))
- }
- }
- }
- z.EncSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x codecSelfer1234) decMapstringSliceuint8(v *map[string][]uint8, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyl1 := r.ReadMapStart()
- yybh1 := z.DecBasicHandle()
- if yyv1 == nil {
- yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40)
- yyv1 = make(map[string][]uint8, yyrl1)
- *v = yyv1
- }
- var yymk1 string
- var yymv1 []uint8
- var yymg1 bool
- if yybh1.MapValueReset {
- yymg1 = true
- }
- if yyl1 > 0 {
- for yyj1 := 0; yyj1 < yyl1; yyj1++ {
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- if r.TryDecodeAsNil() {
- yymk1 = ""
- } else {
- yymk1 = string(r.DecodeString())
- }
-
- if yymg1 {
- yymv1 = yyv1[yymk1]
- } else {
- yymv1 = nil
- }
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- if r.TryDecodeAsNil() {
- yymv1 = nil
- } else {
- yyv3 := &yymv1
- yym4 := z.DecBinary()
- _ = yym4
- if false {
- } else {
- *yyv3 = r.DecodeBytes(*(*[]byte)(yyv3), false, false)
- }
- }
-
- if yyv1 != nil {
- yyv1[yymk1] = yymv1
- }
- }
- } else if yyl1 < 0 {
- for yyj1 := 0; !r.CheckBreak(); yyj1++ {
- z.DecSendContainerState(codecSelfer_containerMapKey1234)
- if r.TryDecodeAsNil() {
- yymk1 = ""
- } else {
- yymk1 = string(r.DecodeString())
- }
-
- if yymg1 {
- yymv1 = yyv1[yymk1]
- } else {
- yymv1 = nil
- }
- z.DecSendContainerState(codecSelfer_containerMapValue1234)
- if r.TryDecodeAsNil() {
- yymv1 = nil
- } else {
- yyv6 := &yymv1
- yym7 := z.DecBinary()
- _ = yym7
- if false {
- } else {
- *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false)
- }
- }
-
- if yyv1 != nil {
- yyv1[yymk1] = yymv1
- }
- }
- } // else len==0: TODO: Should we clear map entries?
- z.DecSendContainerState(codecSelfer_containerMapEnd1234)
-}
-
-func (x codecSelfer1234) encSliceuint8(v []uint8, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yym2 := z.EncBinary()
- _ = yym2
- if false {
- } else {
- r.EncodeUint(uint64(yyv1))
- }
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceuint8(v *[]uint8, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []uint8{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 1)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]uint8, yyrl1)
- }
- } else {
- yyv1 = make([]uint8, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = 0
- } else {
- yyv1[yyj1] = uint8(r.DecodeUint(8))
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, 0)
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = 0
- } else {
- yyv1[yyj1] = uint8(r.DecodeUint(8))
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, 0) // var yyz1 uint8
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = 0
- } else {
- yyv1[yyj1] = uint8(r.DecodeUint(8))
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []uint8{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceSecret(v []Secret, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceSecret(v *[]Secret, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []Secret{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 272)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]Secret, yyrl1)
- }
- } else {
- yyv1 = make([]Secret, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Secret{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, Secret{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Secret{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, Secret{}) // var yyz1 Secret
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = Secret{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []Secret{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceConfigMap(v []ConfigMap, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceConfigMap(v *[]ConfigMap, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ConfigMap{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 248)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ConfigMap, yyrl1)
- }
- } else {
- yyv1 = make([]ConfigMap, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ConfigMap{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ConfigMap{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ConfigMap{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ConfigMap{}) // var yyz1 ConfigMap
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ConfigMap{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ConfigMap{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceComponentCondition(v []ComponentCondition, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceComponentCondition(v *[]ComponentCondition, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ComponentCondition{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ComponentCondition, yyrl1)
- }
- } else {
- yyv1 = make([]ComponentCondition, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentCondition{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ComponentCondition{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentCondition{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ComponentCondition{}) // var yyz1 ComponentCondition
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentCondition{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ComponentCondition{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceComponentStatus(v []ComponentStatus, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceComponentStatus(v *[]ComponentStatus, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []ComponentStatus{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 264)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]ComponentStatus, yyrl1)
- }
- } else {
- yyv1 = make([]ComponentStatus, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentStatus{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, ComponentStatus{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentStatus{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, ComponentStatus{}) // var yyz1 ComponentStatus
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = ComponentStatus{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []ComponentStatus{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
-
-func (x codecSelfer1234) encSliceDownwardAPIVolumeFile(v []DownwardAPIVolumeFile, e *codec1978.Encoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperEncoder(e)
- _, _, _ = h, z, r
- r.EncodeArrayStart(len(v))
- for _, yyv1 := range v {
- z.EncSendContainerState(codecSelfer_containerArrayElem1234)
- yy2 := &yyv1
- yy2.CodecEncodeSelf(e)
- }
- z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
-}
-
-func (x codecSelfer1234) decSliceDownwardAPIVolumeFile(v *[]DownwardAPIVolumeFile, d *codec1978.Decoder) {
- var h codecSelfer1234
- z, r := codec1978.GenHelperDecoder(d)
- _, _, _ = h, z, r
-
- yyv1 := *v
- yyh1, yyl1 := z.DecSliceHelperStart()
- var yyc1 bool
- _ = yyc1
- if yyl1 == 0 {
- if yyv1 == nil {
- yyv1 = []DownwardAPIVolumeFile{}
- yyc1 = true
- } else if len(yyv1) != 0 {
- yyv1 = yyv1[:0]
- yyc1 = true
- }
- } else if yyl1 > 0 {
- var yyrr1, yyrl1 int
- var yyrt1 bool
- _, _ = yyrl1, yyrt1
- yyrr1 = yyl1 // len(yyv1)
- if yyl1 > cap(yyv1) {
-
- yyrg1 := len(yyv1) > 0
- yyv21 := yyv1
- yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32)
- if yyrt1 {
- if yyrl1 <= cap(yyv1) {
- yyv1 = yyv1[:yyrl1]
- } else {
- yyv1 = make([]DownwardAPIVolumeFile, yyrl1)
- }
- } else {
- yyv1 = make([]DownwardAPIVolumeFile, yyrl1)
- }
- yyc1 = true
- yyrr1 = len(yyv1)
- if yyrg1 {
- copy(yyv1, yyv21)
- }
- } else if yyl1 != len(yyv1) {
- yyv1 = yyv1[:yyl1]
- yyc1 = true
- }
- yyj1 := 0
- for ; yyj1 < yyrr1; yyj1++ {
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = DownwardAPIVolumeFile{}
- } else {
- yyv2 := &yyv1[yyj1]
- yyv2.CodecDecodeSelf(d)
- }
-
- }
- if yyrt1 {
- for ; yyj1 < yyl1; yyj1++ {
- yyv1 = append(yyv1, DownwardAPIVolumeFile{})
- yyh1.ElemContainerState(yyj1)
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = DownwardAPIVolumeFile{}
- } else {
- yyv3 := &yyv1[yyj1]
- yyv3.CodecDecodeSelf(d)
- }
-
- }
- }
-
- } else {
- yyj1 := 0
- for ; !r.CheckBreak(); yyj1++ {
-
- if yyj1 >= len(yyv1) {
- yyv1 = append(yyv1, DownwardAPIVolumeFile{}) // var yyz1 DownwardAPIVolumeFile
- yyc1 = true
- }
- yyh1.ElemContainerState(yyj1)
- if yyj1 < len(yyv1) {
- if r.TryDecodeAsNil() {
- yyv1[yyj1] = DownwardAPIVolumeFile{}
- } else {
- yyv4 := &yyv1[yyj1]
- yyv4.CodecDecodeSelf(d)
- }
-
- } else {
- z.DecSwallow()
- }
-
- }
- if yyj1 < len(yyv1) {
- yyv1 = yyv1[:yyj1]
- yyc1 = true
- } else if yyj1 == 0 && yyv1 == nil {
- yyv1 = []DownwardAPIVolumeFile{}
- yyc1 = true
- }
- }
- yyh1.End()
- if yyc1 {
- *v = yyv1
- }
-}
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.go
deleted file mode 100644
index 42a0b98..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types.go
+++ /dev/null
@@ -1,3329 +0,0 @@
-/*
-Copyright 2015 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.
-*/
-
-package v1
-
-import (
- "k8s.io/kubernetes/pkg/api/resource"
- "k8s.io/kubernetes/pkg/api/unversioned"
- "k8s.io/kubernetes/pkg/runtime"
- "k8s.io/kubernetes/pkg/types"
- "k8s.io/kubernetes/pkg/util/intstr"
-)
-
-// The comments for the structs and fields can be used from go-resful to
-// generate Swagger API documentation for its models. Please read this PR for more
-// information on the implementation: https://github.com/emicklei/go-restful/pull/215
-//
-// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if
-// they are on one line! For multiple line or blocks that you want to ignore use ---.
-// Any context after a --- is ignored and not exported to the SwaggerAPI.
-//
-// The aforementioned methods can be generated by hack/update-generated-swagger-docs.sh
-
-// Common string formats
-// ---------------------
-// Many fields in this API have formatting requirements. The commonly used
-// formats are defined here.
-//
-// C_IDENTIFIER: This is a string that conforms to the definition of an "identifier"
-// in the C language. This is captured by the following regex:
-// [A-Za-z_][A-Za-z0-9_]*
-// This defines the format, but not the length restriction, which should be
-// specified at the definition of any field of this type.
-//
-// DNS_LABEL: This is a string, no more than 63 characters long, that conforms
-// to the definition of a "label" in RFCs 1035 and 1123. This is captured
-// by the following regex:
-// [a-z0-9]([-a-z0-9]*[a-z0-9])?
-//
-// DNS_SUBDOMAIN: This is a string, no more than 253 characters long, that conforms
-// to the definition of a "subdomain" in RFCs 1035 and 1123. This is captured
-// by the following regex:
-// [a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*
-// or more simply:
-// DNS_LABEL(\.DNS_LABEL)*
-//
-// IANA_SVC_NAME: This is a string, no more than 15 characters long, that
-// conforms to the definition of IANA service name in RFC 6335.
-// It must contains at least one letter [a-z] and it must contains only [a-z0-9-].
-// Hypens ('-') cannot be leading or trailing character of the string
-// and cannot be adjacent to other hyphens.
-
-// ObjectMeta is metadata that all persisted resources must have, which includes all objects
-// users must create.
-type ObjectMeta struct {
- // Name must be unique within a namespace. Is required when creating resources, although
- // some resources may allow a client to request the generation of an appropriate name
- // automatically. Name is primarily intended for creation idempotence and configuration
- // definition.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
-
- // GenerateName is an optional prefix, used by the server, to generate a unique
- // name ONLY IF the Name field has not been provided.
- // If this field is used, the name returned to the client will be different
- // than the name passed. This value will also be combined with a unique suffix.
- // The provided value has the same validation rules as the Name field,
- // and may be truncated by the length of the suffix required to make the value
- // unique on the server.
- //
- // If this field is specified and the generated name exists, the server will
- // NOT return a 409 - instead, it will either return 201 Created or 500 with Reason
- // ServerTimeout indicating a unique name could not be found in the time allotted, and the client
- // should retry (optionally after the time indicated in the Retry-After header).
- //
- // Applied only if Name is not specified.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency
- GenerateName string `json:"generateName,omitempty" protobuf:"bytes,2,opt,name=generateName"`
-
- // Namespace defines the space within each name must be unique. An empty namespace is
- // equivalent to the "default" namespace, but "default" is the canonical representation.
- // Not all objects are required to be scoped to a namespace - the value of this field for
- // those objects will be empty.
- //
- // Must be a DNS_LABEL.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- Namespace string `json:"namespace,omitempty" protobuf:"bytes,3,opt,name=namespace"`
-
- // SelfLink is a URL representing this object.
- // Populated by the system.
- // Read-only.
- SelfLink string `json:"selfLink,omitempty" protobuf:"bytes,4,opt,name=selfLink"`
-
- // UID is the unique in time and space value for this object. It is typically generated by
- // the server on successful creation of a resource and is not allowed to change on PUT
- // operations.
- //
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- UID types.UID `json:"uid,omitempty" protobuf:"bytes,5,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"`
-
- // An opaque value that represents the internal version of this object that can
- // be used by clients to determine when objects have changed. May be used for optimistic
- // concurrency, change detection, and the watch operation on a resource or set of resources.
- // Clients must treat these values as opaque and passed unmodified back to the server.
- // They may only be valid for a particular resource or set of resources.
- //
- // Populated by the system.
- // Read-only.
- // Value must be treated as opaque by clients and .
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
- ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"`
-
- // A sequence number representing a specific generation of the desired state.
- // Populated by the system. Read-only.
- Generation int64 `json:"generation,omitempty" protobuf:"varint,7,opt,name=generation"`
-
- // CreationTimestamp is a timestamp representing the server time when this object was
- // created. It is not guaranteed to be set in happens-before order across separate operations.
- // Clients may not set this value. It is represented in RFC3339 form and is in UTC.
- //
- // Populated by the system.
- // Read-only.
- // Null for lists.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- CreationTimestamp unversioned.Time `json:"creationTimestamp,omitempty" protobuf:"bytes,8,opt,name=creationTimestamp"`
-
- // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This
- // field is set by the server when a graceful deletion is requested by the user, and is not
- // directly settable by a client. The resource will be deleted (no longer visible from
- // resource lists, and not reachable by name) after the time in this field. Once set, this
- // value may not be unset or be set further into the future, although it may be shortened
- // or the resource may be deleted prior to this time. For example, a user may request that
- // a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination
- // signal to the containers in the pod. Once the resource is deleted in the API, the Kubelet
- // will send a hard termination signal to the container.
- // If not set, graceful deletion of the object has not been requested.
- //
- // Populated by the system when a graceful deletion is requested.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- DeletionTimestamp *unversioned.Time `json:"deletionTimestamp,omitempty" protobuf:"bytes,9,opt,name=deletionTimestamp"`
-
- // Number of seconds allowed for this object to gracefully terminate before
- // it will be removed from the system. Only set when deletionTimestamp is also set.
- // May only be shortened.
- // Read-only.
- DeletionGracePeriodSeconds *int64 `json:"deletionGracePeriodSeconds,omitempty" protobuf:"varint,10,opt,name=deletionGracePeriodSeconds"`
-
- // Map of string keys and values that can be used to organize and categorize
- // (scope and select) objects. May match selectors of replication controllers
- // and services.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md
- // TODO: replace map[string]string with labels.LabelSet type
- Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,11,rep,name=labels"`
-
- // Annotations is an unstructured key value map stored with a resource that may be
- // set by external tools to store and retrieve arbitrary metadata. They are not
- // queryable and should be preserved when modifying objects.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/annotations.md
- Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,12,rep,name=annotations"`
-
- // List of objects depended by this object. If ALL objects in the list have
- // been deleted, this object will be garbage collected. If this object is managed by a controller,
- // then an entry in this list will point to this controller, with the controller field set to true.
- // There cannot be more than one managing controller.
- OwnerReferences []OwnerReference `json:"ownerReferences,omitempty" patchStrategy:"merge" patchMergeKey:"uid" protobuf:"bytes,13,rep,name=ownerReferences"`
-
- // Must be empty before the object is deleted from the registry. Each entry
- // is an identifier for the responsible component that will remove the entry
- // from the list. If the deletionTimestamp of the object is non-nil, entries
- // in this list can only be removed.
- Finalizers []string `json:"finalizers,omitempty" patchStrategy:"merge" protobuf:"bytes,14,rep,name=finalizers"`
-}
-
-const (
- // NamespaceDefault means the object is in the default namespace which is applied when not specified by clients
- NamespaceDefault string = "default"
- // NamespaceAll is the default argument to specify on a context when you want to list or filter resources across all namespaces
- NamespaceAll string = ""
-)
-
-// Volume represents a named volume in a pod that may be accessed by any container in the pod.
-type Volume struct {
- // Volume's name.
- // Must be a DNS_LABEL and unique within the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
- // VolumeSource represents the location and type of the mounted volume.
- // If not specified, the Volume is implied to be an EmptyDir.
- // This implied behavior is deprecated and will be removed in a future version.
- VolumeSource `json:",inline" protobuf:"bytes,2,opt,name=volumeSource"`
-}
-
-// Represents the source of a volume to mount.
-// Only one of its members may be specified.
-type VolumeSource struct {
- // HostPath represents a pre-existing file or directory on the host
- // machine that is directly exposed to the container. This is generally
- // used for system agents or other privileged things that are allowed
- // to see the host machine. Most containers will NOT need this.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- // ---
- // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not
- // mount host directories as read/write.
- HostPath *HostPathVolumeSource `json:"hostPath,omitempty" protobuf:"bytes,1,opt,name=hostPath"`
- // EmptyDir represents a temporary directory that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir
- EmptyDir *EmptyDirVolumeSource `json:"emptyDir,omitempty" protobuf:"bytes,2,opt,name=emptyDir"`
- // GCEPersistentDisk represents a GCE Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty" protobuf:"bytes,3,opt,name=gcePersistentDisk"`
- // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty" protobuf:"bytes,4,opt,name=awsElasticBlockStore"`
- // GitRepo represents a git repository at a particular revision.
- GitRepo *GitRepoVolumeSource `json:"gitRepo,omitempty" protobuf:"bytes,5,opt,name=gitRepo"`
- // Secret represents a secret that should populate this volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets
- Secret *SecretVolumeSource `json:"secret,omitempty" protobuf:"bytes,6,opt,name=secret"`
- // NFS represents an NFS mount on the host that shares a pod's lifetime
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- NFS *NFSVolumeSource `json:"nfs,omitempty" protobuf:"bytes,7,opt,name=nfs"`
- // ISCSI represents an ISCSI Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md
- ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty" protobuf:"bytes,8,opt,name=iscsi"`
- // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
- Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty" protobuf:"bytes,9,opt,name=glusterfs"`
- // PersistentVolumeClaimVolumeSource represents a reference to a
- // PersistentVolumeClaim in the same namespace.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- PersistentVolumeClaim *PersistentVolumeClaimVolumeSource `json:"persistentVolumeClaim,omitempty" protobuf:"bytes,10,opt,name=persistentVolumeClaim"`
- // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
- RBD *RBDVolumeSource `json:"rbd,omitempty" protobuf:"bytes,11,opt,name=rbd"`
- // FlexVolume represents a generic volume resource that is
- // provisioned/attached using a exec based plugin. This is an
- // alpha feature and may change in future.
- FlexVolume *FlexVolumeSource `json:"flexVolume,omitempty" protobuf:"bytes,12,opt,name=flexVolume"`
- // Cinder represents a cinder volume attached and mounted on kubelets host machine
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- Cinder *CinderVolumeSource `json:"cinder,omitempty" protobuf:"bytes,13,opt,name=cinder"`
-
- // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
- CephFS *CephFSVolumeSource `json:"cephfs,omitempty" protobuf:"bytes,14,opt,name=cephfs"`
-
- // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running
- Flocker *FlockerVolumeSource `json:"flocker,omitempty" protobuf:"bytes,15,opt,name=flocker"`
-
- // DownwardAPI represents downward API about the pod that should populate this volume
- DownwardAPI *DownwardAPIVolumeSource `json:"downwardAPI,omitempty" protobuf:"bytes,16,opt,name=downwardAPI"`
- // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
- FC *FCVolumeSource `json:"fc,omitempty" protobuf:"bytes,17,opt,name=fc"`
- // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
- AzureFile *AzureFileVolumeSource `json:"azureFile,omitempty" protobuf:"bytes,18,opt,name=azureFile"`
- // ConfigMap represents a configMap that should populate this volume
- ConfigMap *ConfigMapVolumeSource `json:"configMap,omitempty" protobuf:"bytes,19,opt,name=configMap"`
- // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
- VsphereVolume *VsphereVirtualDiskVolumeSource `json:"vsphereVolume,omitempty" protobuf:"bytes,20,opt,name=vsphereVolume"`
-}
-
-// PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace.
-// This volume finds the bound PV and mounts that volume for the pod. A
-// PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another
-// type of volume that is owned by someone else (the system).
-type PersistentVolumeClaimVolumeSource struct {
- // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- ClaimName string `json:"claimName" protobuf:"bytes,1,opt,name=claimName"`
- // Will force the ReadOnly setting in VolumeMounts.
- // Default false.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,2,opt,name=readOnly"`
-}
-
-// PersistentVolumeSource is similar to VolumeSource but meant for the
-// administrator who creates PVs. Exactly one of its members must be set.
-type PersistentVolumeSource struct {
- // GCEPersistentDisk represents a GCE Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty" protobuf:"bytes,1,opt,name=gcePersistentDisk"`
- // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty" protobuf:"bytes,2,opt,name=awsElasticBlockStore"`
- // HostPath represents a directory on the host.
- // Provisioned by a developer or tester.
- // This is useful for single-node development and testing only!
- // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- HostPath *HostPathVolumeSource `json:"hostPath,omitempty" protobuf:"bytes,3,opt,name=hostPath"`
- // Glusterfs represents a Glusterfs volume that is attached to a host and
- // exposed to the pod. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
- Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty" protobuf:"bytes,4,opt,name=glusterfs"`
- // NFS represents an NFS mount on the host. Provisioned by an admin.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- NFS *NFSVolumeSource `json:"nfs,omitempty" protobuf:"bytes,5,opt,name=nfs"`
- // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
- RBD *RBDVolumeSource `json:"rbd,omitempty" protobuf:"bytes,6,opt,name=rbd"`
- // ISCSI represents an ISCSI Disk resource that is attached to a
- // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
- ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty" protobuf:"bytes,7,opt,name=iscsi"`
- // Cinder represents a cinder volume attached and mounted on kubelets host machine
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- Cinder *CinderVolumeSource `json:"cinder,omitempty" protobuf:"bytes,8,opt,name=cinder"`
- // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
- CephFS *CephFSVolumeSource `json:"cephfs,omitempty" protobuf:"bytes,9,opt,name=cephfs"`
- // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
- FC *FCVolumeSource `json:"fc,omitempty" protobuf:"bytes,10,opt,name=fc"`
- // Flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running
- Flocker *FlockerVolumeSource `json:"flocker,omitempty" protobuf:"bytes,11,opt,name=flocker"`
- // FlexVolume represents a generic volume resource that is
- // provisioned/attached using a exec based plugin. This is an
- // alpha feature and may change in future.
- FlexVolume *FlexVolumeSource `json:"flexVolume,omitempty" protobuf:"bytes,12,opt,name=flexVolume"`
- // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
- AzureFile *AzureFileVolumeSource `json:"azureFile,omitempty" protobuf:"bytes,13,opt,name=azureFile"`
- // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
- VsphereVolume *VsphereVirtualDiskVolumeSource `json:"vsphereVolume,omitempty" protobuf:"bytes,14,opt,name=vsphereVolume"`
-}
-
-// +genclient=true
-// +nonNamespaced=true
-
-// PersistentVolume (PV) is a storage resource provisioned by an administrator.
-// It is analogous to a node.
-// More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md
-type PersistentVolume struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines a specification of a persistent volume owned by the cluster.
- // Provisioned by an administrator.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes
- Spec PersistentVolumeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Status represents the current information/status for the persistent volume.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes
- Status PersistentVolumeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// PersistentVolumeSpec is the specification of a persistent volume.
-type PersistentVolumeSpec struct {
- // A description of the persistent volume's resources and capacity.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity
- Capacity ResourceList `json:"capacity,omitempty" protobuf:"bytes,1,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"`
- // The actual volume backing the persistent volume.
- PersistentVolumeSource `json:",inline" protobuf:"bytes,2,opt,name=persistentVolumeSource"`
- // AccessModes contains all ways the volume can be mounted.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes
- AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,3,rep,name=accessModes,casttype=PersistentVolumeAccessMode"`
- // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim.
- // Expected to be non-nil when bound.
- // claim.VolumeName is the authoritative bind between PV and PVC.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#binding
- ClaimRef *ObjectReference `json:"claimRef,omitempty" protobuf:"bytes,4,opt,name=claimRef"`
- // What happens to a persistent volume when released from its claim.
- // Valid options are Retain (default) and Recycle.
- // Recyling must be supported by the volume plugin underlying this persistent volume.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#recycling-policy
- PersistentVolumeReclaimPolicy PersistentVolumeReclaimPolicy `json:"persistentVolumeReclaimPolicy,omitempty" protobuf:"bytes,5,opt,name=persistentVolumeReclaimPolicy,casttype=PersistentVolumeReclaimPolicy"`
-}
-
-// PersistentVolumeReclaimPolicy describes a policy for end-of-life maintenance of persistent volumes.
-type PersistentVolumeReclaimPolicy string
-
-const (
- // PersistentVolumeReclaimRecycle means the volume will be recycled back into the pool of unbound persistent volumes on release from its claim.
- // The volume plugin must support Recycling.
- PersistentVolumeReclaimRecycle PersistentVolumeReclaimPolicy = "Recycle"
- // PersistentVolumeReclaimDelete means the volume will be deleted from Kubernetes on release from its claim.
- // The volume plugin must support Deletion.
- PersistentVolumeReclaimDelete PersistentVolumeReclaimPolicy = "Delete"
- // PersistentVolumeReclaimRetain means the volume will be left in its current phase (Released) for manual reclamation by the administrator.
- // The default policy is Retain.
- PersistentVolumeReclaimRetain PersistentVolumeReclaimPolicy = "Retain"
-)
-
-// PersistentVolumeStatus is the current status of a persistent volume.
-type PersistentVolumeStatus struct {
- // Phase indicates if a volume is available, bound to a claim, or released by a claim.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#phase
- Phase PersistentVolumePhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PersistentVolumePhase"`
- // A human-readable message indicating details about why the volume is in this state.
- Message string `json:"message,omitempty" protobuf:"bytes,2,opt,name=message"`
- // Reason is a brief CamelCase string that describes any failure and is meant
- // for machine parsing and tidy display in the CLI.
- Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"`
-}
-
-// PersistentVolumeList is a list of PersistentVolume items.
-type PersistentVolumeList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
- // List of persistent volumes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md
- Items []PersistentVolume `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// PersistentVolumeClaim is a user's request for and claim to a persistent volume
-type PersistentVolumeClaim struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the desired characteristics of a volume requested by a pod author.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- Spec PersistentVolumeClaimSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Status represents the current information/status of a persistent volume claim.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- Status PersistentVolumeClaimStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// PersistentVolumeClaimList is a list of PersistentVolumeClaim items.
-type PersistentVolumeClaimList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
- // A list of persistent volume claims.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims
- Items []PersistentVolumeClaim `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// PersistentVolumeClaimSpec describes the common attributes of storage devices
-// and allows a Source for provider-specific attributes
-type PersistentVolumeClaimSpec struct {
- // AccessModes contains the desired access modes the volume should have.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1
- AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,1,rep,name=accessModes,casttype=PersistentVolumeAccessMode"`
- // A label query over volumes to consider for binding.
- Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"`
- // Resources represents the minimum resources the volume should have.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources
- Resources ResourceRequirements `json:"resources,omitempty" protobuf:"bytes,2,opt,name=resources"`
- // VolumeName is the binding reference to the PersistentVolume backing this claim.
- VolumeName string `json:"volumeName,omitempty" protobuf:"bytes,3,opt,name=volumeName"`
-}
-
-// PersistentVolumeClaimStatus is the current status of a persistent volume claim.
-type PersistentVolumeClaimStatus struct {
- // Phase represents the current phase of PersistentVolumeClaim.
- Phase PersistentVolumeClaimPhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PersistentVolumeClaimPhase"`
- // AccessModes contains the actual access modes the volume backing the PVC has.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1
- AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,2,rep,name=accessModes,casttype=PersistentVolumeAccessMode"`
- // Represents the actual resources of the underlying volume.
- Capacity ResourceList `json:"capacity,omitempty" protobuf:"bytes,3,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"`
-}
-
-type PersistentVolumeAccessMode string
-
-const (
- // can be mounted read/write mode to exactly 1 host
- ReadWriteOnce PersistentVolumeAccessMode = "ReadWriteOnce"
- // can be mounted in read-only mode to many hosts
- ReadOnlyMany PersistentVolumeAccessMode = "ReadOnlyMany"
- // can be mounted in read/write mode to many hosts
- ReadWriteMany PersistentVolumeAccessMode = "ReadWriteMany"
-)
-
-type PersistentVolumePhase string
-
-const (
- // used for PersistentVolumes that are not available
- VolumePending PersistentVolumePhase = "Pending"
- // used for PersistentVolumes that are not yet bound
- // Available volumes are held by the binder and matched to PersistentVolumeClaims
- VolumeAvailable PersistentVolumePhase = "Available"
- // used for PersistentVolumes that are bound
- VolumeBound PersistentVolumePhase = "Bound"
- // used for PersistentVolumes where the bound PersistentVolumeClaim was deleted
- // released volumes must be recycled before becoming available again
- // this phase is used by the persistent volume claim binder to signal to another process to reclaim the resource
- VolumeReleased PersistentVolumePhase = "Released"
- // used for PersistentVolumes that failed to be correctly recycled or deleted after being released from a claim
- VolumeFailed PersistentVolumePhase = "Failed"
-)
-
-type PersistentVolumeClaimPhase string
-
-const (
- // used for PersistentVolumeClaims that are not yet bound
- ClaimPending PersistentVolumeClaimPhase = "Pending"
- // used for PersistentVolumeClaims that are bound
- ClaimBound PersistentVolumeClaimPhase = "Bound"
- // used for PersistentVolumeClaims that lost their underlying
- // PersistentVolume. The claim was bound to a PersistentVolume and this
- // volume does not exist any longer and all data on it was lost.
- ClaimLost PersistentVolumeClaimPhase = "Lost"
-)
-
-// Represents a host path mapped into a pod.
-// Host path volumes do not support ownership management or SELinux relabeling.
-type HostPathVolumeSource struct {
- // Path of the directory on the host.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath
- Path string `json:"path" protobuf:"bytes,1,opt,name=path"`
-}
-
-// Represents an empty directory for a pod.
-// Empty directory volumes support ownership management and SELinux relabeling.
-type EmptyDirVolumeSource struct {
- // What type of storage medium should back this directory.
- // The default is "" which means to use the node's default medium.
- // Must be an empty string (default) or Memory.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir
- Medium StorageMedium `json:"medium,omitempty" protobuf:"bytes,1,opt,name=medium,casttype=StorageMedium"`
-}
-
-// Represents a Glusterfs mount that lasts the lifetime of a pod.
-// Glusterfs volumes do not support ownership management or SELinux relabeling.
-type GlusterfsVolumeSource struct {
- // EndpointsName is the endpoint name that details Glusterfs topology.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- EndpointsName string `json:"endpoints" protobuf:"bytes,1,opt,name=endpoints"`
-
- // Path is the Glusterfs volume path.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- Path string `json:"path" protobuf:"bytes,2,opt,name=path"`
-
- // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"`
-}
-
-// Represents a Rados Block Device mount that lasts the lifetime of a pod.
-// RBD volumes support ownership management and SELinux relabeling.
-type RBDVolumeSource struct {
- // A collection of Ceph monitors.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- CephMonitors []string `json:"monitors" protobuf:"bytes,1,rep,name=monitors"`
- // The rados image name.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- RBDImage string `json:"image" protobuf:"bytes,2,opt,name=image"`
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#rbd
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- FSType string `json:"fsType,omitempty" protobuf:"bytes,3,opt,name=fsType"`
- // The rados pool name.
- // Default is rbd.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it.
- RBDPool string `json:"pool,omitempty" protobuf:"bytes,4,opt,name=pool"`
- // The rados user name.
- // Default is admin.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- RadosUser string `json:"user,omitempty" protobuf:"bytes,5,opt,name=user"`
- // Keyring is the path to key ring for RBDUser.
- // Default is /etc/ceph/keyring.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- Keyring string `json:"keyring,omitempty" protobuf:"bytes,6,opt,name=keyring"`
- // SecretRef is name of the authentication secret for RBDUser. If provided
- // overrides keyring.
- // Default is nil.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,7,opt,name=secretRef"`
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,8,opt,name=readOnly"`
-}
-
-// Represents a cinder volume resource in Openstack.
-// A Cinder volume must exist before mounting to a container.
-// The volume must also be in the same region as the kubelet.
-// Cinder volumes support ownership management and SELinux relabeling.
-type CinderVolumeSource struct {
- // volume id used to identify the volume in cinder
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- VolumeID string `json:"volumeID" protobuf:"bytes,1,opt,name=volumeID"`
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"`
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"`
-}
-
-// Represents a Ceph Filesystem mount that lasts the lifetime of a pod
-// Cephfs volumes do not support ownership management or SELinux relabeling.
-type CephFSVolumeSource struct {
- // Required: Monitors is a collection of Ceph monitors
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- Monitors []string `json:"monitors" protobuf:"bytes,1,rep,name=monitors"`
- // Optional: Used as the mounted root, rather than the full Ceph tree, default is /
- Path string `json:"path,omitempty" protobuf:"bytes,2,opt,name=path"`
- // Optional: User is the rados user name, default is admin
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- User string `json:"user,omitempty" protobuf:"bytes,3,opt,name=user"`
- // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- SecretFile string `json:"secretFile,omitempty" protobuf:"bytes,4,opt,name=secretFile"`
- // Optional: SecretRef is reference to the authentication secret for User, default is empty.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,5,opt,name=secretRef"`
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,6,opt,name=readOnly"`
-}
-
-// Represents a Flocker volume mounted by the Flocker agent.
-// Flocker volumes do not support ownership management or SELinux relabeling.
-type FlockerVolumeSource struct {
- // Required: the volume name. This is going to be store on metadata -> name on the payload for Flocker
- DatasetName string `json:"datasetName" protobuf:"bytes,1,opt,name=datasetName"`
-}
-
-// StorageMedium defines ways that storage can be allocated to a volume.
-type StorageMedium string
-
-const (
- StorageMediumDefault StorageMedium = "" // use whatever the default is for the node
- StorageMediumMemory StorageMedium = "Memory" // use memory (tmpfs)
-)
-
-// Protocol defines network protocols supported for things like container ports.
-type Protocol string
-
-const (
- // ProtocolTCP is the TCP protocol.
- ProtocolTCP Protocol = "TCP"
- // ProtocolUDP is the UDP protocol.
- ProtocolUDP Protocol = "UDP"
-)
-
-// Represents a Persistent Disk resource in Google Compute Engine.
-//
-// A GCE PD must exist before mounting to a container. The disk must
-// also be in the same GCE project and zone as the kubelet. A GCE PD
-// can only be mounted as read/write once or read-only many times. GCE
-// PDs support ownership management and SELinux relabeling.
-type GCEPersistentDiskVolumeSource struct {
- // Unique name of the PD resource in GCE. Used to identify the disk in GCE.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- PDName string `json:"pdName" protobuf:"bytes,1,opt,name=pdName"`
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"`
- // The partition in the volume that you want to mount.
- // If omitted, the default is to mount by volume name.
- // Examples: For volume /dev/sda1, you specify the partition as "1".
- // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- Partition int32 `json:"partition,omitempty" protobuf:"varint,3,opt,name=partition"`
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"`
-}
-
-// FlexVolume represents a generic volume resource that is
-// provisioned/attached using a exec based plugin. This is an alpha feature and may change in future.
-type FlexVolumeSource struct {
- // Driver is the name of the driver to use for this volume.
- Driver string `json:"driver" protobuf:"bytes,1,opt,name=driver"`
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script.
- FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"`
- // Optional: SecretRef is reference to the secret object containing
- // sensitive information to pass to the plugin scripts. This may be
- // empty if no secret object is specified. If the secret object
- // contains more than one secret, all secrets are passed to the plugin
- // scripts.
- SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,3,opt,name=secretRef"`
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"`
- // Optional: Extra command options if any.
- Options map[string]string `json:"options,omitempty" protobuf:"bytes,5,rep,name=options"`
-}
-
-// Represents a Persistent Disk resource in AWS.
-//
-// An AWS EBS disk must exist before mounting to a container. The disk
-// must also be in the same AWS zone as the kubelet. An AWS EBS disk
-// can only be mounted as read/write once. AWS EBS volumes support
-// ownership management and SELinux relabeling.
-type AWSElasticBlockStoreVolumeSource struct {
- // Unique ID of the persistent disk resource in AWS (Amazon EBS volume).
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- VolumeID string `json:"volumeID" protobuf:"bytes,1,opt,name=volumeID"`
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"`
- // The partition in the volume that you want to mount.
- // If omitted, the default is to mount by volume name.
- // Examples: For volume /dev/sda1, you specify the partition as "1".
- // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
- Partition int32 `json:"partition,omitempty" protobuf:"varint,3,opt,name=partition"`
- // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true".
- // If omitted, the default is "false".
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"`
-}
-
-// Represents a volume that is populated with the contents of a git repository.
-// Git repo volumes do not support ownership management.
-// Git repo volumes support SELinux relabeling.
-type GitRepoVolumeSource struct {
- // Repository URL
- Repository string `json:"repository" protobuf:"bytes,1,opt,name=repository"`
- // Commit hash for the specified revision.
- Revision string `json:"revision,omitempty" protobuf:"bytes,2,opt,name=revision"`
- // Target directory name.
- // Must not contain or start with '..'. If '.' is supplied, the volume directory will be the
- // git repository. Otherwise, if specified, the volume will contain the git repository in
- // the subdirectory with the given name.
- Directory string `json:"directory,omitempty" protobuf:"bytes,3,opt,name=directory"`
-}
-
-// Adapts a Secret into a volume.
-//
-// The contents of the target Secret's Data field will be presented in a volume
-// as files using the keys in the Data field as the file names.
-// Secret volumes support ownership management and SELinux relabeling.
-type SecretVolumeSource struct {
- // Name of the secret in the pod's namespace to use.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets
- SecretName string `json:"secretName,omitempty" protobuf:"bytes,1,opt,name=secretName"`
- // If unspecified, each key-value pair in the Data field of the referenced
- // Secret will be projected into the volume as a file whose name is the
- // key and content is the value. If specified, the listed keys will be
- // projected into the specified paths, and unlisted keys will not be
- // present. If a key is specified which is not present in the Secret,
- // the volume setup will error. Paths must be relative and may not contain
- // the '..' path or start with '..'.
- Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"`
-}
-
-// Represents an NFS mount that lasts the lifetime of a pod.
-// NFS volumes do not support ownership management or SELinux relabeling.
-type NFSVolumeSource struct {
- // Server is the hostname or IP address of the NFS server.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- Server string `json:"server" protobuf:"bytes,1,opt,name=server"`
-
- // Path that is exported by the NFS server.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- Path string `json:"path" protobuf:"bytes,2,opt,name=path"`
-
- // ReadOnly here will force
- // the NFS export to be mounted with read-only permissions.
- // Defaults to false.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"`
-}
-
-// Represents an ISCSI disk.
-// ISCSI volumes can only be mounted as read/write once.
-// ISCSI volumes support ownership management and SELinux relabeling.
-type ISCSIVolumeSource struct {
- // iSCSI target portal. The portal is either an IP or ip_addr:port if the port
- // is other than default (typically TCP ports 860 and 3260).
- TargetPortal string `json:"targetPortal" protobuf:"bytes,1,opt,name=targetPortal"`
- // Target iSCSI Qualified Name.
- IQN string `json:"iqn" protobuf:"bytes,2,opt,name=iqn"`
- // iSCSI target lun number.
- Lun int32 `json:"lun" protobuf:"varint,3,opt,name=lun"`
- // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport.
- ISCSIInterface string `json:"iscsiInterface,omitempty" protobuf:"bytes,4,opt,name=iscsiInterface"`
- // Filesystem type of the volume that you want to mount.
- // Tip: Ensure that the filesystem type is supported by the host operating system.
- // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#iscsi
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- FSType string `json:"fsType,omitempty" protobuf:"bytes,5,opt,name=fsType"`
- // ReadOnly here will force the ReadOnly setting in VolumeMounts.
- // Defaults to false.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,6,opt,name=readOnly"`
-}
-
-// Represents a Fibre Channel volume.
-// Fibre Channel volumes can only be mounted as read/write once.
-// Fibre Channel volumes support ownership management and SELinux relabeling.
-type FCVolumeSource struct {
- // Required: FC target world wide names (WWNs)
- TargetWWNs []string `json:"targetWWNs" protobuf:"bytes,1,rep,name=targetWWNs"`
- // Required: FC target lun number
- Lun *int32 `json:"lun" protobuf:"varint,2,opt,name=lun"`
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- // TODO: how do we prevent errors in the filesystem from compromising the machine
- FSType string `json:"fsType,omitempty" protobuf:"bytes,3,opt,name=fsType"`
- // Optional: Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"`
-}
-
-// AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
-type AzureFileVolumeSource struct {
- // the name of secret that contains Azure Storage Account Name and Key
- SecretName string `json:"secretName" protobuf:"bytes,1,opt,name=secretName"`
- // Share Name
- ShareName string `json:"shareName" protobuf:"bytes,2,opt,name=shareName"`
- // Defaults to false (read/write). ReadOnly here will force
- // the ReadOnly setting in VolumeMounts.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"`
-}
-
-// Represents a vSphere volume resource.
-type VsphereVirtualDiskVolumeSource struct {
- // Path that identifies vSphere volume vmdk
- VolumePath string `json:"volumePath" protobuf:"bytes,1,opt,name=volumePath"`
- // Filesystem type to mount.
- // Must be a filesystem type supported by the host operating system.
- // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
- FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"`
-}
-
-// Adapts a ConfigMap into a volume.
-//
-// The contents of the target ConfigMap's Data field will be presented in a
-// volume as files using the keys in the Data field as the file names, unless
-// the items element is populated with specific mappings of keys to paths.
-// ConfigMap volumes support ownership management and SELinux relabeling.
-type ConfigMapVolumeSource struct {
- LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"`
- // If unspecified, each key-value pair in the Data field of the referenced
- // ConfigMap will be projected into the volume as a file whose name is the
- // key and content is the value. If specified, the listed keys will be
- // projected into the specified paths, and unlisted keys will not be
- // present. If a key is specified which is not present in the ConfigMap,
- // the volume setup will error. Paths must be relative and may not contain
- // the '..' path or start with '..'.
- Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"`
-}
-
-// Maps a string key to a path within a volume.
-type KeyToPath struct {
- // The key to project.
- Key string `json:"key" protobuf:"bytes,1,opt,name=key"`
-
- // The relative path of the file to map the key to.
- // May not be an absolute path.
- // May not contain the path element '..'.
- // May not start with the string '..'.
- Path string `json:"path" protobuf:"bytes,2,opt,name=path"`
-}
-
-// ContainerPort represents a network port in a single container.
-type ContainerPort struct {
- // If specified, this must be an IANA_SVC_NAME and unique within the pod. Each
- // named port in a pod must have a unique name. Name for the port that can be
- // referred to by services.
- Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
- // Number of port to expose on the host.
- // If specified, this must be a valid port number, 0 < x < 65536.
- // If HostNetwork is specified, this must match ContainerPort.
- // Most containers do not need this.
- HostPort int32 `json:"hostPort,omitempty" protobuf:"varint,2,opt,name=hostPort"`
- // Number of port to expose on the pod's IP address.
- // This must be a valid port number, 0 < x < 65536.
- ContainerPort int32 `json:"containerPort" protobuf:"varint,3,opt,name=containerPort"`
- // Protocol for port. Must be UDP or TCP.
- // Defaults to "TCP".
- Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,4,opt,name=protocol,casttype=Protocol"`
- // What host IP to bind the external port to.
- HostIP string `json:"hostIP,omitempty" protobuf:"bytes,5,opt,name=hostIP"`
-}
-
-// VolumeMount describes a mounting of a Volume within a container.
-type VolumeMount struct {
- // This must match the Name of a Volume.
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
- // Mounted read-only if true, read-write otherwise (false or unspecified).
- // Defaults to false.
- ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,2,opt,name=readOnly"`
- // Path within the container at which the volume should be mounted. Must
- // not contain ':'.
- MountPath string `json:"mountPath" protobuf:"bytes,3,opt,name=mountPath"`
- // Path within the volume from which the container's volume should be mounted.
- // Defaults to "" (volume's root).
- SubPath string `json:"subPath,omitempty" protobuf:"bytes,4,opt,name=subPath"`
-}
-
-// EnvVar represents an environment variable present in a Container.
-type EnvVar struct {
- // Name of the environment variable. Must be a C_IDENTIFIER.
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
-
- // Optional: no more than one of the following may be specified.
-
- // Variable references $(VAR_NAME) are expanded
- // using the previous defined environment variables in the container and
- // any service environment variables. If a variable cannot be resolved,
- // the reference in the input string will be unchanged. The $(VAR_NAME)
- // syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped
- // references will never be expanded, regardless of whether the variable
- // exists or not.
- // Defaults to "".
- Value string `json:"value,omitempty" protobuf:"bytes,2,opt,name=value"`
- // Source for the environment variable's value. Cannot be used if value is not empty.
- ValueFrom *EnvVarSource `json:"valueFrom,omitempty" protobuf:"bytes,3,opt,name=valueFrom"`
-}
-
-// EnvVarSource represents a source for the value of an EnvVar.
-type EnvVarSource struct {
- // Selects a field of the pod; only name and namespace are supported.
- FieldRef *ObjectFieldSelector `json:"fieldRef,omitempty" protobuf:"bytes,1,opt,name=fieldRef"`
- // Selects a resource of the container: only resources limits and requests
- // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.
- ResourceFieldRef *ResourceFieldSelector `json:"resourceFieldRef,omitempty" protobuf:"bytes,2,opt,name=resourceFieldRef"`
- // Selects a key of a ConfigMap.
- ConfigMapKeyRef *ConfigMapKeySelector `json:"configMapKeyRef,omitempty" protobuf:"bytes,3,opt,name=configMapKeyRef"`
- // Selects a key of a secret in the pod's namespace
- SecretKeyRef *SecretKeySelector `json:"secretKeyRef,omitempty" protobuf:"bytes,4,opt,name=secretKeyRef"`
-}
-
-// ObjectFieldSelector selects an APIVersioned field of an object.
-type ObjectFieldSelector struct {
- // Version of the schema the FieldPath is written in terms of, defaults to "v1".
- APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,1,opt,name=apiVersion"`
- // Path of the field to select in the specified API version.
- FieldPath string `json:"fieldPath" protobuf:"bytes,2,opt,name=fieldPath"`
-}
-
-// ResourceFieldSelector represents container resources (cpu, memory) and their output format
-type ResourceFieldSelector struct {
- // Container name: required for volumes, optional for env vars
- ContainerName string `json:"containerName,omitempty" protobuf:"bytes,1,opt,name=containerName"`
- // Required: resource to select
- Resource string `json:"resource" protobuf:"bytes,2,opt,name=resource"`
- // Specifies the output format of the exposed resources, defaults to "1"
- Divisor resource.Quantity `json:"divisor,omitempty" protobuf:"bytes,3,opt,name=divisor"`
-}
-
-// Selects a key from a ConfigMap.
-type ConfigMapKeySelector struct {
- // The ConfigMap to select from.
- LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"`
- // The key to select.
- Key string `json:"key" protobuf:"bytes,2,opt,name=key"`
-}
-
-// SecretKeySelector selects a key of a Secret.
-type SecretKeySelector struct {
- // The name of the secret in the pod's namespace to select from.
- LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"`
- // The key of the secret to select from. Must be a valid secret key.
- Key string `json:"key" protobuf:"bytes,2,opt,name=key"`
-}
-
-// HTTPHeader describes a custom header to be used in HTTP probes
-type HTTPHeader struct {
- // The header field name
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
- // The header field value
- Value string `json:"value" protobuf:"bytes,2,opt,name=value"`
-}
-
-// HTTPGetAction describes an action based on HTTP Get requests.
-type HTTPGetAction struct {
- // Path to access on the HTTP server.
- Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"`
- // Name or number of the port to access on the container.
- // Number must be in the range 1 to 65535.
- // Name must be an IANA_SVC_NAME.
- Port intstr.IntOrString `json:"port" protobuf:"bytes,2,opt,name=port"`
- // Host name to connect to, defaults to the pod IP. You probably want to set
- // "Host" in httpHeaders instead.
- Host string `json:"host,omitempty" protobuf:"bytes,3,opt,name=host"`
- // Scheme to use for connecting to the host.
- // Defaults to HTTP.
- Scheme URIScheme `json:"scheme,omitempty" protobuf:"bytes,4,opt,name=scheme,casttype=URIScheme"`
- // Custom headers to set in the request. HTTP allows repeated headers.
- HTTPHeaders []HTTPHeader `json:"httpHeaders,omitempty" protobuf:"bytes,5,rep,name=httpHeaders"`
-}
-
-// URIScheme identifies the scheme used for connection to a host for Get actions
-type URIScheme string
-
-const (
- // URISchemeHTTP means that the scheme used will be http://
- URISchemeHTTP URIScheme = "HTTP"
- // URISchemeHTTPS means that the scheme used will be https://
- URISchemeHTTPS URIScheme = "HTTPS"
-)
-
-// TCPSocketAction describes an action based on opening a socket
-type TCPSocketAction struct {
- // Number or name of the port to access on the container.
- // Number must be in the range 1 to 65535.
- // Name must be an IANA_SVC_NAME.
- Port intstr.IntOrString `json:"port" protobuf:"bytes,1,opt,name=port"`
-}
-
-// ExecAction describes a "run in container" action.
-type ExecAction struct {
- // Command is the command line to execute inside the container, the working directory for the
- // command is root ('/') in the container's filesystem. The command is simply exec'd, it is
- // not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use
- // a shell, you need to explicitly call out to that shell.
- // Exit status of 0 is treated as live/healthy and non-zero is unhealthy.
- Command []string `json:"command,omitempty" protobuf:"bytes,1,rep,name=command"`
-}
-
-// Probe describes a health check to be performed against a container to determine whether it is
-// alive or ready to receive traffic.
-type Probe struct {
- // The action taken to determine the health of a container
- Handler `json:",inline" protobuf:"bytes,1,opt,name=handler"`
- // Number of seconds after the container has started before liveness probes are initiated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- InitialDelaySeconds int32 `json:"initialDelaySeconds,omitempty" protobuf:"varint,2,opt,name=initialDelaySeconds"`
- // Number of seconds after which the probe times out.
- // Defaults to 1 second. Minimum value is 1.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- TimeoutSeconds int32 `json:"timeoutSeconds,omitempty" protobuf:"varint,3,opt,name=timeoutSeconds"`
- // How often (in seconds) to perform the probe.
- // Default to 10 seconds. Minimum value is 1.
- PeriodSeconds int32 `json:"periodSeconds,omitempty" protobuf:"varint,4,opt,name=periodSeconds"`
- // Minimum consecutive successes for the probe to be considered successful after having failed.
- // Defaults to 1. Must be 1 for liveness. Minimum value is 1.
- SuccessThreshold int32 `json:"successThreshold,omitempty" protobuf:"varint,5,opt,name=successThreshold"`
- // Minimum consecutive failures for the probe to be considered failed after having succeeded.
- // Defaults to 3. Minimum value is 1.
- FailureThreshold int32 `json:"failureThreshold,omitempty" protobuf:"varint,6,opt,name=failureThreshold"`
-}
-
-// PullPolicy describes a policy for if/when to pull a container image
-type PullPolicy string
-
-const (
- // PullAlways means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.
- PullAlways PullPolicy = "Always"
- // PullNever means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present
- PullNever PullPolicy = "Never"
- // PullIfNotPresent means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.
- PullIfNotPresent PullPolicy = "IfNotPresent"
-)
-
-// Capability represent POSIX capabilities type
-type Capability string
-
-// Adds and removes POSIX capabilities from running containers.
-type Capabilities struct {
- // Added capabilities
- Add []Capability `json:"add,omitempty" protobuf:"bytes,1,rep,name=add,casttype=Capability"`
- // Removed capabilities
- Drop []Capability `json:"drop,omitempty" protobuf:"bytes,2,rep,name=drop,casttype=Capability"`
-}
-
-// ResourceRequirements describes the compute resource requirements.
-type ResourceRequirements struct {
- // Limits describes the maximum amount of compute resources allowed.
- // More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications
- Limits ResourceList `json:"limits,omitempty" protobuf:"bytes,1,rep,name=limits,casttype=ResourceList,castkey=ResourceName"`
- // Requests describes the minimum amount of compute resources required.
- // If Requests is omitted for a container, it defaults to Limits if that is explicitly specified,
- // otherwise to an implementation-defined value.
- // More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications
- Requests ResourceList `json:"requests,omitempty" protobuf:"bytes,2,rep,name=requests,casttype=ResourceList,castkey=ResourceName"`
-}
-
-const (
- // TerminationMessagePathDefault means the default path to capture the application termination message running in a container
- TerminationMessagePathDefault string = "/dev/termination-log"
-)
-
-// A single application container that you want to run within a pod.
-type Container struct {
- // Name of the container specified as a DNS_LABEL.
- // Each container in a pod must have a unique name (DNS_LABEL).
- // Cannot be updated.
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
- // Docker image name.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md
- Image string `json:"image,omitempty" protobuf:"bytes,2,opt,name=image"`
- // Entrypoint array. Not executed within a shell.
- // The docker image's ENTRYPOINT is used if this is not provided.
- // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
- // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
- // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
- // regardless of whether the variable exists or not.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands
- Command []string `json:"command,omitempty" protobuf:"bytes,3,rep,name=command"`
- // Arguments to the entrypoint.
- // The docker image's CMD is used if this is not provided.
- // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
- // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
- // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
- // regardless of whether the variable exists or not.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands
- Args []string `json:"args,omitempty" protobuf:"bytes,4,rep,name=args"`
- // Container's working directory.
- // If not specified, the container runtime's default will be used, which
- // might be configured in the container image.
- // Cannot be updated.
- WorkingDir string `json:"workingDir,omitempty" protobuf:"bytes,5,opt,name=workingDir"`
- // List of ports to expose from the container. Exposing a port here gives
- // the system additional information about the network connections a
- // container uses, but is primarily informational. Not specifying a port here
- // DOES NOT prevent that port from being exposed. Any port which is
- // listening on the default "0.0.0.0" address inside a container will be
- // accessible from the network.
- // Cannot be updated.
- Ports []ContainerPort `json:"ports,omitempty" patchStrategy:"merge" patchMergeKey:"containerPort" protobuf:"bytes,6,rep,name=ports"`
- // List of environment variables to set in the container.
- // Cannot be updated.
- Env []EnvVar `json:"env,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,7,rep,name=env"`
- // Compute Resources required by this container.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources
- Resources ResourceRequirements `json:"resources,omitempty" protobuf:"bytes,8,opt,name=resources"`
- // Pod volumes to mount into the container's filesystem.
- // Cannot be updated.
- VolumeMounts []VolumeMount `json:"volumeMounts,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,9,rep,name=volumeMounts"`
- // Periodic probe of container liveness.
- // Container will be restarted if the probe fails.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- LivenessProbe *Probe `json:"livenessProbe,omitempty" protobuf:"bytes,10,opt,name=livenessProbe"`
- // Periodic probe of container service readiness.
- // Container will be removed from service endpoints if the probe fails.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes
- ReadinessProbe *Probe `json:"readinessProbe,omitempty" protobuf:"bytes,11,opt,name=readinessProbe"`
- // Actions that the management system should take in response to container lifecycle events.
- // Cannot be updated.
- Lifecycle *Lifecycle `json:"lifecycle,omitempty" protobuf:"bytes,12,opt,name=lifecycle"`
- // Optional: Path at which the file to which the container's termination message
- // will be written is mounted into the container's filesystem.
- // Message written is intended to be brief final status, such as an assertion failure message.
- // Defaults to /dev/termination-log.
- // Cannot be updated.
- TerminationMessagePath string `json:"terminationMessagePath,omitempty" protobuf:"bytes,13,opt,name=terminationMessagePath"`
- // Image pull policy.
- // One of Always, Never, IfNotPresent.
- // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#updating-images
- ImagePullPolicy PullPolicy `json:"imagePullPolicy,omitempty" protobuf:"bytes,14,opt,name=imagePullPolicy,casttype=PullPolicy"`
- // Security options the pod should run with.
- // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md
- SecurityContext *SecurityContext `json:"securityContext,omitempty" protobuf:"bytes,15,opt,name=securityContext"`
-
- // Variables for interactive containers, these have very specialized use-cases (e.g. debugging)
- // and shouldn't be used for general purpose containers.
-
- // Whether this container should allocate a buffer for stdin in the container runtime. If this
- // is not set, reads from stdin in the container will always result in EOF.
- // Default is false.
- Stdin bool `json:"stdin,omitempty" protobuf:"varint,16,opt,name=stdin"`
- // Whether the container runtime should close the stdin channel after it has been opened by
- // a single attach. When stdin is true the stdin stream will remain open across multiple attach
- // sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the
- // first client attaches to stdin, and then remains open and accepts data until the client disconnects,
- // at which time stdin is closed and remains closed until the container is restarted. If this
- // flag is false, a container processes that reads from stdin will never receive an EOF.
- // Default is false
- StdinOnce bool `json:"stdinOnce,omitempty" protobuf:"varint,17,opt,name=stdinOnce"`
- // Whether this container should allocate a TTY for itself, also requires 'stdin' to be true.
- // Default is false.
- TTY bool `json:"tty,omitempty" protobuf:"varint,18,opt,name=tty"`
-}
-
-// Handler defines a specific action that should be taken
-// TODO: pass structured data to these actions, and document that data here.
-type Handler struct {
- // One and only one of the following should be specified.
- // Exec specifies the action to take.
- Exec *ExecAction `json:"exec,omitempty" protobuf:"bytes,1,opt,name=exec"`
- // HTTPGet specifies the http request to perform.
- HTTPGet *HTTPGetAction `json:"httpGet,omitempty" protobuf:"bytes,2,opt,name=httpGet"`
- // TCPSocket specifies an action involving a TCP port.
- // TCP hooks not yet supported
- // TODO: implement a realistic TCP lifecycle hook
- TCPSocket *TCPSocketAction `json:"tcpSocket,omitempty" protobuf:"bytes,3,opt,name=tcpSocket"`
-}
-
-// Lifecycle describes actions that the management system should take in response to container lifecycle
-// events. For the PostStart and PreStop lifecycle handlers, management of the container blocks
-// until the action is complete, unless the container process fails, in which case the handler is aborted.
-type Lifecycle struct {
- // PostStart is called immediately after a container is created. If the handler fails,
- // the container is terminated and restarted according to its restart policy.
- // Other management of the container blocks until the hook completes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details
- PostStart *Handler `json:"postStart,omitempty" protobuf:"bytes,1,opt,name=postStart"`
- // PreStop is called immediately before a container is terminated.
- // The container is terminated after the handler completes.
- // The reason for termination is passed to the handler.
- // Regardless of the outcome of the handler, the container is eventually terminated.
- // Other management of the container blocks until the hook completes.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details
- PreStop *Handler `json:"preStop,omitempty" protobuf:"bytes,2,opt,name=preStop"`
-}
-
-type ConditionStatus string
-
-// These are valid condition statuses. "ConditionTrue" means a resource is in the condition.
-// "ConditionFalse" means a resource is not in the condition. "ConditionUnknown" means kubernetes
-// can't decide if a resource is in the condition or not. In the future, we could add other
-// intermediate conditions, e.g. ConditionDegraded.
-const (
- ConditionTrue ConditionStatus = "True"
- ConditionFalse ConditionStatus = "False"
- ConditionUnknown ConditionStatus = "Unknown"
-)
-
-// ContainerStateWaiting is a waiting state of a container.
-type ContainerStateWaiting struct {
- // (brief) reason the container is not yet running.
- Reason string `json:"reason,omitempty" protobuf:"bytes,1,opt,name=reason"`
- // Message regarding why the container is not yet running.
- Message string `json:"message,omitempty" protobuf:"bytes,2,opt,name=message"`
-}
-
-// ContainerStateRunning is a running state of a container.
-type ContainerStateRunning struct {
- // Time at which the container was last (re-)started
- StartedAt unversioned.Time `json:"startedAt,omitempty" protobuf:"bytes,1,opt,name=startedAt"`
-}
-
-// ContainerStateTerminated is a terminated state of a container.
-type ContainerStateTerminated struct {
- // Exit status from the last termination of the container
- ExitCode int32 `json:"exitCode" protobuf:"varint,1,opt,name=exitCode"`
- // Signal from the last termination of the container
- Signal int32 `json:"signal,omitempty" protobuf:"varint,2,opt,name=signal"`
- // (brief) reason from the last termination of the container
- Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"`
- // Message regarding the last termination of the container
- Message string `json:"message,omitempty" protobuf:"bytes,4,opt,name=message"`
- // Time at which previous execution of the container started
- StartedAt unversioned.Time `json:"startedAt,omitempty" protobuf:"bytes,5,opt,name=startedAt"`
- // Time at which the container last terminated
- FinishedAt unversioned.Time `json:"finishedAt,omitempty" protobuf:"bytes,6,opt,name=finishedAt"`
- // Container's ID in the format 'docker://<container_id>'
- ContainerID string `json:"containerID,omitempty" protobuf:"bytes,7,opt,name=containerID"`
-}
-
-// ContainerState holds a possible state of container.
-// Only one of its members may be specified.
-// If none of them is specified, the default one is ContainerStateWaiting.
-type ContainerState struct {
- // Details about a waiting container
- Waiting *ContainerStateWaiting `json:"waiting,omitempty" protobuf:"bytes,1,opt,name=waiting"`
- // Details about a running container
- Running *ContainerStateRunning `json:"running,omitempty" protobuf:"bytes,2,opt,name=running"`
- // Details about a terminated container
- Terminated *ContainerStateTerminated `json:"terminated,omitempty" protobuf:"bytes,3,opt,name=terminated"`
-}
-
-// ContainerStatus contains details for the current status of this container.
-type ContainerStatus struct {
- // This must be a DNS_LABEL. Each container in a pod must have a unique name.
- // Cannot be updated.
- Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
- // Details about the container's current condition.
- State ContainerState `json:"state,omitempty" protobuf:"bytes,2,opt,name=state"`
- // Details about the container's last termination condition.
- LastTerminationState ContainerState `json:"lastState,omitempty" protobuf:"bytes,3,opt,name=lastState"`
- // Specifies whether the container has passed its readiness probe.
- Ready bool `json:"ready" protobuf:"varint,4,opt,name=ready"`
- // The number of times the container has been restarted, currently based on
- // the number of dead containers that have not yet been removed.
- // Note that this is calculated from dead containers. But those containers are subject to
- // garbage collection. This value will get capped at 5 by GC.
- RestartCount int32 `json:"restartCount" protobuf:"varint,5,opt,name=restartCount"`
- // The image the container is running.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md
- // TODO(dchen1107): Which image the container is running with?
- Image string `json:"image" protobuf:"bytes,6,opt,name=image"`
- // ImageID of the container's image.
- ImageID string `json:"imageID" protobuf:"bytes,7,opt,name=imageID"`
- // Container's ID in the format 'docker://<container_id>'.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#container-information
- ContainerID string `json:"containerID,omitempty" protobuf:"bytes,8,opt,name=containerID"`
-}
-
-// PodPhase is a label for the condition of a pod at the current time.
-type PodPhase string
-
-// These are the valid statuses of pods.
-const (
- // PodPending means the pod has been accepted by the system, but one or more of the containers
- // has not been started. This includes time before being bound to a node, as well as time spent
- // pulling images onto the host.
- PodPending PodPhase = "Pending"
- // PodRunning means the pod has been bound to a node and all of the containers have been started.
- // At least one container is still running or is in the process of being restarted.
- PodRunning PodPhase = "Running"
- // PodSucceeded means that all containers in the pod have voluntarily terminated
- // with a container exit code of 0, and the system is not going to restart any of these containers.
- PodSucceeded PodPhase = "Succeeded"
- // PodFailed means that all containers in the pod have terminated, and at least one container has
- // terminated in a failure (exited with a non-zero exit code or was stopped by the system).
- PodFailed PodPhase = "Failed"
- // PodUnknown means that for some reason the state of the pod could not be obtained, typically due
- // to an error in communicating with the host of the pod.
- PodUnknown PodPhase = "Unknown"
-)
-
-// PodConditionType is a valid value for PodCondition.Type
-type PodConditionType string
-
-// These are valid conditions of pod.
-const (
- // PodScheduled represents status of the scheduling process for this pod.
- PodScheduled PodConditionType = "PodScheduled"
- // PodReady means the pod is able to service requests and should be added to the
- // load balancing pools of all matching services.
- PodReady PodConditionType = "Ready"
-)
-
-// PodCondition contains details for the current condition of this pod.
-type PodCondition struct {
- // Type is the type of the condition.
- // Currently only Ready.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- Type PodConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=PodConditionType"`
- // Status is the status of the condition.
- // Can be True, False, Unknown.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"`
- // Last time we probed the condition.
- LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"`
- // Last time the condition transitioned from one status to another.
- LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"`
- // Unique, one-word, CamelCase reason for the condition's last transition.
- Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"`
- // Human-readable message indicating details about last transition.
- Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"`
-}
-
-// RestartPolicy describes how the container should be restarted.
-// Only one of the following restart policies may be specified.
-// If none of the following policies is specified, the default one
-// is RestartPolicyAlways.
-type RestartPolicy string
-
-const (
- RestartPolicyAlways RestartPolicy = "Always"
- RestartPolicyOnFailure RestartPolicy = "OnFailure"
- RestartPolicyNever RestartPolicy = "Never"
-)
-
-// DNSPolicy defines how a pod's DNS will be configured.
-type DNSPolicy string
-
-const (
- // DNSClusterFirst indicates that the pod should use cluster DNS
- // first, if it is available, then fall back on the default (as
- // determined by kubelet) DNS settings.
- DNSClusterFirst DNSPolicy = "ClusterFirst"
-
- // DNSDefault indicates that the pod should use the default (as
- // determined by kubelet) DNS settings.
- DNSDefault DNSPolicy = "Default"
-
- DefaultTerminationGracePeriodSeconds = 30
-)
-
-// A node selector represents the union of the results of one or more label queries
-// over a set of nodes; that is, it represents the OR of the selectors represented
-// by the node selector terms.
-type NodeSelector struct {
- //Required. A list of node selector terms. The terms are ORed.
- NodeSelectorTerms []NodeSelectorTerm `json:"nodeSelectorTerms" protobuf:"bytes,1,rep,name=nodeSelectorTerms"`
-}
-
-// A null or empty node selector term matches no objects.
-type NodeSelectorTerm struct {
- //Required. A list of node selector requirements. The requirements are ANDed.
- MatchExpressions []NodeSelectorRequirement `json:"matchExpressions" protobuf:"bytes,1,rep,name=matchExpressions"`
-}
-
-// A node selector requirement is a selector that contains values, a key, and an operator
-// that relates the key and values.
-type NodeSelectorRequirement struct {
- // The label key that the selector applies to.
- Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
- // Represents a key's relationship to a set of values.
- // Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.
- Operator NodeSelectorOperator `json:"operator" protobuf:"bytes,2,opt,name=operator,casttype=NodeSelectorOperator"`
- // An array of string values. If the operator is In or NotIn,
- // the values array must be non-empty. If the operator is Exists or DoesNotExist,
- // the values array must be empty. If the operator is Gt or Lt, the values
- // array must have a single element, which will be interpreted as an integer.
- // This array is replaced during a strategic merge patch.
- Values []string `json:"values,omitempty" protobuf:"bytes,3,rep,name=values"`
-}
-
-// A node selector operator is the set of operators that can be used in
-// a node selector requirement.
-type NodeSelectorOperator string
-
-const (
- NodeSelectorOpIn NodeSelectorOperator = "In"
- NodeSelectorOpNotIn NodeSelectorOperator = "NotIn"
- NodeSelectorOpExists NodeSelectorOperator = "Exists"
- NodeSelectorOpDoesNotExist NodeSelectorOperator = "DoesNotExist"
- NodeSelectorOpGt NodeSelectorOperator = "Gt"
- NodeSelectorOpLt NodeSelectorOperator = "Lt"
-)
-
-// Affinity is a group of affinity scheduling rules.
-type Affinity struct {
- // Describes node affinity scheduling rules for the pod.
- NodeAffinity *NodeAffinity `json:"nodeAffinity,omitempty" protobuf:"bytes,1,opt,name=nodeAffinity"`
- // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).
- PodAffinity *PodAffinity `json:"podAffinity,omitempty" protobuf:"bytes,2,opt,name=podAffinity"`
- // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).
- PodAntiAffinity *PodAntiAffinity `json:"podAntiAffinity,omitempty" protobuf:"bytes,3,opt,name=podAntiAffinity"`
-}
-
-// Pod affinity is a group of inter pod affinity scheduling rules.
-type PodAffinity struct {
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system will try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"`
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system may or may not try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,1,rep,name=requiredDuringSchedulingIgnoredDuringExecution"`
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
- // node(s) with the highest sum are the most preferred.
- PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,2,rep,name=preferredDuringSchedulingIgnoredDuringExecution"`
-}
-
-// Pod anti affinity is a group of inter pod anti affinity scheduling rules.
-type PodAntiAffinity struct {
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // If the anti-affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the anti-affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system will try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"`
- // If the anti-affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the anti-affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to a pod label update), the
- // system may or may not try to eventually evict the pod from its node.
- // When there are multiple elements, the lists of nodes corresponding to each
- // podAffinityTerm are intersected, i.e. all terms must be satisfied.
- RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,1,rep,name=requiredDuringSchedulingIgnoredDuringExecution"`
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the anti-affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling anti-affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
- // node(s) with the highest sum are the most preferred.
- PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,2,rep,name=preferredDuringSchedulingIgnoredDuringExecution"`
-}
-
-// The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)
-type WeightedPodAffinityTerm struct {
- // weight associated with matching the corresponding podAffinityTerm,
- // in the range 1-100.
- Weight int32 `json:"weight" protobuf:"varint,1,opt,name=weight"`
- // Required. A pod affinity term, associated with the corresponding weight.
- PodAffinityTerm PodAffinityTerm `json:"podAffinityTerm" protobuf:"bytes,2,opt,name=podAffinityTerm"`
-}
-
-// Defines a set of pods (namely those matching the labelSelector
-// relative to the given namespace(s)) that this pod should be
-// co-located (affinity) or not co-located (anti-affinity) with,
-// where co-located is defined as running on a node whose value of
-// the label with key <topologyKey> tches that of any node on which
-// a pod of the set of pods is running
-type PodAffinityTerm struct {
- // A label query over a set of resources, in this case pods.
- LabelSelector *unversioned.LabelSelector `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"`
- // namespaces specifies which namespaces the labelSelector applies to (matches against);
- // nil list means "this pod's namespace," empty list means "all namespaces"
- // The json tag here is not "omitempty" since we need to distinguish nil and empty.
- // See https://golang.org/pkg/encoding/json/#Marshal for more details.
- Namespaces []string `json:"namespaces" protobuf:"bytes,2,rep,name=namespaces"`
- // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
- // the labelSelector in the specified namespaces, where co-located is defined as running on a node
- // whose value of the label with key topologyKey matches that of any node on which any of the
- // selected pods is running.
- // For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies"
- // ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains);
- // for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed.
- TopologyKey string `json:"topologyKey,omitempty" protobuf:"bytes,3,opt,name=topologyKey"`
-}
-
-// Node affinity is a group of node affinity scheduling rules.
-type NodeAffinity struct {
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to an update), the system
- // will try to eventually evict the pod from its node.
- // RequiredDuringSchedulingRequiredDuringExecution *NodeSelector `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"`
-
- // If the affinity requirements specified by this field are not met at
- // scheduling time, the pod will not be scheduled onto the node.
- // If the affinity requirements specified by this field cease to be met
- // at some point during pod execution (e.g. due to an update), the system
- // may or may not try to eventually evict the pod from its node.
- RequiredDuringSchedulingIgnoredDuringExecution *NodeSelector `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,1,opt,name=requiredDuringSchedulingIgnoredDuringExecution"`
- // The scheduler will prefer to schedule pods to nodes that satisfy
- // the affinity expressions specified by this field, but it may choose
- // a node that violates one or more of the expressions. The node that is
- // most preferred is the one with the greatest sum of weights, i.e.
- // for each node that meets all of the scheduling requirements (resource
- // request, requiredDuringScheduling affinity expressions, etc.),
- // compute a sum by iterating through the elements of this field and adding
- // "weight" to the sum if the node matches the corresponding matchExpressions; the
- // node(s) with the highest sum are the most preferred.
- PreferredDuringSchedulingIgnoredDuringExecution []PreferredSchedulingTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty" protobuf:"bytes,2,rep,name=preferredDuringSchedulingIgnoredDuringExecution"`
-}
-
-// An empty preferred scheduling term matches all objects with implicit weight 0
-// (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).
-type PreferredSchedulingTerm struct {
- // Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.
- Weight int32 `json:"weight" protobuf:"varint,1,opt,name=weight"`
- // A node selector term, associated with the corresponding weight.
- Preference NodeSelectorTerm `json:"preference" protobuf:"bytes,2,opt,name=preference"`
-}
-
-// The node this Taint is attached to has the effect "effect" on
-// any pod that that does not tolerate the Taint.
-type Taint struct {
- // Required. The taint key to be applied to a node.
- Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
- // Required. The taint value corresponding to the taint key.
- Value string `json:"value,omitempty" protobuf:"bytes,2,opt,name=value"`
- // Required. The effect of the taint on pods
- // that do not tolerate the taint.
- // Valid effects are NoSchedule and PreferNoSchedule.
- Effect TaintEffect `json:"effect" protobuf:"bytes,3,opt,name=effect,casttype=TaintEffect"`
-}
-
-type TaintEffect string
-
-const (
- // Do not allow new pods to schedule onto the node unless they tolerate the taint,
- // but allow all pods submitted to Kubelet without going through the scheduler
- // to start, and allow all already-running pods to continue running.
- // Enforced by the scheduler.
- TaintEffectNoSchedule TaintEffect = "NoSchedule"
- // Like TaintEffectNoSchedule, but the scheduler tries not to schedule
- // new pods onto the node, rather than prohibiting new pods from scheduling
- // onto the node entirely. Enforced by the scheduler.
- TaintEffectPreferNoSchedule TaintEffect = "PreferNoSchedule"
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // Do not allow new pods to schedule onto the node unless they tolerate the taint,
- // do not allow pods to start on Kubelet unless they tolerate the taint,
- // but allow all already-running pods to continue running.
- // Enforced by the scheduler and Kubelet.
- // TaintEffectNoScheduleNoAdmit TaintEffect = "NoScheduleNoAdmit"
- // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented.
- // Do not allow new pods to schedule onto the node unless they tolerate the taint,
- // do not allow pods to start on Kubelet unless they tolerate the taint,
- // and evict any already-running pods that do not tolerate the taint.
- // Enforced by the scheduler and Kubelet.
- // TaintEffectNoScheduleNoAdmitNoExecute = "NoScheduleNoAdmitNoExecute"
-)
-
-// The pod this Toleration is attached to tolerates any taint that matches
-// the triple <key,value,effect> using the matching operator <operator>.
-type Toleration struct {
- // Required. Key is the taint key that the toleration applies to.
- Key string `json:"key,omitempty" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
- // operator represents a key's relationship to the value.
- // Valid operators are Exists and Equal. Defaults to Equal.
- // Exists is equivalent to wildcard for value, so that a pod can
- // tolerate all taints of a particular category.
- Operator TolerationOperator `json:"operator,omitempty" protobuf:"bytes,2,opt,name=operator,casttype=TolerationOperator"`
- // Value is the taint value the toleration matches to.
- // If the operator is Exists, the value should be empty, otherwise just a regular string.
- Value string `json:"value,omitempty" protobuf:"bytes,3,opt,name=value"`
- // Effect indicates the taint effect to match. Empty means match all taint effects.
- // When specified, allowed values are NoSchedule and PreferNoSchedule.
- Effect TaintEffect `json:"effect,omitempty" protobuf:"bytes,4,opt,name=effect,casttype=TaintEffect"`
- // TODO: For forgiveness (#1574), we'd eventually add at least a grace period
- // here, and possibly an occurrence threshold and period.
-}
-
-// A toleration operator is the set of operators that can be used in a toleration.
-type TolerationOperator string
-
-const (
- TolerationOpExists TolerationOperator = "Exists"
- TolerationOpEqual TolerationOperator = "Equal"
-)
-
-const (
- // This annotation key will be used to contain an array of v1 JSON encoded Containers
- // for init containers. The annotation will be placed into the internal type and cleared.
- PodInitContainersAnnotationKey = "pod.alpha.kubernetes.io/init-containers"
- // This annotation key will be used to contain an array of v1 JSON encoded
- // ContainerStatuses for init containers. The annotation will be placed into the internal
- // type and cleared.
- PodInitContainerStatusesAnnotationKey = "pod.alpha.kubernetes.io/init-container-statuses"
-)
-
-// PodSpec is a description of a pod.
-type PodSpec struct {
- // List of volumes that can be mounted by containers belonging to the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md
- Volumes []Volume `json:"volumes,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,1,rep,name=volumes"`
- // List of initialization containers belonging to the pod.
- // Init containers are executed in order prior to containers being started. If any
- // init container fails, the pod is considered to have failed and is handled according
- // to its restartPolicy. The name for an init container or normal container must be
- // unique among all containers.
- // Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes.
- // The resourceRequirements of an init container are taken into account during scheduling
- // by finding the highest request/limit for each resource type, and then using the max of
- // of that value or the sum of the normal containers. Limits are applied to init containers
- // in a similar fashion.
- // Init containers cannot currently be added or removed.
- // Init containers are in alpha state and may change without notice.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md
- InitContainers []Container `json:"-" patchStrategy:"merge" patchMergeKey:"name"`
- // List of containers belonging to the pod.
- // Containers cannot currently be added or removed.
- // There must be at least one container in a Pod.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md
- Containers []Container `json:"containers" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=containers"`
- // Restart policy for all containers within the pod.
- // One of Always, OnFailure, Never.
- // Default to Always.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#restartpolicy
- RestartPolicy RestartPolicy `json:"restartPolicy,omitempty" protobuf:"bytes,3,opt,name=restartPolicy,casttype=RestartPolicy"`
- // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request.
- // Value must be non-negative integer. The value zero indicates delete immediately.
- // If this value is nil, the default grace period will be used instead.
- // The grace period is the duration in seconds after the processes running in the pod are sent
- // a termination signal and the time when the processes are forcibly halted with a kill signal.
- // Set this value longer than the expected cleanup time for your process.
- // Defaults to 30 seconds.
- TerminationGracePeriodSeconds *int64 `json:"terminationGracePeriodSeconds,omitempty" protobuf:"varint,4,opt,name=terminationGracePeriodSeconds"`
- // Optional duration in seconds the pod may be active on the node relative to
- // StartTime before the system will actively try to mark it failed and kill associated containers.
- // Value must be a positive integer.
- ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,5,opt,name=activeDeadlineSeconds"`
- // Set DNS policy for containers within the pod.
- // One of 'ClusterFirst' or 'Default'.
- // Defaults to "ClusterFirst".
- DNSPolicy DNSPolicy `json:"dnsPolicy,omitempty" protobuf:"bytes,6,opt,name=dnsPolicy,casttype=DNSPolicy"`
- // NodeSelector is a selector which must be true for the pod to fit on a node.
- // Selector which must match a node's labels for the pod to be scheduled on that node.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/node-selection/README.md
- NodeSelector map[string]string `json:"nodeSelector,omitempty" protobuf:"bytes,7,rep,name=nodeSelector"`
-
- // ServiceAccountName is the name of the ServiceAccount to use to run this pod.
- // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md
- ServiceAccountName string `json:"serviceAccountName,omitempty" protobuf:"bytes,8,opt,name=serviceAccountName"`
- // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName.
- // Deprecated: Use serviceAccountName instead.
- // +k8s:conversion-gen=false
- DeprecatedServiceAccount string `json:"serviceAccount,omitempty" protobuf:"bytes,9,opt,name=serviceAccount"`
-
- // NodeName is a request to schedule this pod onto a specific node. If it is non-empty,
- // the scheduler simply schedules this pod onto that node, assuming that it fits resource
- // requirements.
- NodeName string `json:"nodeName,omitempty" protobuf:"bytes,10,opt,name=nodeName"`
- // Host networking requested for this pod. Use the host's network namespace.
- // If this option is set, the ports that will be used must be specified.
- // Default to false.
- // +k8s:conversion-gen=false
- HostNetwork bool `json:"hostNetwork,omitempty" protobuf:"varint,11,opt,name=hostNetwork"`
- // Use the host's pid namespace.
- // Optional: Default to false.
- // +k8s:conversion-gen=false
- HostPID bool `json:"hostPID,omitempty" protobuf:"varint,12,opt,name=hostPID"`
- // Use the host's ipc namespace.
- // Optional: Default to false.
- // +k8s:conversion-gen=false
- HostIPC bool `json:"hostIPC,omitempty" protobuf:"varint,13,opt,name=hostIPC"`
- // SecurityContext holds pod-level security attributes and common container settings.
- // Optional: Defaults to empty. See type description for default values of each field.
- SecurityContext *PodSecurityContext `json:"securityContext,omitempty" protobuf:"bytes,14,opt,name=securityContext"`
- // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec.
- // If specified, these secrets will be passed to individual puller implementations for them to use. For example,
- // in the case of docker, only DockerConfig type secrets are honored.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#specifying-imagepullsecrets-on-a-pod
- ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,15,rep,name=imagePullSecrets"`
- // Specifies the hostname of the Pod
- // If not specified, the pod's hostname will be set to a system-defined value.
- Hostname string `json:"hostname,omitempty" protobuf:"bytes,16,opt,name=hostname"`
- // If specified, the fully qualified Pod hostname will be "<hostname>.<subdomain>.<pod namespace>.svc.<cluster domain>".
- // If not specified, the pod will not have a domainname at all.
- Subdomain string `json:"subdomain,omitempty" protobuf:"bytes,17,opt,name=subdomain"`
-}
-
-// PodSecurityContext holds pod-level security attributes and common container settings.
-// Some fields are also present in container.securityContext. Field values of
-// container.securityContext take precedence over field values of PodSecurityContext.
-type PodSecurityContext struct {
- // The SELinux context to be applied to all containers.
- // If unspecified, the container runtime will allocate a random SELinux context for each
- // container. May also be set in SecurityContext. If set in
- // both SecurityContext and PodSecurityContext, the value specified in SecurityContext
- // takes precedence for that container.
- SELinuxOptions *SELinuxOptions `json:"seLinuxOptions,omitempty" protobuf:"bytes,1,opt,name=seLinuxOptions"`
- // The UID to run the entrypoint of the container process.
- // Defaults to user specified in image metadata if unspecified.
- // May also be set in SecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence
- // for that container.
- RunAsUser *int64 `json:"runAsUser,omitempty" protobuf:"varint,2,opt,name=runAsUser"`
- // Indicates that the container must run as a non-root user.
- // If true, the Kubelet will validate the image at runtime to ensure that it
- // does not run as UID 0 (root) and fail to start the container if it does.
- // If unset or false, no such validation will be performed.
- // May also be set in SecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- RunAsNonRoot *bool `json:"runAsNonRoot,omitempty" protobuf:"varint,3,opt,name=runAsNonRoot"`
- // A list of groups applied to the first process run in each container, in addition
- // to the container's primary GID. If unspecified, no groups will be added to
- // any container.
- SupplementalGroups []int64 `json:"supplementalGroups,omitempty" protobuf:"varint,4,rep,name=supplementalGroups"`
- // A special supplemental group that applies to all containers in a pod.
- // Some volume types allow the Kubelet to change the ownership of that volume
- // to be owned by the pod:
- //
- // 1. The owning GID will be the FSGroup
- // 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)
- // 3. The permission bits are OR'd with rw-rw----
- //
- // If unset, the Kubelet will not modify the ownership and permissions of any volume.
- FSGroup *int64 `json:"fsGroup,omitempty" protobuf:"varint,5,opt,name=fsGroup"`
-}
-
-// PodStatus represents information about the status of a pod. Status may trail the actual
-// state of a system.
-type PodStatus struct {
- // Current condition of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-phase
- Phase PodPhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PodPhase"`
- // Current service state of pod.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions
- Conditions []PodCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"`
- // A human readable message indicating details about why the pod is in this condition.
- Message string `json:"message,omitempty" protobuf:"bytes,3,opt,name=message"`
- // A brief CamelCase message indicating details about why the pod is in this state.
- // e.g. 'OutOfDisk'
- Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"`
-
- // IP address of the host to which the pod is assigned. Empty if not yet scheduled.
- HostIP string `json:"hostIP,omitempty" protobuf:"bytes,5,opt,name=hostIP"`
- // IP address allocated to the pod. Routable at least within the cluster.
- // Empty if not yet allocated.
- PodIP string `json:"podIP,omitempty" protobuf:"bytes,6,opt,name=podIP"`
-
- // RFC 3339 date and time at which the object was acknowledged by the Kubelet.
- // This is before the Kubelet pulled the container image(s) for the pod.
- StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,7,opt,name=startTime"`
-
- // The list has one entry per init container in the manifest. The most recent successful
- // init container will have ready = true, the most recently started container will have
- // startTime set.
- // Init containers are in alpha state and may change without notice.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-statuses
- InitContainerStatuses []ContainerStatus `json:"-"`
- // The list has one entry per container in the manifest. Each entry is currently the output
- // of `docker inspect`.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-statuses
- ContainerStatuses []ContainerStatus `json:"containerStatuses,omitempty" protobuf:"bytes,8,rep,name=containerStatuses"`
-}
-
-// PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded
-type PodStatusResult struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
- // Most recently observed status of the pod.
- // This data may not be up to date.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status PodStatus `json:"status,omitempty" protobuf:"bytes,2,opt,name=status"`
-}
-
-// +genclient=true
-
-// Pod is a collection of containers that can run on a host. This resource is created
-// by clients and scheduled onto hosts.
-type Pod struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Specification of the desired behavior of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec PodSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Most recently observed status of the pod.
- // This data may not be up to date.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status PodStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// PodList is a list of Pods.
-type PodList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of pods.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/pods.md
- Items []Pod `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// PodTemplateSpec describes the data a pod should have when created from a template
-type PodTemplateSpec struct {
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Specification of the desired behavior of the pod.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec PodSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-}
-
-// +genclient=true
-
-// PodTemplate describes a template for creating copies of a predefined pod.
-type PodTemplate struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Template defines the pods that will be created from this pod template.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Template PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,2,opt,name=template"`
-}
-
-// PodTemplateList is a list of PodTemplates.
-type PodTemplateList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of pod templates
- Items []PodTemplate `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// ReplicationControllerSpec is the specification of a replication controller.
-type ReplicationControllerSpec struct {
- // Replicas is the number of desired replicas.
- // This is a pointer to distinguish between explicit zero and unspecified.
- // Defaults to 1.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
- Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"`
-
- // Selector is a label query over pods that should match the Replicas count.
- // If Selector is empty, it is defaulted to the labels present on the Pod template.
- // Label keys and values that must match in order to be controlled by this replication
- // controller, if empty defaulted to labels on Pod template.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
- Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"`
-
- // TemplateRef is a reference to an object that describes the pod that will be created if
- // insufficient replicas are detected.
- // Reference to an object that describes the pod that will be created if insufficient replicas are detected.
- // TemplateRef *ObjectReference `json:"templateRef,omitempty"`
-
- // Template is the object that describes the pod that will be created if
- // insufficient replicas are detected. This takes precedence over a TemplateRef.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
- Template *PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,3,opt,name=template"`
-}
-
-// ReplicationControllerStatus represents the current status of a replication
-// controller.
-type ReplicationControllerStatus struct {
- // Replicas is the most recently oberved number of replicas.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
- Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"`
-
- // The number of pods that have labels matching the labels of the pod template of the replication controller.
- FullyLabeledReplicas int32 `json:"fullyLabeledReplicas,omitempty" protobuf:"varint,2,opt,name=fullyLabeledReplicas"`
-
- // ObservedGeneration reflects the generation of the most recently observed replication controller.
- ObservedGeneration int64 `json:"observedGeneration,omitempty" protobuf:"varint,3,opt,name=observedGeneration"`
-}
-
-// +genclient=true
-
-// ReplicationController represents the configuration of a replication controller.
-type ReplicationController struct {
- unversioned.TypeMeta `json:",inline"`
-
- // If the Labels of a ReplicationController are empty, they are defaulted to
- // be the same as the Pod(s) that the replication controller manages.
- // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the specification of the desired behavior of the replication controller.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec ReplicationControllerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Status is the most recently observed status of the replication controller.
- // This data may be out of date by some window of time.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status ReplicationControllerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// ReplicationControllerList is a collection of replication controllers.
-type ReplicationControllerList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of replication controllers.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md
- Items []ReplicationController `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// Session Affinity Type string
-type ServiceAffinity string
-
-const (
- // ServiceAffinityClientIP is the Client IP based.
- ServiceAffinityClientIP ServiceAffinity = "ClientIP"
-
- // ServiceAffinityNone - no session affinity.
- ServiceAffinityNone ServiceAffinity = "None"
-)
-
-// Service Type string describes ingress methods for a service
-type ServiceType string
-
-const (
- // ServiceTypeClusterIP means a service will only be accessible inside the
- // cluster, via the cluster IP.
- ServiceTypeClusterIP ServiceType = "ClusterIP"
-
- // ServiceTypeNodePort means a service will be exposed on one port of
- // every node, in addition to 'ClusterIP' type.
- ServiceTypeNodePort ServiceType = "NodePort"
-
- // ServiceTypeLoadBalancer means a service will be exposed via an
- // external load balancer (if the cloud provider supports it), in addition
- // to 'NodePort' type.
- ServiceTypeLoadBalancer ServiceType = "LoadBalancer"
-)
-
-// ServiceStatus represents the current status of a service.
-type ServiceStatus struct {
- // LoadBalancer contains the current status of the load-balancer,
- // if one is present.
- LoadBalancer LoadBalancerStatus `json:"loadBalancer,omitempty" protobuf:"bytes,1,opt,name=loadBalancer"`
-}
-
-// LoadBalancerStatus represents the status of a load-balancer.
-type LoadBalancerStatus struct {
- // Ingress is a list containing ingress points for the load-balancer.
- // Traffic intended for the service should be sent to these ingress points.
- Ingress []LoadBalancerIngress `json:"ingress,omitempty" protobuf:"bytes,1,rep,name=ingress"`
-}
-
-// LoadBalancerIngress represents the status of a load-balancer ingress point:
-// traffic intended for the service should be sent to an ingress point.
-type LoadBalancerIngress struct {
- // IP is set for load-balancer ingress points that are IP based
- // (typically GCE or OpenStack load-balancers)
- IP string `json:"ip,omitempty" protobuf:"bytes,1,opt,name=ip"`
-
- // Hostname is set for load-balancer ingress points that are DNS based
- // (typically AWS load-balancers)
- Hostname string `json:"hostname,omitempty" protobuf:"bytes,2,opt,name=hostname"`
-}
-
-// ServiceSpec describes the attributes that a user creates on a service.
-type ServiceSpec struct {
- // The list of ports that are exposed by this service.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- Ports []ServicePort `json:"ports" patchStrategy:"merge" patchMergeKey:"port" protobuf:"bytes,1,rep,name=ports"`
-
- // This service will route traffic to pods having labels matching this selector.
- // Label keys and values that must match in order to receive traffic for this service.
- // If not specified, endpoints must be manually specified and the system will not automatically manage them.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#overview
- Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"`
-
- // ClusterIP is usually assigned by the master and is the IP address of the service.
- // If specified, it will be allocated to the service if it is unused
- // or else creation of the service will fail.
- // Valid values are None, empty string (""), or a valid IP address.
- // 'None' can be specified for a headless service when proxying is not required.
- // Cannot be updated.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- ClusterIP string `json:"clusterIP,omitempty" protobuf:"bytes,3,opt,name=clusterIP"`
-
- // Type of exposed service. Must be ClusterIP, NodePort, or LoadBalancer.
- // Defaults to ClusterIP.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#external-services
- Type ServiceType `json:"type,omitempty" protobuf:"bytes,4,opt,name=type,casttype=ServiceType"`
-
- // externalIPs is a list of IP addresses for which nodes in the cluster
- // will also accept traffic for this service. These IPs are not managed by
- // Kubernetes. The user is responsible for ensuring that traffic arrives
- // at a node with this IP. A common example is external load-balancers
- // that are not part of the Kubernetes system. A previous form of this
- // functionality exists as the deprecatedPublicIPs field. When using this
- // field, callers should also clear the deprecatedPublicIPs field.
- ExternalIPs []string `json:"externalIPs,omitempty" protobuf:"bytes,5,rep,name=externalIPs"`
-
- // deprecatedPublicIPs is deprecated and replaced by the externalIPs field
- // with almost the exact same semantics. This field is retained in the v1
- // API for compatibility until at least 8/20/2016. It will be removed from
- // any new API revisions. If both deprecatedPublicIPs *and* externalIPs are
- // set, deprecatedPublicIPs is used.
- // +k8s:conversion-gen=false
- DeprecatedPublicIPs []string `json:"deprecatedPublicIPs,omitempty" protobuf:"bytes,6,rep,name=deprecatedPublicIPs"`
-
- // Supports "ClientIP" and "None". Used to maintain session affinity.
- // Enable client IP based session affinity.
- // Must be ClientIP or None.
- // Defaults to None.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies
- SessionAffinity ServiceAffinity `json:"sessionAffinity,omitempty" protobuf:"bytes,7,opt,name=sessionAffinity,casttype=ServiceAffinity"`
-
- // Only applies to Service Type: LoadBalancer
- // LoadBalancer will get created with the IP specified in this field.
- // This feature depends on whether the underlying cloud-provider supports specifying
- // the loadBalancerIP when a load balancer is created.
- // This field will be ignored if the cloud-provider does not support the feature.
- LoadBalancerIP string `json:"loadBalancerIP,omitempty" protobuf:"bytes,8,opt,name=loadBalancerIP"`
-
- // If specified and supported by the platform, this will restrict traffic through the cloud-provider
- // load-balancer will be restricted to the specified client IPs. This field will be ignored if the
- // cloud-provider does not support the feature."
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services-firewalls.md
- LoadBalancerSourceRanges []string `json:"loadBalancerSourceRanges,omitempty" protobuf:"bytes,9,opt,name=loadBalancerSourceRanges"`
-}
-
-// ServicePort contains information on service's port.
-type ServicePort struct {
- // The name of this port within the service. This must be a DNS_LABEL.
- // All ports within a ServiceSpec must have unique names. This maps to
- // the 'Name' field in EndpointPort objects.
- // Optional if only one ServicePort is defined on this service.
- Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
-
- // The IP protocol for this port. Supports "TCP" and "UDP".
- // Default is TCP.
- Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,2,opt,name=protocol,casttype=Protocol"`
-
- // The port that will be exposed by this service.
- Port int32 `json:"port" protobuf:"varint,3,opt,name=port"`
-
- // Number or name of the port to access on the pods targeted by the service.
- // Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.
- // If this is a string, it will be looked up as a named port in the
- // target Pod's container ports. If this is not specified, the value
- // of the 'port' field is used (an identity map).
- // This field is ignored for services with clusterIP=None, and should be
- // omitted or set equal to the 'port' field.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#defining-a-service
- TargetPort intstr.IntOrString `json:"targetPort,omitempty" protobuf:"bytes,4,opt,name=targetPort"`
-
- // The port on each node on which this service is exposed when type=NodePort or LoadBalancer.
- // Usually assigned by the system. If specified, it will be allocated to the service
- // if unused or else creation of the service will fail.
- // Default is to auto-allocate a port if the ServiceType of this Service requires one.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#type--nodeport
- NodePort int32 `json:"nodePort,omitempty" protobuf:"varint,5,opt,name=nodePort"`
-}
-
-// +genclient=true
-
-// Service is a named abstraction of software service (for example, mysql) consisting of local port
-// (for example 3306) that the proxy listens on, and the selector that determines which pods
-// will answer requests sent through the proxy.
-type Service struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the behavior of a service.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec ServiceSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Most recently observed status of the service.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status ServiceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-const (
- // ClusterIPNone - do not assign a cluster IP
- // no proxying required and no environment variables should be created for pods
- ClusterIPNone = "None"
-)
-
-// ServiceList holds a list of services.
-type ServiceList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of services
- Items []Service `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// +genclient=true
-
-// ServiceAccount binds together:
-// * a name, understood by users, and perhaps by peripheral systems, for an identity
-// * a principal that can be authenticated and authorized
-// * a set of secrets
-type ServiceAccount struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md
- Secrets []ObjectReference `json:"secrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=secrets"`
-
- // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images
- // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets
- // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md#manually-specifying-an-imagepullsecret
- ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty" protobuf:"bytes,3,rep,name=imagePullSecrets"`
-}
-
-// ServiceAccountList is a list of ServiceAccount objects
-type ServiceAccountList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of ServiceAccounts.
- // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts
- Items []ServiceAccount `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// +genclient=true
-
-// Endpoints is a collection of endpoints that implement the actual service. Example:
-// Name: "mysvc",
-// Subsets: [
-// {
-// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
-// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
-// },
-// {
-// Addresses: [{"ip": "10.10.3.3"}],
-// Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}]
-// },
-// ]
-type Endpoints struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // The set of all endpoints is the union of all subsets. Addresses are placed into
- // subsets according to the IPs they share. A single address with multiple ports,
- // some of which are ready and some of which are not (because they come from
- // different containers) will result in the address being displayed in different
- // subsets for the different ports. No address will appear in both Addresses and
- // NotReadyAddresses in the same subset.
- // Sets of addresses and ports that comprise a service.
- Subsets []EndpointSubset `json:"subsets" protobuf:"bytes,2,rep,name=subsets"`
-}
-
-// EndpointSubset is a group of addresses with a common set of ports. The
-// expanded set of endpoints is the Cartesian product of Addresses x Ports.
-// For example, given:
-// {
-// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
-// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
-// }
-// The resulting set of endpoints can be viewed as:
-// a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],
-// b: [ 10.10.1.1:309, 10.10.2.2:309 ]
-type EndpointSubset struct {
- // IP addresses which offer the related ports that are marked as ready. These endpoints
- // should be considered safe for load balancers and clients to utilize.
- Addresses []EndpointAddress `json:"addresses,omitempty" protobuf:"bytes,1,rep,name=addresses"`
- // IP addresses which offer the related ports but are not currently marked as ready
- // because they have not yet finished starting, have recently failed a readiness check,
- // or have recently failed a liveness check.
- NotReadyAddresses []EndpointAddress `json:"notReadyAddresses,omitempty" protobuf:"bytes,2,rep,name=notReadyAddresses"`
- // Port numbers available on the related IP addresses.
- Ports []EndpointPort `json:"ports,omitempty" protobuf:"bytes,3,rep,name=ports"`
-}
-
-// EndpointAddress is a tuple that describes single IP address.
-type EndpointAddress struct {
- // The IP of this endpoint.
- // May not be loopback (127.0.0.0/8), link-local (169.254.0.0/16),
- // or link-local multicast ((224.0.0.0/24).
- // IPv6 is also accepted but not fully supported on all platforms. Also, certain
- // kubernetes components, like kube-proxy, are not IPv6 ready.
- // TODO: This should allow hostname or IP, See #4447.
- IP string `json:"ip" protobuf:"bytes,1,opt,name=ip"`
- // The Hostname of this endpoint
- Hostname string `json:"hostname,omitempty" protobuf:"bytes,3,opt,name=hostname"`
- // Reference to object providing the endpoint.
- TargetRef *ObjectReference `json:"targetRef,omitempty" protobuf:"bytes,2,opt,name=targetRef"`
-}
-
-// EndpointPort is a tuple that describes a single port.
-type EndpointPort struct {
- // The name of this port (corresponds to ServicePort.Name).
- // Must be a DNS_LABEL.
- // Optional only if one port is defined.
- Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
-
- // The port number of the endpoint.
- Port int32 `json:"port" protobuf:"varint,2,opt,name=port"`
-
- // The IP protocol for this port.
- // Must be UDP or TCP.
- // Default is TCP.
- Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,3,opt,name=protocol,casttype=Protocol"`
-}
-
-// EndpointsList is a list of endpoints.
-type EndpointsList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of endpoints.
- Items []Endpoints `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// NodeSpec describes the attributes that a node is created with.
-type NodeSpec struct {
- // PodCIDR represents the pod IP range assigned to the node.
- PodCIDR string `json:"podCIDR,omitempty" protobuf:"bytes,1,opt,name=podCIDR"`
- // External ID of the node assigned by some machine database (e.g. a cloud provider).
- // Deprecated.
- ExternalID string `json:"externalID,omitempty" protobuf:"bytes,2,opt,name=externalID"`
- // ID of the node assigned by the cloud provider in the format: <ProviderName>://<ProviderSpecificNodeID>
- ProviderID string `json:"providerID,omitempty" protobuf:"bytes,3,opt,name=providerID"`
- // Unschedulable controls node schedulability of new pods. By default, node is schedulable.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration"`
- Unschedulable bool `json:"unschedulable,omitempty" protobuf:"varint,4,opt,name=unschedulable"`
-}
-
-// DaemonEndpoint contains information about a single Daemon endpoint.
-type DaemonEndpoint struct {
- /*
- The port tag was not properly in quotes in earlier releases, so it must be
- uppercased for backwards compat (since it was falling back to var name of
- 'Port').
- */
-
- // Port number of the given endpoint.
- Port int32 `json:"Port" protobuf:"varint,1,opt,name=Port"`
-}
-
-// NodeDaemonEndpoints lists ports opened by daemons running on the Node.
-type NodeDaemonEndpoints struct {
- // Endpoint on which Kubelet is listening.
- KubeletEndpoint DaemonEndpoint `json:"kubeletEndpoint,omitempty" protobuf:"bytes,1,opt,name=kubeletEndpoint"`
-}
-
-// NodeSystemInfo is a set of ids/uuids to uniquely identify the node.
-type NodeSystemInfo struct {
- // Machine ID reported by the node.
- MachineID string `json:"machineID" protobuf:"bytes,1,opt,name=machineID"`
- // System UUID reported by the node.
- SystemUUID string `json:"systemUUID" protobuf:"bytes,2,opt,name=systemUUID"`
- // Boot ID reported by the node.
- BootID string `json:"bootID" protobuf:"bytes,3,opt,name=bootID"`
- // Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).
- KernelVersion string `json:"kernelVersion" protobuf:"bytes,4,opt,name=kernelVersion"`
- // OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).
- OSImage string `json:"osImage" protobuf:"bytes,5,opt,name=osImage"`
- // ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0).
- ContainerRuntimeVersion string `json:"containerRuntimeVersion" protobuf:"bytes,6,opt,name=containerRuntimeVersion"`
- // Kubelet Version reported by the node.
- KubeletVersion string `json:"kubeletVersion" protobuf:"bytes,7,opt,name=kubeletVersion"`
- // KubeProxy Version reported by the node.
- KubeProxyVersion string `json:"kubeProxyVersion" protobuf:"bytes,8,opt,name=kubeProxyVersion"`
- // The Operating System reported by the node
- OperatingSystem string `json:"operatingSystem" protobuf:"bytes,9,opt,name=operatingSystem"`
- // The Architecture reported by the node
- Architecture string `json:"architecture" protobuf:"bytes,10,opt,name=architecture"`
-}
-
-// NodeStatus is information about the current status of a node.
-type NodeStatus struct {
- // Capacity represents the total resources of a node.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity for more details.
- Capacity ResourceList `json:"capacity,omitempty" protobuf:"bytes,1,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"`
- // Allocatable represents the resources of a node that are available for scheduling.
- // Defaults to Capacity.
- Allocatable ResourceList `json:"allocatable,omitempty" protobuf:"bytes,2,rep,name=allocatable,casttype=ResourceList,castkey=ResourceName"`
- // NodePhase is the recently observed lifecycle phase of the node.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase
- Phase NodePhase `json:"phase,omitempty" protobuf:"bytes,3,opt,name=phase,casttype=NodePhase"`
- // Conditions is an array of current observed node conditions.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition
- Conditions []NodeCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,4,rep,name=conditions"`
- // List of addresses reachable to the node.
- // Queried from cloud provider, if available.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses
- Addresses []NodeAddress `json:"addresses,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,5,rep,name=addresses"`
- // Endpoints of daemons running on the Node.
- DaemonEndpoints NodeDaemonEndpoints `json:"daemonEndpoints,omitempty" protobuf:"bytes,6,opt,name=daemonEndpoints"`
- // Set of ids/uuids to uniquely identify the node.
- // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info
- NodeInfo NodeSystemInfo `json:"nodeInfo,omitempty" protobuf:"bytes,7,opt,name=nodeInfo"`
- // List of container images on this node
- Images []ContainerImage `json:"images,omitempty" protobuf:"bytes,8,rep,name=images"`
- // List of attachable volumes in use (mounted) by the node.
- VolumesInUse []UniqueVolumeName `json:"volumesInUse,omitempty" protobuf:"bytes,9,rep,name=volumesInUse"`
- // List of volumes that are attached to the node.
- VolumesAttached []AttachedVolume `json:"volumesAttached,omitempty" protobuf:"bytes,10,rep,name=volumesAttached"`
-}
-
-type UniqueVolumeName string
-
-// AttachedVolume describes a volume attached to a node
-type AttachedVolume struct {
- // Name of the attached volume
- Name UniqueVolumeName `json:"name" protobuf:"bytes,1,rep,name=name"`
-
- // DevicePath represents the device path where the volume should be avilable
- DevicePath string `json:"devicePath" protobuf:"bytes,2,rep,name=devicePath"`
-}
-
-// Describe a container image
-type ContainerImage struct {
- // Names by which this image is known.
- // e.g. ["gcr.io/google_containers/hyperkube:v1.0.7", "dockerhub.io/google_containers/hyperkube:v1.0.7"]
- Names []string `json:"names" protobuf:"bytes,1,rep,name=names"`
- // The size of the image in bytes.
- SizeBytes int64 `json:"sizeBytes,omitempty" protobuf:"varint,2,opt,name=sizeBytes"`
-}
-
-type NodePhase string
-
-// These are the valid phases of node.
-const (
- // NodePending means the node has been created/added by the system, but not configured.
- NodePending NodePhase = "Pending"
- // NodeRunning means the node has been configured and has Kubernetes components running.
- NodeRunning NodePhase = "Running"
- // NodeTerminated means the node has been removed from the cluster.
- NodeTerminated NodePhase = "Terminated"
-)
-
-type NodeConditionType string
-
-// These are valid conditions of node. Currently, we don't have enough information to decide
-// node condition. In the future, we will add more. The proposed set of conditions are:
-// NodeReachable, NodeLive, NodeReady, NodeSchedulable, NodeRunnable.
-const (
- // NodeReady means kubelet is healthy and ready to accept pods.
- NodeReady NodeConditionType = "Ready"
- // NodeOutOfDisk means the kubelet will not accept new pods due to insufficient free disk
- // space on the node.
- NodeOutOfDisk NodeConditionType = "OutOfDisk"
- // NodeMemoryPressure means the kubelet is under pressure due to insufficient available memory.
- NodeMemoryPressure NodeConditionType = "MemoryPressure"
- // NodeNetworkUnavailable means that network for the node is not correctly configured.
- NodeNetworkUnavailable NodeConditionType = "NetworkUnavailable"
-)
-
-// NodeCondition contains condition infromation for a node.
-type NodeCondition struct {
- // Type of node condition.
- Type NodeConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=NodeConditionType"`
- // Status of the condition, one of True, False, Unknown.
- Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"`
- // Last time we got an update on a given condition.
- LastHeartbeatTime unversioned.Time `json:"lastHeartbeatTime,omitempty" protobuf:"bytes,3,opt,name=lastHeartbeatTime"`
- // Last time the condition transit from one status to another.
- LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"`
- // (brief) reason for the condition's last transition.
- Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"`
- // Human readable message indicating details about last transition.
- Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"`
-}
-
-type NodeAddressType string
-
-// These are valid address type of node.
-const (
- NodeHostName NodeAddressType = "Hostname"
- NodeExternalIP NodeAddressType = "ExternalIP"
- NodeInternalIP NodeAddressType = "InternalIP"
-)
-
-// NodeAddress contains information for the node's address.
-type NodeAddress struct {
- // Node address type, one of Hostname, ExternalIP or InternalIP.
- Type NodeAddressType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=NodeAddressType"`
- // The node address.
- Address string `json:"address" protobuf:"bytes,2,opt,name=address"`
-}
-
-// ResourceName is the name identifying various resources in a ResourceList.
-type ResourceName string
-
-// Resource names must be not more than 63 characters, consisting of upper- or lower-case alphanumeric characters,
-// with the -, _, and . characters allowed anywhere, except the first or last character.
-// The default convention, matching that for annotations, is to use lower-case names, with dashes, rather than
-// camel case, separating compound words.
-// Fully-qualified resource typenames are constructed from a DNS-style subdomain, followed by a slash `/` and a name.
-const (
- // CPU, in cores. (500m = .5 cores)
- ResourceCPU ResourceName = "cpu"
- // Memory, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)
- ResourceMemory ResourceName = "memory"
- // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024)
- ResourceStorage ResourceName = "storage"
- // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned.
- ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu"
- // Number of Pods that may be running on this Node: see ResourcePods
-)
-
-// ResourceList is a set of (resource name, quantity) pairs.
-type ResourceList map[ResourceName]resource.Quantity
-
-// +genclient=true
-// +nonNamespaced=true
-
-// Node is a worker node in Kubernetes, formerly known as minion.
-// Each node will have a unique identifier in the cache (i.e. in etcd).
-type Node struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the behavior of a node.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec NodeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Most recently observed status of the node.
- // Populated by the system.
- // Read-only.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status NodeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// NodeList is the whole list of all Nodes which have been registered with master.
-type NodeList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of nodes
- Items []Node `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-type FinalizerName string
-
-// These are internal finalizer values to Kubernetes, must be qualified name unless defined here
-const (
- FinalizerKubernetes FinalizerName = "kubernetes"
-)
-
-// NamespaceSpec describes the attributes on a Namespace.
-type NamespaceSpec struct {
- // Finalizers is an opaque list of values that must be empty to permanently remove object from storage.
- // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers
- Finalizers []FinalizerName `json:"finalizers,omitempty" protobuf:"bytes,1,rep,name=finalizers,casttype=FinalizerName"`
-}
-
-// NamespaceStatus is information about the current status of a Namespace.
-type NamespaceStatus struct {
- // Phase is the current lifecycle phase of the namespace.
- // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases
- Phase NamespacePhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=NamespacePhase"`
-}
-
-type NamespacePhase string
-
-// These are the valid phases of a namespace.
-const (
- // NamespaceActive means the namespace is available for use in the system
- NamespaceActive NamespacePhase = "Active"
- // NamespaceTerminating means the namespace is undergoing graceful termination
- NamespaceTerminating NamespacePhase = "Terminating"
-)
-
-// +genclient=true
-// +nonNamespaced=true
-
-// Namespace provides a scope for Names.
-// Use of multiple namespaces is optional.
-type Namespace struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the behavior of the Namespace.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec NamespaceSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Status describes the current status of a Namespace.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status NamespaceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// NamespaceList is a list of Namespaces.
-type NamespaceList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Items is the list of Namespace objects in the list.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- Items []Namespace `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// Binding ties one object to another.
-// For example, a pod is bound to a node by a scheduler.
-type Binding struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // The target object that you want to bind to the standard object.
- Target ObjectReference `json:"target" protobuf:"bytes,2,opt,name=target"`
-}
-
-// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.
-type Preconditions struct {
- // Specifies the target UID.
- UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"`
-}
-
-// DeleteOptions may be provided when deleting an API object
-type DeleteOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // The duration in seconds before the object should be deleted. Value must be non-negative integer.
- // The value zero indicates delete immediately. If this value is nil, the default grace period for the
- // specified type will be used.
- // Defaults to a per object value if not specified. zero means delete immediately.
- GracePeriodSeconds *int64 `json:"gracePeriodSeconds,omitempty" protobuf:"varint,1,opt,name=gracePeriodSeconds"`
-
- // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be
- // returned.
- Preconditions *Preconditions `json:"preconditions,omitempty" protobuf:"bytes,2,opt,name=preconditions"`
-
- // Should the dependent objects be orphaned. If true/false, the "orphan"
- // finalizer will be added to/removed from the object's finalizers list.
- OrphanDependents *bool `json:"orphanDependents,omitempty" protobuf:"varint,3,opt,name=orphanDependents"`
-}
-
-// ExportOptions is the query options to the standard REST get call.
-type ExportOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Should this value be exported. Export strips fields that a user can not specify.
- Export bool `json:"export" protobuf:"varint,1,opt,name=export"`
- // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
- Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"`
-}
-
-// ListOptions is the query options to a standard REST list call.
-type ListOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // A selector to restrict the list of returned objects by their labels.
- // Defaults to everything.
- LabelSelector string `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"`
- // A selector to restrict the list of returned objects by their fields.
- // Defaults to everything.
- FieldSelector string `json:"fieldSelector,omitempty" protobuf:"bytes,2,opt,name=fieldSelector"`
- // Watch for changes to the described resources and return them as a stream of
- // add, update, and remove notifications. Specify resourceVersion.
- Watch bool `json:"watch,omitempty" protobuf:"varint,3,opt,name=watch"`
- // When specified with a watch call, shows changes that occur after that particular version of a resource.
- // Defaults to changes from the beginning of history.
- ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,4,opt,name=resourceVersion"`
- // Timeout for the list/watch call.
- TimeoutSeconds *int64 `json:"timeoutSeconds,omitempty" protobuf:"varint,5,opt,name=timeoutSeconds"`
-}
-
-// PodLogOptions is the query options for a Pod's logs REST call.
-type PodLogOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // The container for which to stream logs. Defaults to only container if there is one container in the pod.
- Container string `json:"container,omitempty" protobuf:"bytes,1,opt,name=container"`
- // Follow the log stream of the pod. Defaults to false.
- Follow bool `json:"follow,omitempty" protobuf:"varint,2,opt,name=follow"`
- // Return previous terminated container logs. Defaults to false.
- Previous bool `json:"previous,omitempty" protobuf:"varint,3,opt,name=previous"`
- // A relative time in seconds before the current time from which to show logs. If this value
- // precedes the time a pod was started, only logs since the pod start will be returned.
- // If this value is in the future, no logs will be returned.
- // Only one of sinceSeconds or sinceTime may be specified.
- SinceSeconds *int64 `json:"sinceSeconds,omitempty" protobuf:"varint,4,opt,name=sinceSeconds"`
- // An RFC3339 timestamp from which to show logs. If this value
- // precedes the time a pod was started, only logs since the pod start will be returned.
- // If this value is in the future, no logs will be returned.
- // Only one of sinceSeconds or sinceTime may be specified.
- SinceTime *unversioned.Time `json:"sinceTime,omitempty" protobuf:"bytes,5,opt,name=sinceTime"`
- // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line
- // of log output. Defaults to false.
- Timestamps bool `json:"timestamps,omitempty" protobuf:"varint,6,opt,name=timestamps"`
- // If set, the number of lines from the end of the logs to show. If not specified,
- // logs are shown from the creation of the container or sinceSeconds or sinceTime
- TailLines *int64 `json:"tailLines,omitempty" protobuf:"varint,7,opt,name=tailLines"`
- // If set, the number of bytes to read from the server before terminating the
- // log output. This may not display a complete final line of logging, and may return
- // slightly more or slightly less than the specified limit.
- LimitBytes *int64 `json:"limitBytes,omitempty" protobuf:"varint,8,opt,name=limitBytes"`
-}
-
-// PodAttachOptions is the query options to a Pod's remote attach call.
-// ---
-// TODO: merge w/ PodExecOptions below for stdin, stdout, etc
-// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
-type PodAttachOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Stdin if true, redirects the standard input stream of the pod for this call.
- // Defaults to false.
- Stdin bool `json:"stdin,omitempty" protobuf:"varint,1,opt,name=stdin"`
-
- // Stdout if true indicates that stdout is to be redirected for the attach call.
- // Defaults to true.
- Stdout bool `json:"stdout,omitempty" protobuf:"varint,2,opt,name=stdout"`
-
- // Stderr if true indicates that stderr is to be redirected for the attach call.
- // Defaults to true.
- Stderr bool `json:"stderr,omitempty" protobuf:"varint,3,opt,name=stderr"`
-
- // TTY if true indicates that a tty will be allocated for the attach call.
- // This is passed through the container runtime so the tty
- // is allocated on the worker node by the container runtime.
- // Defaults to false.
- TTY bool `json:"tty,omitempty" protobuf:"varint,4,opt,name=tty"`
-
- // The container in which to execute the command.
- // Defaults to only container if there is only one container in the pod.
- Container string `json:"container,omitempty" protobuf:"bytes,5,opt,name=container"`
-}
-
-// PodExecOptions is the query options to a Pod's remote exec call.
-// ---
-// TODO: This is largely identical to PodAttachOptions above, make sure they stay in sync and see about merging
-// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
-type PodExecOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Redirect the standard input stream of the pod for this call.
- // Defaults to false.
- Stdin bool `json:"stdin,omitempty" protobuf:"varint,1,opt,name=stdin"`
-
- // Redirect the standard output stream of the pod for this call.
- // Defaults to true.
- Stdout bool `json:"stdout,omitempty" protobuf:"varint,2,opt,name=stdout"`
-
- // Redirect the standard error stream of the pod for this call.
- // Defaults to true.
- Stderr bool `json:"stderr,omitempty" protobuf:"varint,3,opt,name=stderr"`
-
- // TTY if true indicates that a tty will be allocated for the exec call.
- // Defaults to false.
- TTY bool `json:"tty,omitempty" protobuf:"varint,4,opt,name=tty"`
-
- // Container in which to execute the command.
- // Defaults to only container if there is only one container in the pod.
- Container string `json:"container,omitempty" protobuf:"bytes,5,opt,name=container"`
-
- // Command is the remote command to execute. argv array. Not executed within a shell.
- Command []string `json:"command" protobuf:"bytes,6,rep,name=command"`
-}
-
-// PodProxyOptions is the query options to a Pod's proxy call.
-type PodProxyOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Path is the URL path to use for the current proxy request to pod.
- Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"`
-}
-
-// NodeProxyOptions is the query options to a Node's proxy call.
-type NodeProxyOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Path is the URL path to use for the current proxy request to node.
- Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"`
-}
-
-// ServiceProxyOptions is the query options to a Service's proxy call.
-type ServiceProxyOptions struct {
- unversioned.TypeMeta `json:",inline"`
-
- // Path is the part of URLs that include service endpoints, suffixes,
- // and parameters to use for the current proxy request to service.
- // For example, the whole request URL is
- // http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy.
- // Path is _search?q=user:kimchy.
- Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"`
-}
-
-// OwnerReference contains enough information to let you identify an owning
-// object. Currently, an owning object must be in the same namespace, so there
-// is no namespace field.
-type OwnerReference struct {
- // API version of the referent.
- APIVersion string `json:"apiVersion" protobuf:"bytes,5,opt,name=apiVersion"`
- // Kind of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"`
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- Name string `json:"name" protobuf:"bytes,3,opt,name=name"`
- // UID of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- UID types.UID `json:"uid" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"`
- // If true, this reference points to the managing controller.
- Controller *bool `json:"controller,omitempty" protobuf:"varint,6,opt,name=controller"`
-}
-
-// ObjectReference contains enough information to let you inspect or modify the referred object.
-type ObjectReference struct {
- // Kind of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"`
- // Namespace of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md
- Namespace string `json:"namespace,omitempty" protobuf:"bytes,2,opt,name=namespace"`
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- Name string `json:"name,omitempty" protobuf:"bytes,3,opt,name=name"`
- // UID of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids
- UID types.UID `json:"uid,omitempty" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"`
- // API version of the referent.
- APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,5,opt,name=apiVersion"`
- // Specific resourceVersion to which this reference is made, if any.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
- ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"`
-
- // If referring to a piece of an object instead of an entire object, this string
- // should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2].
- // For example, if the object reference is to a container within a pod, this would take on a value like:
- // "spec.containers{name}" (where "name" refers to the name of the container that triggered
- // the event) or if no container name is specified "spec.containers[2]" (container with
- // index 2 in this pod). This syntax is chosen only to have some well-defined way of
- // referencing a part of an object.
- // TODO: this design is not final and this field is subject to change in the future.
- FieldPath string `json:"fieldPath,omitempty" protobuf:"bytes,7,opt,name=fieldPath"`
-}
-
-// LocalObjectReference contains enough information to let you locate the
-// referenced object inside the same namespace.
-type LocalObjectReference struct {
- // Name of the referent.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
- // TODO: Add other useful fields. apiVersion, kind, uid?
- Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
-}
-
-// SerializedReference is a reference to serialized object.
-type SerializedReference struct {
- unversioned.TypeMeta `json:",inline"`
- // The reference to an object in the system.
- Reference ObjectReference `json:"reference,omitempty" protobuf:"bytes,1,opt,name=reference"`
-}
-
-// EventSource contains information for an event.
-type EventSource struct {
- // Component from which the event is generated.
- Component string `json:"component,omitempty" protobuf:"bytes,1,opt,name=component"`
- // Host name on which the event is generated.
- Host string `json:"host,omitempty" protobuf:"bytes,2,opt,name=host"`
-}
-
-// Valid values for event types (new types could be added in future)
-const (
- // Information only and will not cause any problems
- EventTypeNormal string = "Normal"
- // These events are to warn that something might go wrong
- EventTypeWarning string = "Warning"
-)
-
-// +genclient=true
-
-// Event is a report of an event somewhere in the cluster.
-// TODO: Decide whether to store these separately or with the object they apply to.
-type Event struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata" protobuf:"bytes,1,opt,name=metadata"`
-
- // The object that this event is about.
- InvolvedObject ObjectReference `json:"involvedObject" protobuf:"bytes,2,opt,name=involvedObject"`
-
- // This should be a short, machine understandable string that gives the reason
- // for the transition into the object's current status.
- // TODO: provide exact specification for format.
- Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"`
-
- // A human-readable description of the status of this operation.
- // TODO: decide on maximum length.
- Message string `json:"message,omitempty" protobuf:"bytes,4,opt,name=message"`
-
- // The component reporting this event. Should be a short machine understandable string.
- Source EventSource `json:"source,omitempty" protobuf:"bytes,5,opt,name=source"`
-
- // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)
- FirstTimestamp unversioned.Time `json:"firstTimestamp,omitempty" protobuf:"bytes,6,opt,name=firstTimestamp"`
-
- // The time at which the most recent occurrence of this event was recorded.
- LastTimestamp unversioned.Time `json:"lastTimestamp,omitempty" protobuf:"bytes,7,opt,name=lastTimestamp"`
-
- // The number of times this event has occurred.
- Count int32 `json:"count,omitempty" protobuf:"varint,8,opt,name=count"`
-
- // Type of this event (Normal, Warning), new types could be added in the future
- Type string `json:"type,omitempty" protobuf:"bytes,9,opt,name=type"`
-}
-
-// EventList is a list of events.
-type EventList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of events
- Items []Event `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// List holds a list of objects, which may not be known by the server.
-type List struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of objects
- Items []runtime.RawExtension `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// LimitType is a type of object that is limited
-type LimitType string
-
-const (
- // Limit that applies to all pods in a namespace
- LimitTypePod LimitType = "Pod"
- // Limit that applies to all containers in a namespace
- LimitTypeContainer LimitType = "Container"
-)
-
-// LimitRangeItem defines a min/max usage limit for any resource that matches on kind.
-type LimitRangeItem struct {
- // Type of resource that this limit applies to.
- Type LimitType `json:"type,omitempty" protobuf:"bytes,1,opt,name=type,casttype=LimitType"`
- // Max usage constraints on this kind by resource name.
- Max ResourceList `json:"max,omitempty" protobuf:"bytes,2,rep,name=max,casttype=ResourceList,castkey=ResourceName"`
- // Min usage constraints on this kind by resource name.
- Min ResourceList `json:"min,omitempty" protobuf:"bytes,3,rep,name=min,casttype=ResourceList,castkey=ResourceName"`
- // Default resource requirement limit value by resource name if resource limit is omitted.
- Default ResourceList `json:"default,omitempty" protobuf:"bytes,4,rep,name=default,casttype=ResourceList,castkey=ResourceName"`
- // DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.
- DefaultRequest ResourceList `json:"defaultRequest,omitempty" protobuf:"bytes,5,rep,name=defaultRequest,casttype=ResourceList,castkey=ResourceName"`
- // MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.
- MaxLimitRequestRatio ResourceList `json:"maxLimitRequestRatio,omitempty" protobuf:"bytes,6,rep,name=maxLimitRequestRatio,casttype=ResourceList,castkey=ResourceName"`
-}
-
-// LimitRangeSpec defines a min/max usage limit for resources that match on kind.
-type LimitRangeSpec struct {
- // Limits is the list of LimitRangeItem objects that are enforced.
- Limits []LimitRangeItem `json:"limits" protobuf:"bytes,1,rep,name=limits"`
-}
-
-// +genclient=true
-
-// LimitRange sets resource usage limits for each kind of resource in a Namespace.
-type LimitRange struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the limits enforced.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec LimitRangeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-}
-
-// LimitRangeList is a list of LimitRange items.
-type LimitRangeList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Items is a list of LimitRange objects.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md
- Items []LimitRange `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// The following identify resource constants for Kubernetes object types
-const (
- // Pods, number
- ResourcePods ResourceName = "pods"
- // Services, number
- ResourceServices ResourceName = "services"
- // ReplicationControllers, number
- ResourceReplicationControllers ResourceName = "replicationcontrollers"
- // ResourceQuotas, number
- ResourceQuotas ResourceName = "resourcequotas"
- // ResourceSecrets, number
- ResourceSecrets ResourceName = "secrets"
- // ResourceConfigMaps, number
- ResourceConfigMaps ResourceName = "configmaps"
- // ResourcePersistentVolumeClaims, number
- ResourcePersistentVolumeClaims ResourceName = "persistentvolumeclaims"
- // ResourceServicesNodePorts, number
- ResourceServicesNodePorts ResourceName = "services.nodeports"
- // ResourceServicesLoadBalancers, number
- ResourceServicesLoadBalancers ResourceName = "services.loadbalancers"
- // CPU request, in cores. (500m = .5 cores)
- ResourceRequestsCPU ResourceName = "requests.cpu"
- // Memory request, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)
- ResourceRequestsMemory ResourceName = "requests.memory"
- // CPU limit, in cores. (500m = .5 cores)
- ResourceLimitsCPU ResourceName = "limits.cpu"
- // Memory limit, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)
- ResourceLimitsMemory ResourceName = "limits.memory"
-)
-
-// A ResourceQuotaScope defines a filter that must match each object tracked by a quota
-type ResourceQuotaScope string
-
-const (
- // Match all pod objects where spec.activeDeadlineSeconds
- ResourceQuotaScopeTerminating ResourceQuotaScope = "Terminating"
- // Match all pod objects where !spec.activeDeadlineSeconds
- ResourceQuotaScopeNotTerminating ResourceQuotaScope = "NotTerminating"
- // Match all pod objects that have best effort quality of service
- ResourceQuotaScopeBestEffort ResourceQuotaScope = "BestEffort"
- // Match all pod objects that do not have best effort quality of service
- ResourceQuotaScopeNotBestEffort ResourceQuotaScope = "NotBestEffort"
-)
-
-// ResourceQuotaSpec defines the desired hard limits to enforce for Quota.
-type ResourceQuotaSpec struct {
- // Hard is the set of desired hard limits for each named resource.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- Hard ResourceList `json:"hard,omitempty" protobuf:"bytes,1,rep,name=hard,casttype=ResourceList,castkey=ResourceName"`
- // A collection of filters that must match each object tracked by a quota.
- // If not specified, the quota matches all objects.
- Scopes []ResourceQuotaScope `json:"scopes,omitempty" protobuf:"bytes,2,rep,name=scopes,casttype=ResourceQuotaScope"`
-}
-
-// ResourceQuotaStatus defines the enforced hard limits and observed use.
-type ResourceQuotaStatus struct {
- // Hard is the set of enforced hard limits for each named resource.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- Hard ResourceList `json:"hard,omitempty" protobuf:"bytes,1,rep,name=hard,casttype=ResourceList,castkey=ResourceName"`
- // Used is the current observed total usage of the resource in the namespace.
- Used ResourceList `json:"used,omitempty" protobuf:"bytes,2,rep,name=used,casttype=ResourceList,castkey=ResourceName"`
-}
-
-// +genclient=true
-
-// ResourceQuota sets aggregate quota restrictions enforced per namespace
-type ResourceQuota struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Spec defines the desired quota.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Spec ResourceQuotaSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
-
- // Status defines the actual enforced quota and its current usage.
- // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
- Status ResourceQuotaStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
-}
-
-// ResourceQuotaList is a list of ResourceQuota items.
-type ResourceQuotaList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Items is a list of ResourceQuota objects.
- // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota
- Items []ResourceQuota `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// +genclient=true
-
-// Secret holds secret data of a certain type. The total bytes of the values in
-// the Data field must be less than MaxSecretSize bytes.
-type Secret struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN
- // or leading dot followed by valid DNS_SUBDOMAIN.
- // The serialized form of the secret data is a base64 encoded string,
- // representing the arbitrary (possibly non-string) data value here.
- // Described in https://tools.ietf.org/html/rfc4648#section-4
- Data map[string][]byte `json:"data,omitempty" protobuf:"bytes,2,rep,name=data"`
-
- // stringData allows specifying non-binary secret data in string form.
- // It is provided as a write-only convenience method.
- // All keys and values are merged into the data field on write, overwriting any existing values.
- // It is never output when reading from the API.
- // +k8s:conversion-gen=false
- StringData map[string]string `json:"stringData,omitempty" protobuf:"bytes,4,rep,name=stringData"`
-
- // Used to facilitate programmatic handling of secret data.
- Type SecretType `json:"type,omitempty" protobuf:"bytes,3,opt,name=type,casttype=SecretType"`
-}
-
-const MaxSecretSize = 1 * 1024 * 1024
-
-type SecretType string
-
-const (
- // SecretTypeOpaque is the default. Arbitrary user-defined data
- SecretTypeOpaque SecretType = "Opaque"
-
- // SecretTypeServiceAccountToken contains a token that identifies a service account to the API
- //
- // Required fields:
- // - Secret.Annotations["kubernetes.io/service-account.name"] - the name of the ServiceAccount the token identifies
- // - Secret.Annotations["kubernetes.io/service-account.uid"] - the UID of the ServiceAccount the token identifies
- // - Secret.Data["token"] - a token that identifies the service account to the API
- SecretTypeServiceAccountToken SecretType = "kubernetes.io/service-account-token"
-
- // ServiceAccountNameKey is the key of the required annotation for SecretTypeServiceAccountToken secrets
- ServiceAccountNameKey = "kubernetes.io/service-account.name"
- // ServiceAccountUIDKey is the key of the required annotation for SecretTypeServiceAccountToken secrets
- ServiceAccountUIDKey = "kubernetes.io/service-account.uid"
- // ServiceAccountTokenKey is the key of the required data for SecretTypeServiceAccountToken secrets
- ServiceAccountTokenKey = "token"
- // ServiceAccountKubeconfigKey is the key of the optional kubeconfig data for SecretTypeServiceAccountToken secrets
- ServiceAccountKubeconfigKey = "kubernetes.kubeconfig"
- // ServiceAccountRootCAKey is the key of the optional root certificate authority for SecretTypeServiceAccountToken secrets
- ServiceAccountRootCAKey = "ca.crt"
- // ServiceAccountNamespaceKey is the key of the optional namespace to use as the default for namespaced API calls
- ServiceAccountNamespaceKey = "namespace"
-
- // SecretTypeDockercfg contains a dockercfg file that follows the same format rules as ~/.dockercfg
- //
- // Required fields:
- // - Secret.Data[".dockercfg"] - a serialized ~/.dockercfg file
- SecretTypeDockercfg SecretType = "kubernetes.io/dockercfg"
-
- // DockerConfigKey is the key of the required data for SecretTypeDockercfg secrets
- DockerConfigKey = ".dockercfg"
-
- // SecretTypeTLS contains information about a TLS client or server secret. It
- // is primarily used with TLS termination of the Ingress resource, but may be
- // used in other types.
- //
- // Required fields:
- // - Secret.Data["tls.key"] - TLS private key.
- // Secret.Data["tls.crt"] - TLS certificate.
- // TODO: Consider supporting different formats, specifying CA/destinationCA.
- SecretTypeTLS SecretType = "kubernetes.io/tls"
-
- // TLSCertKey is the key for tls certificates in a TLS secert.
- TLSCertKey = "tls.crt"
- // TLSPrivateKeyKey is the key for the private key field in a TLS secret.
- TLSPrivateKeyKey = "tls.key"
-)
-
-// SecretList is a list of Secret.
-type SecretList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Items is a list of secret objects.
- // More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md
- Items []Secret `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// +genclient=true
-
-// ConfigMap holds configuration data for pods to consume.
-type ConfigMap struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Data contains the configuration data.
- // Each key must be a valid DNS_SUBDOMAIN with an optional leading dot.
- Data map[string]string `json:"data,omitempty" protobuf:"bytes,2,rep,name=data"`
-}
-
-// ConfigMapList is a resource containing a list of ConfigMap objects.
-type ConfigMapList struct {
- unversioned.TypeMeta `json:",inline"`
-
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Items is the list of ConfigMaps.
- Items []ConfigMap `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// Type and constants for component health validation.
-type ComponentConditionType string
-
-// These are the valid conditions for the component.
-const (
- ComponentHealthy ComponentConditionType = "Healthy"
-)
-
-// Information about the condition of a component.
-type ComponentCondition struct {
- // Type of condition for a component.
- // Valid value: "Healthy"
- Type ComponentConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=ComponentConditionType"`
- // Status of the condition for a component.
- // Valid values for "Healthy": "True", "False", or "Unknown".
- Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"`
- // Message about the condition for a component.
- // For example, information about a health check.
- Message string `json:"message,omitempty" protobuf:"bytes,3,opt,name=message"`
- // Condition error code for a component.
- // For example, a health check error code.
- Error string `json:"error,omitempty" protobuf:"bytes,4,opt,name=error"`
-}
-
-// +genclient=true
-// +nonNamespaced=true
-
-// ComponentStatus (and ComponentStatusList) holds the cluster validation info.
-type ComponentStatus struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of component conditions observed
- Conditions []ComponentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"`
-}
-
-// Status of all the conditions for the component as a list of ComponentStatus objects.
-type ComponentStatusList struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard list metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
- unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // List of ComponentStatus objects.
- Items []ComponentStatus `json:"items" protobuf:"bytes,2,rep,name=items"`
-}
-
-// DownwardAPIVolumeSource represents a volume containing downward API info.
-// Downward API volumes support ownership management and SELinux relabeling.
-type DownwardAPIVolumeSource struct {
- // Items is a list of downward API volume file
- Items []DownwardAPIVolumeFile `json:"items,omitempty" protobuf:"bytes,1,rep,name=items"`
-}
-
-// DownwardAPIVolumeFile represents information to create the file containing the pod field
-type DownwardAPIVolumeFile struct {
- // Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'
- Path string `json:"path" protobuf:"bytes,1,opt,name=path"`
- // Required: Selects a field of the pod: only annotations, labels, name and namespace are supported.
- FieldRef *ObjectFieldSelector `json:"fieldRef,omitempty" protobuf:"bytes,2,opt,name=fieldRef"`
- // Selects a resource of the container: only resources limits and requests
- // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.
- ResourceFieldRef *ResourceFieldSelector `json:"resourceFieldRef,omitempty" protobuf:"bytes,3,opt,name=resourceFieldRef"`
-}
-
-// SecurityContext holds security configuration that will be applied to a container.
-// Some fields are present in both SecurityContext and PodSecurityContext. When both
-// are set, the values in SecurityContext take precedence.
-type SecurityContext struct {
- // The capabilities to add/drop when running containers.
- // Defaults to the default set of capabilities granted by the container runtime.
- Capabilities *Capabilities `json:"capabilities,omitempty" protobuf:"bytes,1,opt,name=capabilities"`
- // Run container in privileged mode.
- // Processes in privileged containers are essentially equivalent to root on the host.
- // Defaults to false.
- Privileged *bool `json:"privileged,omitempty" protobuf:"varint,2,opt,name=privileged"`
- // The SELinux context to be applied to the container.
- // If unspecified, the container runtime will allocate a random SELinux context for each
- // container. May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- SELinuxOptions *SELinuxOptions `json:"seLinuxOptions,omitempty" protobuf:"bytes,3,opt,name=seLinuxOptions"`
- // The UID to run the entrypoint of the container process.
- // Defaults to user specified in image metadata if unspecified.
- // May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- RunAsUser *int64 `json:"runAsUser,omitempty" protobuf:"varint,4,opt,name=runAsUser"`
- // Indicates that the container must run as a non-root user.
- // If true, the Kubelet will validate the image at runtime to ensure that it
- // does not run as UID 0 (root) and fail to start the container if it does.
- // If unset or false, no such validation will be performed.
- // May also be set in PodSecurityContext. If set in both SecurityContext and
- // PodSecurityContext, the value specified in SecurityContext takes precedence.
- RunAsNonRoot *bool `json:"runAsNonRoot,omitempty" protobuf:"varint,5,opt,name=runAsNonRoot"`
- // Whether this container has a read-only root filesystem.
- // Default is false.
- ReadOnlyRootFilesystem *bool `json:"readOnlyRootFilesystem,omitempty" protobuf:"varint,6,opt,name=readOnlyRootFilesystem"`
-}
-
-// SELinuxOptions are the labels to be applied to the container
-type SELinuxOptions struct {
- // User is a SELinux user label that applies to the container.
- User string `json:"user,omitempty" protobuf:"bytes,1,opt,name=user"`
- // Role is a SELinux role label that applies to the container.
- Role string `json:"role,omitempty" protobuf:"bytes,2,opt,name=role"`
- // Type is a SELinux type label that applies to the container.
- Type string `json:"type,omitempty" protobuf:"bytes,3,opt,name=type"`
- // Level is SELinux level label that applies to the container.
- Level string `json:"level,omitempty" protobuf:"bytes,4,opt,name=level"`
-}
-
-// RangeAllocation is not a public type.
-type RangeAllocation struct {
- unversioned.TypeMeta `json:",inline"`
- // Standard object's metadata.
- // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
- ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
-
- // Range is string that identifies the range represented by 'data'.
- Range string `json:"range" protobuf:"bytes,2,opt,name=range"`
- // Data is a bit array containing all allocated addresses in the previous segment.
- Data []byte `json:"data" protobuf:"bytes,3,opt,name=data"`
-}
-
-const (
- // "default-scheduler" is the name of default scheduler.
- DefaultSchedulerName = "default-scheduler"
-)
diff --git a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types_swagger_doc_generated.go b/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types_swagger_doc_generated.go
deleted file mode 100644
index c5eb00d..0000000
--- a/kube2msb/src/vendor/k8s.io/kubernetes/pkg/api/v1/types_swagger_doc_generated.go
+++ /dev/null
@@ -1,1742 +0,0 @@
-/*
-Copyright 2016 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.
-*/
-
-package v1
-
-// This file contains a collection of methods that can be used from go-restful to
-// generate Swagger API documentation for its models. Please read this PR for more
-// information on the implementation: https://github.com/emicklei/go-restful/pull/215
-//
-// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if
-// they are on one line! For multiple line or blocks that you want to ignore use ---.
-// Any context after a --- is ignored.
-//
-// Those methods can be generated by using hack/update-generated-swagger-docs.sh
-
-// AUTO-GENERATED FUNCTIONS START HERE
-var map_AWSElasticBlockStoreVolumeSource = map[string]string{
- "": "Represents a Persistent Disk resource in AWS.\n\nAn AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling.",
- "volumeID": "Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore",
- "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore",
- "partition": "The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty).",
- "readOnly": "Specify \"true\" to force and set the ReadOnly property in VolumeMounts to \"true\". If omitted, the default is \"false\". More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore",
-}
-
-func (AWSElasticBlockStoreVolumeSource) SwaggerDoc() map[string]string {
- return map_AWSElasticBlockStoreVolumeSource
-}
-
-var map_Affinity = map[string]string{
- "": "Affinity is a group of affinity scheduling rules.",
- "nodeAffinity": "Describes node affinity scheduling rules for the pod.",
- "podAffinity": "Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).",
- "podAntiAffinity": "Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).",
-}
-
-func (Affinity) SwaggerDoc() map[string]string {
- return map_Affinity
-}
-
-var map_AttachedVolume = map[string]string{
- "": "AttachedVolume describes a volume attached to a node",
- "name": "Name of the attached volume",
- "devicePath": "DevicePath represents the device path where the volume should be avilable",
-}
-
-func (AttachedVolume) SwaggerDoc() map[string]string {
- return map_AttachedVolume
-}
-
-var map_AzureFileVolumeSource = map[string]string{
- "": "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.",
- "secretName": "the name of secret that contains Azure Storage Account Name and Key",
- "shareName": "Share Name",
- "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
-}
-
-func (AzureFileVolumeSource) SwaggerDoc() map[string]string {
- return map_AzureFileVolumeSource
-}
-
-var map_Binding = map[string]string{
- "": "Binding ties one object to another. For example, a pod is bound to a node by a scheduler.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "target": "The target object that you want to bind to the standard object.",
-}
-
-func (Binding) SwaggerDoc() map[string]string {
- return map_Binding
-}
-
-var map_Capabilities = map[string]string{
- "": "Adds and removes POSIX capabilities from running containers.",
- "add": "Added capabilities",
- "drop": "Removed capabilities",
-}
-
-func (Capabilities) SwaggerDoc() map[string]string {
- return map_Capabilities
-}
-
-var map_CephFSVolumeSource = map[string]string{
- "": "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.",
- "monitors": "Required: Monitors is a collection of Ceph monitors More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it",
- "path": "Optional: Used as the mounted root, rather than the full Ceph tree, default is /",
- "user": "Optional: User is the rados user name, default is admin More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it",
- "secretFile": "Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it",
- "secretRef": "Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it",
- "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it",
-}
-
-func (CephFSVolumeSource) SwaggerDoc() map[string]string {
- return map_CephFSVolumeSource
-}
-
-var map_CinderVolumeSource = map[string]string{
- "": "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.",
- "volumeID": "volume id used to identify the volume in cinder More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md",
- "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md",
- "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md",
-}
-
-func (CinderVolumeSource) SwaggerDoc() map[string]string {
- return map_CinderVolumeSource
-}
-
-var map_ComponentCondition = map[string]string{
- "": "Information about the condition of a component.",
- "type": "Type of condition for a component. Valid value: \"Healthy\"",
- "status": "Status of the condition for a component. Valid values for \"Healthy\": \"True\", \"False\", or \"Unknown\".",
- "message": "Message about the condition for a component. For example, information about a health check.",
- "error": "Condition error code for a component. For example, a health check error code.",
-}
-
-func (ComponentCondition) SwaggerDoc() map[string]string {
- return map_ComponentCondition
-}
-
-var map_ComponentStatus = map[string]string{
- "": "ComponentStatus (and ComponentStatusList) holds the cluster validation info.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "conditions": "List of component conditions observed",
-}
-
-func (ComponentStatus) SwaggerDoc() map[string]string {
- return map_ComponentStatus
-}
-
-var map_ComponentStatusList = map[string]string{
- "": "Status of all the conditions for the component as a list of ComponentStatus objects.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of ComponentStatus objects.",
-}
-
-func (ComponentStatusList) SwaggerDoc() map[string]string {
- return map_ComponentStatusList
-}
-
-var map_ConfigMap = map[string]string{
- "": "ConfigMap holds configuration data for pods to consume.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "data": "Data contains the configuration data. Each key must be a valid DNS_SUBDOMAIN with an optional leading dot.",
-}
-
-func (ConfigMap) SwaggerDoc() map[string]string {
- return map_ConfigMap
-}
-
-var map_ConfigMapKeySelector = map[string]string{
- "": "Selects a key from a ConfigMap.",
- "key": "The key to select.",
-}
-
-func (ConfigMapKeySelector) SwaggerDoc() map[string]string {
- return map_ConfigMapKeySelector
-}
-
-var map_ConfigMapList = map[string]string{
- "": "ConfigMapList is a resource containing a list of ConfigMap objects.",
- "metadata": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "items": "Items is the list of ConfigMaps.",
-}
-
-func (ConfigMapList) SwaggerDoc() map[string]string {
- return map_ConfigMapList
-}
-
-var map_ConfigMapVolumeSource = map[string]string{
- "": "Adapts a ConfigMap into a volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. ConfigMap volumes support ownership management and SELinux relabeling.",
- "items": "If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error. Paths must be relative and may not contain the '..' path or start with '..'.",
-}
-
-func (ConfigMapVolumeSource) SwaggerDoc() map[string]string {
- return map_ConfigMapVolumeSource
-}
-
-var map_Container = map[string]string{
- "": "A single application container that you want to run within a pod.",
- "name": "Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated.",
- "image": "Docker image name. More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md",
- "command": "Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands",
- "args": "Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md#containers-and-commands",
- "workingDir": "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.",
- "ports": "List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default \"0.0.0.0\" address inside a container will be accessible from the network. Cannot be updated.",
- "env": "List of environment variables to set in the container. Cannot be updated.",
- "resources": "Compute Resources required by this container. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources",
- "volumeMounts": "Pod volumes to mount into the container's filesystem. Cannot be updated.",
- "livenessProbe": "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes",
- "readinessProbe": "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes",
- "lifecycle": "Actions that the management system should take in response to container lifecycle events. Cannot be updated.",
- "terminationMessagePath": "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Defaults to /dev/termination-log. Cannot be updated.",
- "imagePullPolicy": "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#updating-images",
- "securityContext": "Security options the pod should run with. More info: http://releases.k8s.io/HEAD/docs/design/security_context.md",
- "stdin": "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.",
- "stdinOnce": "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false",
- "tty": "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.",
-}
-
-func (Container) SwaggerDoc() map[string]string {
- return map_Container
-}
-
-var map_ContainerImage = map[string]string{
- "": "Describe a container image",
- "names": "Names by which this image is known. e.g. [\"gcr.io/google_containers/hyperkube:v1.0.7\", \"dockerhub.io/google_containers/hyperkube:v1.0.7\"]",
- "sizeBytes": "The size of the image in bytes.",
-}
-
-func (ContainerImage) SwaggerDoc() map[string]string {
- return map_ContainerImage
-}
-
-var map_ContainerPort = map[string]string{
- "": "ContainerPort represents a network port in a single container.",
- "name": "If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services.",
- "hostPort": "Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this.",
- "containerPort": "Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536.",
- "protocol": "Protocol for port. Must be UDP or TCP. Defaults to \"TCP\".",
- "hostIP": "What host IP to bind the external port to.",
-}
-
-func (ContainerPort) SwaggerDoc() map[string]string {
- return map_ContainerPort
-}
-
-var map_ContainerState = map[string]string{
- "": "ContainerState holds a possible state of container. Only one of its members may be specified. If none of them is specified, the default one is ContainerStateWaiting.",
- "waiting": "Details about a waiting container",
- "running": "Details about a running container",
- "terminated": "Details about a terminated container",
-}
-
-func (ContainerState) SwaggerDoc() map[string]string {
- return map_ContainerState
-}
-
-var map_ContainerStateRunning = map[string]string{
- "": "ContainerStateRunning is a running state of a container.",
- "startedAt": "Time at which the container was last (re-)started",
-}
-
-func (ContainerStateRunning) SwaggerDoc() map[string]string {
- return map_ContainerStateRunning
-}
-
-var map_ContainerStateTerminated = map[string]string{
- "": "ContainerStateTerminated is a terminated state of a container.",
- "exitCode": "Exit status from the last termination of the container",
- "signal": "Signal from the last termination of the container",
- "reason": "(brief) reason from the last termination of the container",
- "message": "Message regarding the last termination of the container",
- "startedAt": "Time at which previous execution of the container started",
- "finishedAt": "Time at which the container last terminated",
- "containerID": "Container's ID in the format 'docker://<container_id>'",
-}
-
-func (ContainerStateTerminated) SwaggerDoc() map[string]string {
- return map_ContainerStateTerminated
-}
-
-var map_ContainerStateWaiting = map[string]string{
- "": "ContainerStateWaiting is a waiting state of a container.",
- "reason": "(brief) reason the container is not yet running.",
- "message": "Message regarding why the container is not yet running.",
-}
-
-func (ContainerStateWaiting) SwaggerDoc() map[string]string {
- return map_ContainerStateWaiting
-}
-
-var map_ContainerStatus = map[string]string{
- "": "ContainerStatus contains details for the current status of this container.",
- "name": "This must be a DNS_LABEL. Each container in a pod must have a unique name. Cannot be updated.",
- "state": "Details about the container's current condition.",
- "lastState": "Details about the container's last termination condition.",
- "ready": "Specifies whether the container has passed its readiness probe.",
- "restartCount": "The number of times the container has been restarted, currently based on the number of dead containers that have not yet been removed. Note that this is calculated from dead containers. But those containers are subject to garbage collection. This value will get capped at 5 by GC.",
- "image": "The image the container is running. More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md",
- "imageID": "ImageID of the container's image.",
- "containerID": "Container's ID in the format 'docker://<container_id>'. More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#container-information",
-}
-
-func (ContainerStatus) SwaggerDoc() map[string]string {
- return map_ContainerStatus
-}
-
-var map_DaemonEndpoint = map[string]string{
- "": "DaemonEndpoint contains information about a single Daemon endpoint.",
- "Port": "Port number of the given endpoint.",
-}
-
-func (DaemonEndpoint) SwaggerDoc() map[string]string {
- return map_DaemonEndpoint
-}
-
-var map_DeleteOptions = map[string]string{
- "": "DeleteOptions may be provided when deleting an API object",
- "gracePeriodSeconds": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.",
- "preconditions": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.",
- "orphanDependents": "Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list.",
-}
-
-func (DeleteOptions) SwaggerDoc() map[string]string {
- return map_DeleteOptions
-}
-
-var map_DownwardAPIVolumeFile = map[string]string{
- "": "DownwardAPIVolumeFile represents information to create the file containing the pod field",
- "path": "Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'",
- "fieldRef": "Required: Selects a field of the pod: only annotations, labels, name and namespace are supported.",
- "resourceFieldRef": "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.",
-}
-
-func (DownwardAPIVolumeFile) SwaggerDoc() map[string]string {
- return map_DownwardAPIVolumeFile
-}
-
-var map_DownwardAPIVolumeSource = map[string]string{
- "": "DownwardAPIVolumeSource represents a volume containing downward API info. Downward API volumes support ownership management and SELinux relabeling.",
- "items": "Items is a list of downward API volume file",
-}
-
-func (DownwardAPIVolumeSource) SwaggerDoc() map[string]string {
- return map_DownwardAPIVolumeSource
-}
-
-var map_EmptyDirVolumeSource = map[string]string{
- "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.",
- "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir",
-}
-
-func (EmptyDirVolumeSource) SwaggerDoc() map[string]string {
- return map_EmptyDirVolumeSource
-}
-
-var map_EndpointAddress = map[string]string{
- "": "EndpointAddress is a tuple that describes single IP address.",
- "ip": "The IP of this endpoint. May not be loopback (127.0.0.0/8), link-local (169.254.0.0/16), or link-local multicast ((224.0.0.0/24). IPv6 is also accepted but not fully supported on all platforms. Also, certain kubernetes components, like kube-proxy, are not IPv6 ready.",
- "hostname": "The Hostname of this endpoint",
- "targetRef": "Reference to object providing the endpoint.",
-}
-
-func (EndpointAddress) SwaggerDoc() map[string]string {
- return map_EndpointAddress
-}
-
-var map_EndpointPort = map[string]string{
- "": "EndpointPort is a tuple that describes a single port.",
- "name": "The name of this port (corresponds to ServicePort.Name). Must be a DNS_LABEL. Optional only if one port is defined.",
- "port": "The port number of the endpoint.",
- "protocol": "The IP protocol for this port. Must be UDP or TCP. Default is TCP.",
-}
-
-func (EndpointPort) SwaggerDoc() map[string]string {
- return map_EndpointPort
-}
-
-var map_EndpointSubset = map[string]string{
- "": "EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given:\n {\n Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n }\nThe resulting set of endpoints can be viewed as:\n a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],\n b: [ 10.10.1.1:309, 10.10.2.2:309 ]",
- "addresses": "IP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize.",
- "notReadyAddresses": "IP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check.",
- "ports": "Port numbers available on the related IP addresses.",
-}
-
-func (EndpointSubset) SwaggerDoc() map[string]string {
- return map_EndpointSubset
-}
-
-var map_Endpoints = map[string]string{
- "": "Endpoints is a collection of endpoints that implement the actual service. Example:\n Name: \"mysvc\",\n Subsets: [\n {\n Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n },\n {\n Addresses: [{\"ip\": \"10.10.3.3\"}],\n Ports: [{\"name\": \"a\", \"port\": 93}, {\"name\": \"b\", \"port\": 76}]\n },\n ]",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "subsets": "The set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service.",
-}
-
-func (Endpoints) SwaggerDoc() map[string]string {
- return map_Endpoints
-}
-
-var map_EndpointsList = map[string]string{
- "": "EndpointsList is a list of endpoints.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of endpoints.",
-}
-
-func (EndpointsList) SwaggerDoc() map[string]string {
- return map_EndpointsList
-}
-
-var map_EnvVar = map[string]string{
- "": "EnvVar represents an environment variable present in a Container.",
- "name": "Name of the environment variable. Must be a C_IDENTIFIER.",
- "value": "Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\".",
- "valueFrom": "Source for the environment variable's value. Cannot be used if value is not empty.",
-}
-
-func (EnvVar) SwaggerDoc() map[string]string {
- return map_EnvVar
-}
-
-var map_EnvVarSource = map[string]string{
- "": "EnvVarSource represents a source for the value of an EnvVar.",
- "fieldRef": "Selects a field of the pod; only name and namespace are supported.",
- "resourceFieldRef": "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.",
- "configMapKeyRef": "Selects a key of a ConfigMap.",
- "secretKeyRef": "Selects a key of a secret in the pod's namespace",
-}
-
-func (EnvVarSource) SwaggerDoc() map[string]string {
- return map_EnvVarSource
-}
-
-var map_Event = map[string]string{
- "": "Event is a report of an event somewhere in the cluster.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "involvedObject": "The object that this event is about.",
- "reason": "This should be a short, machine understandable string that gives the reason for the transition into the object's current status.",
- "message": "A human-readable description of the status of this operation.",
- "source": "The component reporting this event. Should be a short machine understandable string.",
- "firstTimestamp": "The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)",
- "lastTimestamp": "The time at which the most recent occurrence of this event was recorded.",
- "count": "The number of times this event has occurred.",
- "type": "Type of this event (Normal, Warning), new types could be added in the future",
-}
-
-func (Event) SwaggerDoc() map[string]string {
- return map_Event
-}
-
-var map_EventList = map[string]string{
- "": "EventList is a list of events.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of events",
-}
-
-func (EventList) SwaggerDoc() map[string]string {
- return map_EventList
-}
-
-var map_EventSource = map[string]string{
- "": "EventSource contains information for an event.",
- "component": "Component from which the event is generated.",
- "host": "Host name on which the event is generated.",
-}
-
-func (EventSource) SwaggerDoc() map[string]string {
- return map_EventSource
-}
-
-var map_ExecAction = map[string]string{
- "": "ExecAction describes a \"run in container\" action.",
- "command": "Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy.",
-}
-
-func (ExecAction) SwaggerDoc() map[string]string {
- return map_ExecAction
-}
-
-var map_ExportOptions = map[string]string{
- "": "ExportOptions is the query options to the standard REST get call.",
- "export": "Should this value be exported. Export strips fields that a user can not specify.",
- "exact": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'",
-}
-
-func (ExportOptions) SwaggerDoc() map[string]string {
- return map_ExportOptions
-}
-
-var map_FCVolumeSource = map[string]string{
- "": "Represents a Fibre Channel volume. Fibre Channel volumes can only be mounted as read/write once. Fibre Channel volumes support ownership management and SELinux relabeling.",
- "targetWWNs": "Required: FC target world wide names (WWNs)",
- "lun": "Required: FC target lun number",
- "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
- "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
-}
-
-func (FCVolumeSource) SwaggerDoc() map[string]string {
- return map_FCVolumeSource
-}
-
-var map_FlexVolumeSource = map[string]string{
- "": "FlexVolume represents a generic volume resource that is provisioned/attached using a exec based plugin. This is an alpha feature and may change in future.",
- "driver": "Driver is the name of the driver to use for this volume.",
- "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default filesystem depends on FlexVolume script.",
- "secretRef": "Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.",
- "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
- "options": "Optional: Extra command options if any.",
-}
-
-func (FlexVolumeSource) SwaggerDoc() map[string]string {
- return map_FlexVolumeSource
-}
-
-var map_FlockerVolumeSource = map[string]string{
- "": "Represents a Flocker volume mounted by the Flocker agent. Flocker volumes do not support ownership management or SELinux relabeling.",
- "datasetName": "Required: the volume name. This is going to be store on metadata -> name on the payload for Flocker",
-}
-
-func (FlockerVolumeSource) SwaggerDoc() map[string]string {
- return map_FlockerVolumeSource
-}
-
-var map_GCEPersistentDiskVolumeSource = map[string]string{
- "": "Represents a Persistent Disk resource in Google Compute Engine.\n\nA GCE PD must exist before mounting to a container. The disk must also be in the same GCE project and zone as the kubelet. A GCE PD can only be mounted as read/write once or read-only many times. GCE PDs support ownership management and SELinux relabeling.",
- "pdName": "Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
- "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
- "partition": "The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty). More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
- "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
-}
-
-func (GCEPersistentDiskVolumeSource) SwaggerDoc() map[string]string {
- return map_GCEPersistentDiskVolumeSource
-}
-
-var map_GitRepoVolumeSource = map[string]string{
- "": "Represents a volume that is populated with the contents of a git repository. Git repo volumes do not support ownership management. Git repo volumes support SELinux relabeling.",
- "repository": "Repository URL",
- "revision": "Commit hash for the specified revision.",
- "directory": "Target directory name. Must not contain or start with '..'. If '.' is supplied, the volume directory will be the git repository. Otherwise, if specified, the volume will contain the git repository in the subdirectory with the given name.",
-}
-
-func (GitRepoVolumeSource) SwaggerDoc() map[string]string {
- return map_GitRepoVolumeSource
-}
-
-var map_GlusterfsVolumeSource = map[string]string{
- "": "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.",
- "endpoints": "EndpointsName is the endpoint name that details Glusterfs topology. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod",
- "path": "Path is the Glusterfs volume path. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod",
- "readOnly": "ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod",
-}
-
-func (GlusterfsVolumeSource) SwaggerDoc() map[string]string {
- return map_GlusterfsVolumeSource
-}
-
-var map_HTTPGetAction = map[string]string{
- "": "HTTPGetAction describes an action based on HTTP Get requests.",
- "path": "Path to access on the HTTP server.",
- "port": "Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.",
- "host": "Host name to connect to, defaults to the pod IP. You probably want to set \"Host\" in httpHeaders instead.",
- "scheme": "Scheme to use for connecting to the host. Defaults to HTTP.",
- "httpHeaders": "Custom headers to set in the request. HTTP allows repeated headers.",
-}
-
-func (HTTPGetAction) SwaggerDoc() map[string]string {
- return map_HTTPGetAction
-}
-
-var map_HTTPHeader = map[string]string{
- "": "HTTPHeader describes a custom header to be used in HTTP probes",
- "name": "The header field name",
- "value": "The header field value",
-}
-
-func (HTTPHeader) SwaggerDoc() map[string]string {
- return map_HTTPHeader
-}
-
-var map_Handler = map[string]string{
- "": "Handler defines a specific action that should be taken",
- "exec": "One and only one of the following should be specified. Exec specifies the action to take.",
- "httpGet": "HTTPGet specifies the http request to perform.",
- "tcpSocket": "TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported",
-}
-
-func (Handler) SwaggerDoc() map[string]string {
- return map_Handler
-}
-
-var map_HostPathVolumeSource = map[string]string{
- "": "Represents a host path mapped into a pod. Host path volumes do not support ownership management or SELinux relabeling.",
- "path": "Path of the directory on the host. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath",
-}
-
-func (HostPathVolumeSource) SwaggerDoc() map[string]string {
- return map_HostPathVolumeSource
-}
-
-var map_ISCSIVolumeSource = map[string]string{
- "": "Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.",
- "targetPortal": "iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).",
- "iqn": "Target iSCSI Qualified Name.",
- "lun": "iSCSI target lun number.",
- "iscsiInterface": "Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport.",
- "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#iscsi",
- "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.",
-}
-
-func (ISCSIVolumeSource) SwaggerDoc() map[string]string {
- return map_ISCSIVolumeSource
-}
-
-var map_KeyToPath = map[string]string{
- "": "Maps a string key to a path within a volume.",
- "key": "The key to project.",
- "path": "The relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.",
-}
-
-func (KeyToPath) SwaggerDoc() map[string]string {
- return map_KeyToPath
-}
-
-var map_Lifecycle = map[string]string{
- "": "Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted.",
- "postStart": "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details",
- "preStop": "PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: http://releases.k8s.io/HEAD/docs/user-guide/container-environment.md#hook-details",
-}
-
-func (Lifecycle) SwaggerDoc() map[string]string {
- return map_Lifecycle
-}
-
-var map_LimitRange = map[string]string{
- "": "LimitRange sets resource usage limits for each kind of resource in a Namespace.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the limits enforced. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (LimitRange) SwaggerDoc() map[string]string {
- return map_LimitRange
-}
-
-var map_LimitRangeItem = map[string]string{
- "": "LimitRangeItem defines a min/max usage limit for any resource that matches on kind.",
- "type": "Type of resource that this limit applies to.",
- "max": "Max usage constraints on this kind by resource name.",
- "min": "Min usage constraints on this kind by resource name.",
- "default": "Default resource requirement limit value by resource name if resource limit is omitted.",
- "defaultRequest": "DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.",
- "maxLimitRequestRatio": "MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.",
-}
-
-func (LimitRangeItem) SwaggerDoc() map[string]string {
- return map_LimitRangeItem
-}
-
-var map_LimitRangeList = map[string]string{
- "": "LimitRangeList is a list of LimitRange items.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "Items is a list of LimitRange objects. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md",
-}
-
-func (LimitRangeList) SwaggerDoc() map[string]string {
- return map_LimitRangeList
-}
-
-var map_LimitRangeSpec = map[string]string{
- "": "LimitRangeSpec defines a min/max usage limit for resources that match on kind.",
- "limits": "Limits is the list of LimitRangeItem objects that are enforced.",
-}
-
-func (LimitRangeSpec) SwaggerDoc() map[string]string {
- return map_LimitRangeSpec
-}
-
-var map_List = map[string]string{
- "": "List holds a list of objects, which may not be known by the server.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of objects",
-}
-
-func (List) SwaggerDoc() map[string]string {
- return map_List
-}
-
-var map_ListOptions = map[string]string{
- "": "ListOptions is the query options to a standard REST list call.",
- "labelSelector": "A selector to restrict the list of returned objects by their labels. Defaults to everything.",
- "fieldSelector": "A selector to restrict the list of returned objects by their fields. Defaults to everything.",
- "watch": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.",
- "resourceVersion": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history.",
- "timeoutSeconds": "Timeout for the list/watch call.",
-}
-
-func (ListOptions) SwaggerDoc() map[string]string {
- return map_ListOptions
-}
-
-var map_LoadBalancerIngress = map[string]string{
- "": "LoadBalancerIngress represents the status of a load-balancer ingress point: traffic intended for the service should be sent to an ingress point.",
- "ip": "IP is set for load-balancer ingress points that are IP based (typically GCE or OpenStack load-balancers)",
- "hostname": "Hostname is set for load-balancer ingress points that are DNS based (typically AWS load-balancers)",
-}
-
-func (LoadBalancerIngress) SwaggerDoc() map[string]string {
- return map_LoadBalancerIngress
-}
-
-var map_LoadBalancerStatus = map[string]string{
- "": "LoadBalancerStatus represents the status of a load-balancer.",
- "ingress": "Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points.",
-}
-
-func (LoadBalancerStatus) SwaggerDoc() map[string]string {
- return map_LoadBalancerStatus
-}
-
-var map_LocalObjectReference = map[string]string{
- "": "LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace.",
- "name": "Name of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names",
-}
-
-func (LocalObjectReference) SwaggerDoc() map[string]string {
- return map_LocalObjectReference
-}
-
-var map_NFSVolumeSource = map[string]string{
- "": "Represents an NFS mount that lasts the lifetime of a pod. NFS volumes do not support ownership management or SELinux relabeling.",
- "server": "Server is the hostname or IP address of the NFS server. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs",
- "path": "Path that is exported by the NFS server. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs",
- "readOnly": "ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs",
-}
-
-func (NFSVolumeSource) SwaggerDoc() map[string]string {
- return map_NFSVolumeSource
-}
-
-var map_Namespace = map[string]string{
- "": "Namespace provides a scope for Names. Use of multiple namespaces is optional.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the behavior of the Namespace. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Status describes the current status of a Namespace. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (Namespace) SwaggerDoc() map[string]string {
- return map_Namespace
-}
-
-var map_NamespaceList = map[string]string{
- "": "NamespaceList is a list of Namespaces.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "Items is the list of Namespace objects in the list. More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md",
-}
-
-func (NamespaceList) SwaggerDoc() map[string]string {
- return map_NamespaceList
-}
-
-var map_NamespaceSpec = map[string]string{
- "": "NamespaceSpec describes the attributes on a Namespace.",
- "finalizers": "Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers",
-}
-
-func (NamespaceSpec) SwaggerDoc() map[string]string {
- return map_NamespaceSpec
-}
-
-var map_NamespaceStatus = map[string]string{
- "": "NamespaceStatus is information about the current status of a Namespace.",
- "phase": "Phase is the current lifecycle phase of the namespace. More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases",
-}
-
-func (NamespaceStatus) SwaggerDoc() map[string]string {
- return map_NamespaceStatus
-}
-
-var map_Node = map[string]string{
- "": "Node is a worker node in Kubernetes, formerly known as minion. Each node will have a unique identifier in the cache (i.e. in etcd).",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the behavior of a node. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Most recently observed status of the node. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (Node) SwaggerDoc() map[string]string {
- return map_Node
-}
-
-var map_NodeAddress = map[string]string{
- "": "NodeAddress contains information for the node's address.",
- "type": "Node address type, one of Hostname, ExternalIP or InternalIP.",
- "address": "The node address.",
-}
-
-func (NodeAddress) SwaggerDoc() map[string]string {
- return map_NodeAddress
-}
-
-var map_NodeAffinity = map[string]string{
- "": "Node affinity is a group of node affinity scheduling rules.",
- "requiredDuringSchedulingIgnoredDuringExecution": "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node.",
- "preferredDuringSchedulingIgnoredDuringExecution": "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred.",
-}
-
-func (NodeAffinity) SwaggerDoc() map[string]string {
- return map_NodeAffinity
-}
-
-var map_NodeCondition = map[string]string{
- "": "NodeCondition contains condition infromation for a node.",
- "type": "Type of node condition.",
- "status": "Status of the condition, one of True, False, Unknown.",
- "lastHeartbeatTime": "Last time we got an update on a given condition.",
- "lastTransitionTime": "Last time the condition transit from one status to another.",
- "reason": "(brief) reason for the condition's last transition.",
- "message": "Human readable message indicating details about last transition.",
-}
-
-func (NodeCondition) SwaggerDoc() map[string]string {
- return map_NodeCondition
-}
-
-var map_NodeDaemonEndpoints = map[string]string{
- "": "NodeDaemonEndpoints lists ports opened by daemons running on the Node.",
- "kubeletEndpoint": "Endpoint on which Kubelet is listening.",
-}
-
-func (NodeDaemonEndpoints) SwaggerDoc() map[string]string {
- return map_NodeDaemonEndpoints
-}
-
-var map_NodeList = map[string]string{
- "": "NodeList is the whole list of all Nodes which have been registered with master.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of nodes",
-}
-
-func (NodeList) SwaggerDoc() map[string]string {
- return map_NodeList
-}
-
-var map_NodeProxyOptions = map[string]string{
- "": "NodeProxyOptions is the query options to a Node's proxy call.",
- "path": "Path is the URL path to use for the current proxy request to node.",
-}
-
-func (NodeProxyOptions) SwaggerDoc() map[string]string {
- return map_NodeProxyOptions
-}
-
-var map_NodeSelector = map[string]string{
- "": "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.",
- "nodeSelectorTerms": "Required. A list of node selector terms. The terms are ORed.",
-}
-
-func (NodeSelector) SwaggerDoc() map[string]string {
- return map_NodeSelector
-}
-
-var map_NodeSelectorRequirement = map[string]string{
- "": "A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.",
- "key": "The label key that the selector applies to.",
- "operator": "Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.",
- "values": "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.",
-}
-
-func (NodeSelectorRequirement) SwaggerDoc() map[string]string {
- return map_NodeSelectorRequirement
-}
-
-var map_NodeSelectorTerm = map[string]string{
- "": "A null or empty node selector term matches no objects.",
- "matchExpressions": "Required. A list of node selector requirements. The requirements are ANDed.",
-}
-
-func (NodeSelectorTerm) SwaggerDoc() map[string]string {
- return map_NodeSelectorTerm
-}
-
-var map_NodeSpec = map[string]string{
- "": "NodeSpec describes the attributes that a node is created with.",
- "podCIDR": "PodCIDR represents the pod IP range assigned to the node.",
- "externalID": "External ID of the node assigned by some machine database (e.g. a cloud provider). Deprecated.",
- "providerID": "ID of the node assigned by the cloud provider in the format: <ProviderName>://<ProviderSpecificNodeID>",
- "unschedulable": "Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration\"`",
-}
-
-func (NodeSpec) SwaggerDoc() map[string]string {
- return map_NodeSpec
-}
-
-var map_NodeStatus = map[string]string{
- "": "NodeStatus is information about the current status of a node.",
- "capacity": "Capacity represents the total resources of a node. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity for more details.",
- "allocatable": "Allocatable represents the resources of a node that are available for scheduling. Defaults to Capacity.",
- "phase": "NodePhase is the recently observed lifecycle phase of the node. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase",
- "conditions": "Conditions is an array of current observed node conditions. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition",
- "addresses": "List of addresses reachable to the node. Queried from cloud provider, if available. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses",
- "daemonEndpoints": "Endpoints of daemons running on the Node.",
- "nodeInfo": "Set of ids/uuids to uniquely identify the node. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info",
- "images": "List of container images on this node",
- "volumesInUse": "List of attachable volumes in use (mounted) by the node.",
- "volumesAttached": "List of volumes that are attached to the node.",
-}
-
-func (NodeStatus) SwaggerDoc() map[string]string {
- return map_NodeStatus
-}
-
-var map_NodeSystemInfo = map[string]string{
- "": "NodeSystemInfo is a set of ids/uuids to uniquely identify the node.",
- "machineID": "Machine ID reported by the node.",
- "systemUUID": "System UUID reported by the node.",
- "bootID": "Boot ID reported by the node.",
- "kernelVersion": "Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).",
- "osImage": "OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).",
- "containerRuntimeVersion": "ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0).",
- "kubeletVersion": "Kubelet Version reported by the node.",
- "kubeProxyVersion": "KubeProxy Version reported by the node.",
- "operatingSystem": "The Operating System reported by the node",
- "architecture": "The Architecture reported by the node",
-}
-
-func (NodeSystemInfo) SwaggerDoc() map[string]string {
- return map_NodeSystemInfo
-}
-
-var map_ObjectFieldSelector = map[string]string{
- "": "ObjectFieldSelector selects an APIVersioned field of an object.",
- "apiVersion": "Version of the schema the FieldPath is written in terms of, defaults to \"v1\".",
- "fieldPath": "Path of the field to select in the specified API version.",
-}
-
-func (ObjectFieldSelector) SwaggerDoc() map[string]string {
- return map_ObjectFieldSelector
-}
-
-var map_ObjectMeta = map[string]string{
- "": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.",
- "name": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names",
- "generateName": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency",
- "namespace": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md",
- "selfLink": "SelfLink is a URL representing this object. Populated by the system. Read-only.",
- "uid": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids",
- "resourceVersion": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency",
- "generation": "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.",
- "creationTimestamp": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "deletionTimestamp": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource will be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. Once the resource is deleted in the API, the Kubelet will send a hard termination signal to the container. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "deletionGracePeriodSeconds": "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.",
- "labels": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md",
- "annotations": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://releases.k8s.io/HEAD/docs/user-guide/annotations.md",
- "ownerReferences": "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.",
- "finalizers": "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed.",
-}
-
-func (ObjectMeta) SwaggerDoc() map[string]string {
- return map_ObjectMeta
-}
-
-var map_ObjectReference = map[string]string{
- "": "ObjectReference contains enough information to let you inspect or modify the referred object.",
- "kind": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "namespace": "Namespace of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/namespaces.md",
- "name": "Name of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names",
- "uid": "UID of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids",
- "apiVersion": "API version of the referent.",
- "resourceVersion": "Specific resourceVersion to which this reference is made, if any. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency",
- "fieldPath": "If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: \"spec.containers{name}\" (where \"name\" refers to the name of the container that triggered the event) or if no container name is specified \"spec.containers[2]\" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object.",
-}
-
-func (ObjectReference) SwaggerDoc() map[string]string {
- return map_ObjectReference
-}
-
-var map_OwnerReference = map[string]string{
- "": "OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.",
- "apiVersion": "API version of the referent.",
- "kind": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "name": "Name of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names",
- "uid": "UID of the referent. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#uids",
- "controller": "If true, this reference points to the managing controller.",
-}
-
-func (OwnerReference) SwaggerDoc() map[string]string {
- return map_OwnerReference
-}
-
-var map_PersistentVolume = map[string]string{
- "": "PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes",
- "status": "Status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistent-volumes",
-}
-
-func (PersistentVolume) SwaggerDoc() map[string]string {
- return map_PersistentVolume
-}
-
-var map_PersistentVolumeClaim = map[string]string{
- "": "PersistentVolumeClaim is a user's request for and claim to a persistent volume",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the desired characteristics of a volume requested by a pod author. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims",
- "status": "Status represents the current information/status of a persistent volume claim. Read-only. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims",
-}
-
-func (PersistentVolumeClaim) SwaggerDoc() map[string]string {
- return map_PersistentVolumeClaim
-}
-
-var map_PersistentVolumeClaimList = map[string]string{
- "": "PersistentVolumeClaimList is a list of PersistentVolumeClaim items.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "A list of persistent volume claims. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims",
-}
-
-func (PersistentVolumeClaimList) SwaggerDoc() map[string]string {
- return map_PersistentVolumeClaimList
-}
-
-var map_PersistentVolumeClaimSpec = map[string]string{
- "": "PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes",
- "accessModes": "AccessModes contains the desired access modes the volume should have. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1",
- "selector": "A label query over volumes to consider for binding.",
- "resources": "Resources represents the minimum resources the volume should have. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#resources",
- "volumeName": "VolumeName is the binding reference to the PersistentVolume backing this claim.",
-}
-
-func (PersistentVolumeClaimSpec) SwaggerDoc() map[string]string {
- return map_PersistentVolumeClaimSpec
-}
-
-var map_PersistentVolumeClaimStatus = map[string]string{
- "": "PersistentVolumeClaimStatus is the current status of a persistent volume claim.",
- "phase": "Phase represents the current phase of PersistentVolumeClaim.",
- "accessModes": "AccessModes contains the actual access modes the volume backing the PVC has. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes-1",
- "capacity": "Represents the actual resources of the underlying volume.",
-}
-
-func (PersistentVolumeClaimStatus) SwaggerDoc() map[string]string {
- return map_PersistentVolumeClaimStatus
-}
-
-var map_PersistentVolumeClaimVolumeSource = map[string]string{
- "": "PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. This volume finds the bound PV and mounts that volume for the pod. A PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another type of volume that is owned by someone else (the system).",
- "claimName": "ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims",
- "readOnly": "Will force the ReadOnly setting in VolumeMounts. Default false.",
-}
-
-func (PersistentVolumeClaimVolumeSource) SwaggerDoc() map[string]string {
- return map_PersistentVolumeClaimVolumeSource
-}
-
-var map_PersistentVolumeList = map[string]string{
- "": "PersistentVolumeList is a list of PersistentVolume items.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of persistent volumes. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md",
-}
-
-func (PersistentVolumeList) SwaggerDoc() map[string]string {
- return map_PersistentVolumeList
-}
-
-var map_PersistentVolumeSource = map[string]string{
- "": "PersistentVolumeSource is similar to VolumeSource but meant for the administrator who creates PVs. Exactly one of its members must be set.",
- "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
- "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore",
- "hostPath": "HostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath",
- "glusterfs": "Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md",
- "nfs": "NFS represents an NFS mount on the host. Provisioned by an admin. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs",
- "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md",
- "iscsi": "ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.",
- "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md",
- "cephfs": "CephFS represents a Ceph FS mount on the host that shares a pod's lifetime",
- "fc": "FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.",
- "flocker": "Flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running",
- "flexVolume": "FlexVolume represents a generic volume resource that is provisioned/attached using a exec based plugin. This is an alpha feature and may change in future.",
- "azureFile": "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.",
- "vsphereVolume": "VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine",
-}
-
-func (PersistentVolumeSource) SwaggerDoc() map[string]string {
- return map_PersistentVolumeSource
-}
-
-var map_PersistentVolumeSpec = map[string]string{
- "": "PersistentVolumeSpec is the specification of a persistent volume.",
- "capacity": "A description of the persistent volume's resources and capacity. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#capacity",
- "accessModes": "AccessModes contains all ways the volume can be mounted. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#access-modes",
- "claimRef": "ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#binding",
- "persistentVolumeReclaimPolicy": "What happens to a persistent volume when released from its claim. Valid options are Retain (default) and Recycle. Recyling must be supported by the volume plugin underlying this persistent volume. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#recycling-policy",
-}
-
-func (PersistentVolumeSpec) SwaggerDoc() map[string]string {
- return map_PersistentVolumeSpec
-}
-
-var map_PersistentVolumeStatus = map[string]string{
- "": "PersistentVolumeStatus is the current status of a persistent volume.",
- "phase": "Phase indicates if a volume is available, bound to a claim, or released by a claim. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#phase",
- "message": "A human-readable message indicating details about why the volume is in this state.",
- "reason": "Reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI.",
-}
-
-func (PersistentVolumeStatus) SwaggerDoc() map[string]string {
- return map_PersistentVolumeStatus
-}
-
-var map_Pod = map[string]string{
- "": "Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Specification of the desired behavior of the pod. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (Pod) SwaggerDoc() map[string]string {
- return map_Pod
-}
-
-var map_PodAffinity = map[string]string{
- "": "Pod affinity is a group of inter pod affinity scheduling rules.",
- "requiredDuringSchedulingIgnoredDuringExecution": "NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:\"requiredDuringSchedulingRequiredDuringExecution,omitempty\"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.",
- "preferredDuringSchedulingIgnoredDuringExecution": "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.",
-}
-
-func (PodAffinity) SwaggerDoc() map[string]string {
- return map_PodAffinity
-}
-
-var map_PodAffinityTerm = map[string]string{
- "": "Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key <topologyKey> tches that of any node on which a pod of the set of pods is running",
- "labelSelector": "A label query over a set of resources, in this case pods.",
- "namespaces": "namespaces specifies which namespaces the labelSelector applies to (matches against); nil list means \"this pod's namespace,\" empty list means \"all namespaces\" The json tag here is not \"omitempty\" since we need to distinguish nil and empty. See https://golang.org/pkg/encoding/json/#Marshal for more details.",
- "topologyKey": "This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as \"all topologies\" (\"all topologies\" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed.",
-}
-
-func (PodAffinityTerm) SwaggerDoc() map[string]string {
- return map_PodAffinityTerm
-}
-
-var map_PodAntiAffinity = map[string]string{
- "": "Pod anti affinity is a group of inter pod anti affinity scheduling rules.",
- "requiredDuringSchedulingIgnoredDuringExecution": "NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:\"requiredDuringSchedulingRequiredDuringExecution,omitempty\"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.",
- "preferredDuringSchedulingIgnoredDuringExecution": "The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.",
-}
-
-func (PodAntiAffinity) SwaggerDoc() map[string]string {
- return map_PodAntiAffinity
-}
-
-var map_PodAttachOptions = map[string]string{
- "": "PodAttachOptions is the query options to a Pod's remote attach call.",
- "stdin": "Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.",
- "stdout": "Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.",
- "stderr": "Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.",
- "tty": "TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.",
- "container": "The container in which to execute the command. Defaults to only container if there is only one container in the pod.",
-}
-
-func (PodAttachOptions) SwaggerDoc() map[string]string {
- return map_PodAttachOptions
-}
-
-var map_PodCondition = map[string]string{
- "": "PodCondition contains details for the current condition of this pod.",
- "type": "Type is the type of the condition. Currently only Ready. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions",
- "status": "Status is the status of the condition. Can be True, False, Unknown. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions",
- "lastProbeTime": "Last time we probed the condition.",
- "lastTransitionTime": "Last time the condition transitioned from one status to another.",
- "reason": "Unique, one-word, CamelCase reason for the condition's last transition.",
- "message": "Human-readable message indicating details about last transition.",
-}
-
-func (PodCondition) SwaggerDoc() map[string]string {
- return map_PodCondition
-}
-
-var map_PodExecOptions = map[string]string{
- "": "PodExecOptions is the query options to a Pod's remote exec call.",
- "stdin": "Redirect the standard input stream of the pod for this call. Defaults to false.",
- "stdout": "Redirect the standard output stream of the pod for this call. Defaults to true.",
- "stderr": "Redirect the standard error stream of the pod for this call. Defaults to true.",
- "tty": "TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.",
- "container": "Container in which to execute the command. Defaults to only container if there is only one container in the pod.",
- "command": "Command is the remote command to execute. argv array. Not executed within a shell.",
-}
-
-func (PodExecOptions) SwaggerDoc() map[string]string {
- return map_PodExecOptions
-}
-
-var map_PodList = map[string]string{
- "": "PodList is a list of Pods.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of pods. More info: http://releases.k8s.io/HEAD/docs/user-guide/pods.md",
-}
-
-func (PodList) SwaggerDoc() map[string]string {
- return map_PodList
-}
-
-var map_PodLogOptions = map[string]string{
- "": "PodLogOptions is the query options for a Pod's logs REST call.",
- "container": "The container for which to stream logs. Defaults to only container if there is one container in the pod.",
- "follow": "Follow the log stream of the pod. Defaults to false.",
- "previous": "Return previous terminated container logs. Defaults to false.",
- "sinceSeconds": "A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.",
- "sinceTime": "An RFC3339 timestamp from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.",
- "timestamps": "If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.",
- "tailLines": "If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime",
- "limitBytes": "If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.",
-}
-
-func (PodLogOptions) SwaggerDoc() map[string]string {
- return map_PodLogOptions
-}
-
-var map_PodProxyOptions = map[string]string{
- "": "PodProxyOptions is the query options to a Pod's proxy call.",
- "path": "Path is the URL path to use for the current proxy request to pod.",
-}
-
-func (PodProxyOptions) SwaggerDoc() map[string]string {
- return map_PodProxyOptions
-}
-
-var map_PodSecurityContext = map[string]string{
- "": "PodSecurityContext holds pod-level security attributes and common container settings. Some fields are also present in container.securityContext. Field values of container.securityContext take precedence over field values of PodSecurityContext.",
- "seLinuxOptions": "The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container.",
- "runAsUser": "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container.",
- "runAsNonRoot": "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.",
- "supplementalGroups": "A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container.",
- "fsGroup": "A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod:\n\n1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw ",
-}
-
-func (PodSecurityContext) SwaggerDoc() map[string]string {
- return map_PodSecurityContext
-}
-
-var map_PodSpec = map[string]string{
- "": "PodSpec is a description of a pod.",
- "volumes": "List of volumes that can be mounted by containers belonging to the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md",
- "containers": "List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/containers.md",
- "restartPolicy": "Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#restartpolicy",
- "terminationGracePeriodSeconds": "Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds.",
- "activeDeadlineSeconds": "Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer.",
- "dnsPolicy": "Set DNS policy for containers within the pod. One of 'ClusterFirst' or 'Default'. Defaults to \"ClusterFirst\".",
- "nodeSelector": "NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: http://releases.k8s.io/HEAD/docs/user-guide/node-selection/README.md",
- "serviceAccountName": "ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md",
- "serviceAccount": "DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead.",
- "nodeName": "NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements.",
- "hostNetwork": "Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false.",
- "hostPID": "Use the host's pid namespace. Optional: Default to false.",
- "hostIPC": "Use the host's ipc namespace. Optional: Default to false.",
- "securityContext": "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.",
- "imagePullSecrets": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: http://releases.k8s.io/HEAD/docs/user-guide/images.md#specifying-imagepullsecrets-on-a-pod",
- "hostname": "Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value.",
- "subdomain": "If specified, the fully qualified Pod hostname will be \"<hostname>.<subdomain>.<pod namespace>.svc.<cluster domain>\". If not specified, the pod will not have a domainname at all.",
-}
-
-func (PodSpec) SwaggerDoc() map[string]string {
- return map_PodSpec
-}
-
-var map_PodStatus = map[string]string{
- "": "PodStatus represents information about the status of a pod. Status may trail the actual state of a system.",
- "phase": "Current condition of the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-phase",
- "conditions": "Current service state of pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#pod-conditions",
- "message": "A human readable message indicating details about why the pod is in this condition.",
- "reason": "A brief CamelCase message indicating details about why the pod is in this state. e.g. 'OutOfDisk'",
- "hostIP": "IP address of the host to which the pod is assigned. Empty if not yet scheduled.",
- "podIP": "IP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated.",
- "startTime": "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.",
- "containerStatuses": "The list has one entry per container in the manifest. Each entry is currently the output of `docker inspect`. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-statuses",
-}
-
-func (PodStatus) SwaggerDoc() map[string]string {
- return map_PodStatus
-}
-
-var map_PodStatusResult = map[string]string{
- "": "PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (PodStatusResult) SwaggerDoc() map[string]string {
- return map_PodStatusResult
-}
-
-var map_PodTemplate = map[string]string{
- "": "PodTemplate describes a template for creating copies of a predefined pod.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "template": "Template defines the pods that will be created from this pod template. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (PodTemplate) SwaggerDoc() map[string]string {
- return map_PodTemplate
-}
-
-var map_PodTemplateList = map[string]string{
- "": "PodTemplateList is a list of PodTemplates.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of pod templates",
-}
-
-func (PodTemplateList) SwaggerDoc() map[string]string {
- return map_PodTemplateList
-}
-
-var map_PodTemplateSpec = map[string]string{
- "": "PodTemplateSpec describes the data a pod should have when created from a template",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Specification of the desired behavior of the pod. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (PodTemplateSpec) SwaggerDoc() map[string]string {
- return map_PodTemplateSpec
-}
-
-var map_Preconditions = map[string]string{
- "": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.",
- "uid": "Specifies the target UID.",
-}
-
-func (Preconditions) SwaggerDoc() map[string]string {
- return map_Preconditions
-}
-
-var map_PreferredSchedulingTerm = map[string]string{
- "": "An empty preferred scheduling term matches all objects with implicit weight 0 (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).",
- "weight": "Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.",
- "preference": "A node selector term, associated with the corresponding weight.",
-}
-
-func (PreferredSchedulingTerm) SwaggerDoc() map[string]string {
- return map_PreferredSchedulingTerm
-}
-
-var map_Probe = map[string]string{
- "": "Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.",
- "initialDelaySeconds": "Number of seconds after the container has started before liveness probes are initiated. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes",
- "timeoutSeconds": "Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: http://releases.k8s.io/HEAD/docs/user-guide/pod-states.md#container-probes",
- "periodSeconds": "How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1.",
- "successThreshold": "Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1.",
- "failureThreshold": "Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1.",
-}
-
-func (Probe) SwaggerDoc() map[string]string {
- return map_Probe
-}
-
-var map_RBDVolumeSource = map[string]string{
- "": "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.",
- "monitors": "A collection of Ceph monitors. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
- "image": "The rados image name. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
- "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#rbd",
- "pool": "The rados pool name. Default is rbd. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it.",
- "user": "The rados user name. Default is admin. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
- "keyring": "Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
- "secretRef": "SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
- "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it",
-}
-
-func (RBDVolumeSource) SwaggerDoc() map[string]string {
- return map_RBDVolumeSource
-}
-
-var map_RangeAllocation = map[string]string{
- "": "RangeAllocation is not a public type.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "range": "Range is string that identifies the range represented by 'data'.",
- "data": "Data is a bit array containing all allocated addresses in the previous segment.",
-}
-
-func (RangeAllocation) SwaggerDoc() map[string]string {
- return map_RangeAllocation
-}
-
-var map_ReplicationController = map[string]string{
- "": "ReplicationController represents the configuration of a replication controller.",
- "metadata": "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the specification of the desired behavior of the replication controller. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (ReplicationController) SwaggerDoc() map[string]string {
- return map_ReplicationController
-}
-
-var map_ReplicationControllerList = map[string]string{
- "": "ReplicationControllerList is a collection of replication controllers.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of replication controllers. More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md",
-}
-
-func (ReplicationControllerList) SwaggerDoc() map[string]string {
- return map_ReplicationControllerList
-}
-
-var map_ReplicationControllerSpec = map[string]string{
- "": "ReplicationControllerSpec is the specification of a replication controller.",
- "replicas": "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller",
- "selector": "Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors",
- "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template",
-}
-
-func (ReplicationControllerSpec) SwaggerDoc() map[string]string {
- return map_ReplicationControllerSpec
-}
-
-var map_ReplicationControllerStatus = map[string]string{
- "": "ReplicationControllerStatus represents the current status of a replication controller.",
- "replicas": "Replicas is the most recently oberved number of replicas. More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller",
- "fullyLabeledReplicas": "The number of pods that have labels matching the labels of the pod template of the replication controller.",
- "observedGeneration": "ObservedGeneration reflects the generation of the most recently observed replication controller.",
-}
-
-func (ReplicationControllerStatus) SwaggerDoc() map[string]string {
- return map_ReplicationControllerStatus
-}
-
-var map_ResourceFieldSelector = map[string]string{
- "": "ResourceFieldSelector represents container resources (cpu, memory) and their output format",
- "containerName": "Container name: required for volumes, optional for env vars",
- "resource": "Required: resource to select",
- "divisor": "Specifies the output format of the exposed resources, defaults to \"1\"",
-}
-
-func (ResourceFieldSelector) SwaggerDoc() map[string]string {
- return map_ResourceFieldSelector
-}
-
-var map_ResourceQuota = map[string]string{
- "": "ResourceQuota sets aggregate quota restrictions enforced per namespace",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the desired quota. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Status defines the actual enforced quota and its current usage. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (ResourceQuota) SwaggerDoc() map[string]string {
- return map_ResourceQuota
-}
-
-var map_ResourceQuotaList = map[string]string{
- "": "ResourceQuotaList is a list of ResourceQuota items.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "Items is a list of ResourceQuota objects. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota",
-}
-
-func (ResourceQuotaList) SwaggerDoc() map[string]string {
- return map_ResourceQuotaList
-}
-
-var map_ResourceQuotaSpec = map[string]string{
- "": "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.",
- "hard": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota",
- "scopes": "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.",
-}
-
-func (ResourceQuotaSpec) SwaggerDoc() map[string]string {
- return map_ResourceQuotaSpec
-}
-
-var map_ResourceQuotaStatus = map[string]string{
- "": "ResourceQuotaStatus defines the enforced hard limits and observed use.",
- "hard": "Hard is the set of enforced hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota",
- "used": "Used is the current observed total usage of the resource in the namespace.",
-}
-
-func (ResourceQuotaStatus) SwaggerDoc() map[string]string {
- return map_ResourceQuotaStatus
-}
-
-var map_ResourceRequirements = map[string]string{
- "": "ResourceRequirements describes the compute resource requirements.",
- "limits": "Limits describes the maximum amount of compute resources allowed. More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications",
- "requests": "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: http://releases.k8s.io/HEAD/docs/design/resources.md#resource-specifications",
-}
-
-func (ResourceRequirements) SwaggerDoc() map[string]string {
- return map_ResourceRequirements
-}
-
-var map_SELinuxOptions = map[string]string{
- "": "SELinuxOptions are the labels to be applied to the container",
- "user": "User is a SELinux user label that applies to the container.",
- "role": "Role is a SELinux role label that applies to the container.",
- "type": "Type is a SELinux type label that applies to the container.",
- "level": "Level is SELinux level label that applies to the container.",
-}
-
-func (SELinuxOptions) SwaggerDoc() map[string]string {
- return map_SELinuxOptions
-}
-
-var map_Secret = map[string]string{
- "": "Secret holds secret data of a certain type. The total bytes of the values in the Data field must be less than MaxSecretSize bytes.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "data": "Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN or leading dot followed by valid DNS_SUBDOMAIN. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4",
- "stringData": "stringData allows specifying non-binary secret data in string form. It is provided as a write-only convenience method. All keys and values are merged into the data field on write, overwriting any existing values. It is never output when reading from the API.",
- "type": "Used to facilitate programmatic handling of secret data.",
-}
-
-func (Secret) SwaggerDoc() map[string]string {
- return map_Secret
-}
-
-var map_SecretKeySelector = map[string]string{
- "": "SecretKeySelector selects a key of a Secret.",
- "key": "The key of the secret to select from. Must be a valid secret key.",
-}
-
-func (SecretKeySelector) SwaggerDoc() map[string]string {
- return map_SecretKeySelector
-}
-
-var map_SecretList = map[string]string{
- "": "SecretList is a list of Secret.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "Items is a list of secret objects. More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md",
-}
-
-func (SecretList) SwaggerDoc() map[string]string {
- return map_SecretList
-}
-
-var map_SecretVolumeSource = map[string]string{
- "": "Adapts a Secret into a volume.\n\nThe contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. Secret volumes support ownership management and SELinux relabeling.",
- "secretName": "Name of the secret in the pod's namespace to use. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets",
- "items": "If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error. Paths must be relative and may not contain the '..' path or start with '..'.",
-}
-
-func (SecretVolumeSource) SwaggerDoc() map[string]string {
- return map_SecretVolumeSource
-}
-
-var map_SecurityContext = map[string]string{
- "": "SecurityContext holds security configuration that will be applied to a container. Some fields are present in both SecurityContext and PodSecurityContext. When both are set, the values in SecurityContext take precedence.",
- "capabilities": "The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime.",
- "privileged": "Run container in privileged mode. Processes in privileged containers are essentially equivalent to root on the host. Defaults to false.",
- "seLinuxOptions": "The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.",
- "runAsUser": "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.",
- "runAsNonRoot": "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.",
- "readOnlyRootFilesystem": "Whether this container has a read-only root filesystem. Default is false.",
-}
-
-func (SecurityContext) SwaggerDoc() map[string]string {
- return map_SecurityContext
-}
-
-var map_SerializedReference = map[string]string{
- "": "SerializedReference is a reference to serialized object.",
- "reference": "The reference to an object in the system.",
-}
-
-func (SerializedReference) SwaggerDoc() map[string]string {
- return map_SerializedReference
-}
-
-var map_Service = map[string]string{
- "": "Service is a named abstraction of software service (for example, mysql) consisting of local port (for example 3306) that the proxy listens on, and the selector that determines which pods will answer requests sent through the proxy.",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "spec": "Spec defines the behavior of a service. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
- "status": "Most recently observed status of the service. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
-}
-
-func (Service) SwaggerDoc() map[string]string {
- return map_Service
-}
-
-var map_ServiceAccount = map[string]string{
- "": "ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets",
- "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
- "secrets": "Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md",
- "imagePullSecrets": "ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: http://releases.k8s.io/HEAD/docs/user-guide/secrets.md#manually-specifying-an-imagepullsecret",
-}
-
-func (ServiceAccount) SwaggerDoc() map[string]string {
- return map_ServiceAccount
-}
-
-var map_ServiceAccountList = map[string]string{
- "": "ServiceAccountList is a list of ServiceAccount objects",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of ServiceAccounts. More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts",
-}
-
-func (ServiceAccountList) SwaggerDoc() map[string]string {
- return map_ServiceAccountList
-}
-
-var map_ServiceList = map[string]string{
- "": "ServiceList holds a list of services.",
- "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds",
- "items": "List of services",
-}
-
-func (ServiceList) SwaggerDoc() map[string]string {
- return map_ServiceList
-}
-
-var map_ServicePort = map[string]string{
- "": "ServicePort contains information on service's port.",
- "name": "The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. This maps to the 'Name' field in EndpointPort objects. Optional if only one ServicePort is defined on this service.",
- "protocol": "The IP protocol for this port. Supports \"TCP\" and \"UDP\". Default is TCP.",
- "port": "The port that will be exposed by this service.",
- "targetPort": "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#defining-a-service",
- "nodePort": "The port on each node on which this service is exposed when type=NodePort or LoadBalancer. Usually assigned by the system. If specified, it will be allocated to the service if unused or else creation of the service will fail. Default is to auto-allocate a port if the ServiceType of this Service requires one. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#type--nodeport",
-}
-
-func (ServicePort) SwaggerDoc() map[string]string {
- return map_ServicePort
-}
-
-var map_ServiceProxyOptions = map[string]string{
- "": "ServiceProxyOptions is the query options to a Service's proxy call.",
- "path": "Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.",
-}
-
-func (ServiceProxyOptions) SwaggerDoc() map[string]string {
- return map_ServiceProxyOptions
-}
-
-var map_ServiceSpec = map[string]string{
- "": "ServiceSpec describes the attributes that a user creates on a service.",
- "ports": "The list of ports that are exposed by this service. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies",
- "selector": "This service will route traffic to pods having labels matching this selector. Label keys and values that must match in order to receive traffic for this service. If not specified, endpoints must be manually specified and the system will not automatically manage them. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#overview",
- "clusterIP": "ClusterIP is usually assigned by the master and is the IP address of the service. If specified, it will be allocated to the service if it is unused or else creation of the service will fail. Valid values are None, empty string (\"\"), or a valid IP address. 'None' can be specified for a headless service when proxying is not required. Cannot be updated. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies",
- "type": "Type of exposed service. Must be ClusterIP, NodePort, or LoadBalancer. Defaults to ClusterIP. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#external-services",
- "externalIPs": "externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system. A previous form of this functionality exists as the deprecatedPublicIPs field. When using this field, callers should also clear the deprecatedPublicIPs field.",
- "deprecatedPublicIPs": "deprecatedPublicIPs is deprecated and replaced by the externalIPs field with almost the exact same semantics. This field is retained in the v1 API for compatibility until at least 8/20/2016. It will be removed from any new API revisions. If both deprecatedPublicIPs *and* externalIPs are set, deprecatedPublicIPs is used.",
- "sessionAffinity": "Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: http://releases.k8s.io/HEAD/docs/user-guide/services.md#virtual-ips-and-service-proxies",
- "loadBalancerIP": "Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature.",
- "loadBalancerSourceRanges": "If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: http://releases.k8s.io/HEAD/docs/user-guide/services-firewalls.md",
-}
-
-func (ServiceSpec) SwaggerDoc() map[string]string {
- return map_ServiceSpec
-}
-
-var map_ServiceStatus = map[string]string{
- "": "ServiceStatus represents the current status of a service.",
- "loadBalancer": "LoadBalancer contains the current status of the load-balancer, if one is present.",
-}
-
-func (ServiceStatus) SwaggerDoc() map[string]string {
- return map_ServiceStatus
-}
-
-var map_TCPSocketAction = map[string]string{
- "": "TCPSocketAction describes an action based on opening a socket",
- "port": "Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.",
-}
-
-func (TCPSocketAction) SwaggerDoc() map[string]string {
- return map_TCPSocketAction
-}
-
-var map_Taint = map[string]string{
- "": "The node this Taint is attached to has the effect \"effect\" on any pod that that does not tolerate the Taint.",
- "key": "Required. The taint key to be applied to a node.",
- "value": "Required. The taint value corresponding to the taint key.",
- "effect": "Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule and PreferNoSchedule.",
-}
-
-func (Taint) SwaggerDoc() map[string]string {
- return map_Taint
-}
-
-var map_Toleration = map[string]string{
- "": "The pod this Toleration is attached to tolerates any taint that matches the triple <key,value,effect> using the matching operator <operator>.",
- "key": "Required. Key is the taint key that the toleration applies to.",
- "operator": "operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category.",
- "value": "Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string.",
- "effect": "Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule and PreferNoSchedule.",
-}
-
-func (Toleration) SwaggerDoc() map[string]string {
- return map_Toleration
-}
-
-var map_Volume = map[string]string{
- "": "Volume represents a named volume in a pod that may be accessed by any container in the pod.",
- "name": "Volume's name. Must be a DNS_LABEL and unique within the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names",
-}
-
-func (Volume) SwaggerDoc() map[string]string {
- return map_Volume
-}
-
-var map_VolumeMount = map[string]string{
- "": "VolumeMount describes a mounting of a Volume within a container.",
- "name": "This must match the Name of a Volume.",
- "readOnly": "Mounted read-only if true, read-write otherwise (false or unspecified). Defaults to false.",
- "mountPath": "Path within the container at which the volume should be mounted. Must not contain ':'.",
- "subPath": "Path within the volume from which the container's volume should be mounted. Defaults to \"\" (volume's root).",
-}
-
-func (VolumeMount) SwaggerDoc() map[string]string {
- return map_VolumeMount
-}
-
-var map_VolumeSource = map[string]string{
- "": "Represents the source of a volume to mount. Only one of its members may be specified.",
- "hostPath": "HostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#hostpath",
- "emptyDir": "EmptyDir represents a temporary directory that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#emptydir",
- "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#gcepersistentdisk",
- "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#awselasticblockstore",
- "gitRepo": "GitRepo represents a git repository at a particular revision.",
- "secret": "Secret represents a secret that should populate this volume. More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#secrets",
- "nfs": "NFS represents an NFS mount on the host that shares a pod's lifetime More info: http://releases.k8s.io/HEAD/docs/user-guide/volumes.md#nfs",
- "iscsi": "ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md",
- "glusterfs": "Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md",
- "persistentVolumeClaim": "PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: http://releases.k8s.io/HEAD/docs/user-guide/persistent-volumes.md#persistentvolumeclaims",
- "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md",
- "flexVolume": "FlexVolume represents a generic volume resource that is provisioned/attached using a exec based plugin. This is an alpha feature and may change in future.",
- "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md",
- "cephfs": "CephFS represents a Ceph FS mount on the host that shares a pod's lifetime",
- "flocker": "Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running",
- "downwardAPI": "DownwardAPI represents downward API about the pod that should populate this volume",
- "fc": "FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.",
- "azureFile": "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.",
- "configMap": "ConfigMap represents a configMap that should populate this volume",
- "vsphereVolume": "VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine",
-}
-
-func (VolumeSource) SwaggerDoc() map[string]string {
- return map_VolumeSource
-}
-
-var map_VsphereVirtualDiskVolumeSource = map[string]string{
- "": "Represents a vSphere volume resource.",
- "volumePath": "Path that identifies vSphere volume vmdk",
- "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
-}
-
-func (VsphereVirtualDiskVolumeSource) SwaggerDoc() map[string]string {
- return map_VsphereVirtualDiskVolumeSource
-}
-
-var map_WeightedPodAffinityTerm = map[string]string{
- "": "The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)",
- "weight": "weight associated with matching the corresponding podAffinityTerm, in the range 1-100.",
- "podAffinityTerm": "Required. A pod affinity term, associated with the corresponding weight.",
-}
-
-func (WeightedPodAffinityTerm) SwaggerDoc() map[string]string {
- return map_WeightedPodAffinityTerm
-}
-
-// AUTO-GENERATED FUNCTIONS END HERE