diff --git a/vendor/k8s.io/client-go/1.5/pkg/api/v1/types.generated.go b/vendor/k8s.io/client-go/1.5/pkg/api/v1/types.generated.go deleted file mode 100644 index cf9b71261..000000000 --- a/vendor/k8s.io/client-go/1.5/pkg/api/v1/types.generated.go +++ /dev/null @@ -1,62479 +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/client-go/1.5/pkg/api/resource" - pkg2_unversioned "k8s.io/client-go/1.5/pkg/api/unversioned" - pkg5_runtime "k8s.io/client-go/1.5/pkg/runtime" - pkg1_types "k8s.io/client-go/1.5/pkg/types" - pkg4_intstr "k8s.io/client-go/1.5/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 [15]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 - yyq2[14] = x.ClusterName != "" - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(15) - } 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_containerArrayElem1234) - if yyq2[14] { - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym51 := z.EncBinary() - _ = yym51 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } - } - 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 - yym52 := z.DecBinary() - _ = yym52 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct53 := r.ContainerType() - if yyct53 == codecSelferValueTypeMap1234 { - yyl53 := r.ReadMapStart() - if yyl53 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl53, d) - } - } else if yyct53 == codecSelferValueTypeArray1234 { - yyl53 := r.ReadArrayStart() - if yyl53 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl53, 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 yys54Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys54Slc - var yyhl54 bool = l >= 0 - for yyj54 := 0; ; yyj54++ { - if yyhl54 { - if yyj54 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys54Slc = r.DecodeBytes(yys54Slc, true, true) - yys54 := string(yys54Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys54 { - 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 { - yyv62 := &x.CreationTimestamp - yym63 := z.DecBinary() - _ = yym63 - if false { - } else if z.HasExtensions() && z.DecExt(yyv62) { - } else if yym63 { - z.DecBinaryUnmarshal(yyv62) - } else if !yym63 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv62) - } else { - z.DecFallback(yyv62, false) - } - } - case "deletionTimestamp": - if r.TryDecodeAsNil() { - if x.DeletionTimestamp != nil { - x.DeletionTimestamp = nil - } - } else { - if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg2_unversioned.Time) - } - yym65 := z.DecBinary() - _ = yym65 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym65 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym65 && 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) - } - yym67 := z.DecBinary() - _ = yym67 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - case "labels": - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv68 := &x.Labels - yym69 := z.DecBinary() - _ = yym69 - if false { - } else { - z.F.DecMapStringStringX(yyv68, false, d) - } - } - case "annotations": - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv70 := &x.Annotations - yym71 := z.DecBinary() - _ = yym71 - if false { - } else { - z.F.DecMapStringStringX(yyv70, false, d) - } - } - case "ownerReferences": - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv72 := &x.OwnerReferences - yym73 := z.DecBinary() - _ = yym73 - if false { - } else { - h.decSliceOwnerReference((*[]OwnerReference)(yyv72), d) - } - } - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv74 := &x.Finalizers - yym75 := z.DecBinary() - _ = yym75 - if false { - } else { - z.F.DecSliceStringX(yyv74, false, d) - } - } - case "clusterName": - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys54) - } // end switch yys54 - } // end for yyj54 - 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 yyj77 int - var yyb77 bool - var yyhl77 bool = l >= 0 - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.GenerateName = "" - } else { - x.GenerateName = string(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SelfLink = "" - } else { - x.SelfLink = string(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Generation = 0 - } else { - x.Generation = int64(r.DecodeInt(64)) - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg2_unversioned.Time{} - } else { - yyv85 := &x.CreationTimestamp - yym86 := z.DecBinary() - _ = yym86 - if false { - } else if z.HasExtensions() && z.DecExt(yyv85) { - } else if yym86 { - z.DecBinaryUnmarshal(yyv85) - } else if !yym86 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv85) - } else { - z.DecFallback(yyv85, false) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - 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) - } - yym88 := z.DecBinary() - _ = yym88 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym88 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym88 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - 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) - } - yym90 := z.DecBinary() - _ = yym90 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv91 := &x.Labels - yym92 := z.DecBinary() - _ = yym92 - if false { - } else { - z.F.DecMapStringStringX(yyv91, false, d) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv93 := &x.Annotations - yym94 := z.DecBinary() - _ = yym94 - if false { - } else { - z.F.DecMapStringStringX(yyv93, false, d) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv95 := &x.OwnerReferences - yym96 := z.DecBinary() - _ = yym96 - if false { - } else { - h.decSliceOwnerReference((*[]OwnerReference)(yyv95), d) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv97 := &x.Finalizers - yym98 := z.DecBinary() - _ = yym98 - if false { - } else { - z.F.DecSliceStringX(yyv97, false, d) - } - } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - for { - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l - } else { - yyb77 = r.CheckBreak() - } - if yyb77 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj77-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 { - yym100 := z.EncBinary() - _ = yym100 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep101 := !z.EncBinary() - yy2arr101 := z.EncBasicHandle().StructToArray - var yyq101 [23]bool - _, _, _ = yysep101, yyq101, yy2arr101 - const yyr101 bool = false - yyq101[1] = x.VolumeSource.HostPath != nil && x.HostPath != nil - yyq101[2] = x.VolumeSource.EmptyDir != nil && x.EmptyDir != nil - yyq101[3] = x.VolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil - yyq101[4] = x.VolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil - yyq101[5] = x.VolumeSource.GitRepo != nil && x.GitRepo != nil - yyq101[6] = x.VolumeSource.Secret != nil && x.Secret != nil - yyq101[7] = x.VolumeSource.NFS != nil && x.NFS != nil - yyq101[8] = x.VolumeSource.ISCSI != nil && x.ISCSI != nil - yyq101[9] = x.VolumeSource.Glusterfs != nil && x.Glusterfs != nil - yyq101[10] = x.VolumeSource.PersistentVolumeClaim != nil && x.PersistentVolumeClaim != nil - yyq101[11] = x.VolumeSource.RBD != nil && x.RBD != nil - yyq101[12] = x.VolumeSource.FlexVolume != nil && x.FlexVolume != nil - yyq101[13] = x.VolumeSource.Cinder != nil && x.Cinder != nil - yyq101[14] = x.VolumeSource.CephFS != nil && x.CephFS != nil - yyq101[15] = x.VolumeSource.Flocker != nil && x.Flocker != nil - yyq101[16] = x.VolumeSource.DownwardAPI != nil && x.DownwardAPI != nil - yyq101[17] = x.VolumeSource.FC != nil && x.FC != nil - yyq101[18] = x.VolumeSource.AzureFile != nil && x.AzureFile != nil - yyq101[19] = x.VolumeSource.ConfigMap != nil && x.ConfigMap != nil - yyq101[20] = x.VolumeSource.VsphereVolume != nil && x.VsphereVolume != nil - yyq101[21] = x.VolumeSource.Quobyte != nil && x.Quobyte != nil - yyq101[22] = x.VolumeSource.AzureDisk != nil && x.AzureDisk != nil - var yynn101 int - if yyr101 || yy2arr101 { - r.EncodeArrayStart(23) - } else { - yynn101 = 1 - for _, b := range yyq101 { - if b { - yynn101++ - } - } - r.EncodeMapStart(yynn101) - yynn101 = 0 - } - if yyr101 || yy2arr101 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym103 := z.EncBinary() - _ = yym103 - 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) - yym104 := z.EncBinary() - _ = yym104 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - var yyn105 bool - if x.VolumeSource.HostPath == nil { - yyn105 = true - goto LABEL105 - } - LABEL105: - if yyr101 || yy2arr101 { - if yyn105 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[1] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn105 { - r.EncodeNil() - } else { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } - } - } - var yyn106 bool - if x.VolumeSource.EmptyDir == nil { - yyn106 = true - goto LABEL106 - } - LABEL106: - if yyr101 || yy2arr101 { - if yyn106 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[2] { - if x.EmptyDir == nil { - r.EncodeNil() - } else { - x.EmptyDir.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("emptyDir")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn106 { - r.EncodeNil() - } else { - if x.EmptyDir == nil { - r.EncodeNil() - } else { - x.EmptyDir.CodecEncodeSelf(e) - } - } - } - } - var yyn107 bool - if x.VolumeSource.GCEPersistentDisk == nil { - yyn107 = true - goto LABEL107 - } - LABEL107: - if yyr101 || yy2arr101 { - if yyn107 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[3] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn107 { - r.EncodeNil() - } else { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } - } - } - var yyn108 bool - if x.VolumeSource.AWSElasticBlockStore == nil { - yyn108 = true - goto LABEL108 - } - LABEL108: - if yyr101 || yy2arr101 { - if yyn108 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[4] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn108 { - r.EncodeNil() - } else { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } - } - } - var yyn109 bool - if x.VolumeSource.GitRepo == nil { - yyn109 = true - goto LABEL109 - } - LABEL109: - if yyr101 || yy2arr101 { - if yyn109 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[5] { - if x.GitRepo == nil { - r.EncodeNil() - } else { - x.GitRepo.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gitRepo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn109 { - r.EncodeNil() - } else { - if x.GitRepo == nil { - r.EncodeNil() - } else { - x.GitRepo.CodecEncodeSelf(e) - } - } - } - } - var yyn110 bool - if x.VolumeSource.Secret == nil { - yyn110 = true - goto LABEL110 - } - LABEL110: - if yyr101 || yy2arr101 { - if yyn110 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[6] { - if x.Secret == nil { - r.EncodeNil() - } else { - x.Secret.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secret")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn110 { - r.EncodeNil() - } else { - if x.Secret == nil { - r.EncodeNil() - } else { - x.Secret.CodecEncodeSelf(e) - } - } - } - } - var yyn111 bool - if x.VolumeSource.NFS == nil { - yyn111 = true - goto LABEL111 - } - LABEL111: - if yyr101 || yy2arr101 { - if yyn111 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[7] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn111 { - r.EncodeNil() - } else { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } - } - } - var yyn112 bool - if x.VolumeSource.ISCSI == nil { - yyn112 = true - goto LABEL112 - } - LABEL112: - if yyr101 || yy2arr101 { - if yyn112 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[8] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsi")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn112 { - r.EncodeNil() - } else { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } - } - } - var yyn113 bool - if x.VolumeSource.Glusterfs == nil { - yyn113 = true - goto LABEL113 - } - LABEL113: - if yyr101 || yy2arr101 { - if yyn113 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[9] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn113 { - r.EncodeNil() - } else { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } - } - } - var yyn114 bool - if x.VolumeSource.PersistentVolumeClaim == nil { - yyn114 = true - goto LABEL114 - } - LABEL114: - if yyr101 || yy2arr101 { - if yyn114 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[10] { - if x.PersistentVolumeClaim == nil { - r.EncodeNil() - } else { - x.PersistentVolumeClaim.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeClaim")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn114 { - r.EncodeNil() - } else { - if x.PersistentVolumeClaim == nil { - r.EncodeNil() - } else { - x.PersistentVolumeClaim.CodecEncodeSelf(e) - } - } - } - } - var yyn115 bool - if x.VolumeSource.RBD == nil { - yyn115 = true - goto LABEL115 - } - LABEL115: - if yyr101 || yy2arr101 { - if yyn115 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[11] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rbd")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn115 { - r.EncodeNil() - } else { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } - } - } - var yyn116 bool - if x.VolumeSource.FlexVolume == nil { - yyn116 = true - goto LABEL116 - } - LABEL116: - if yyr101 || yy2arr101 { - if yyn116 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[12] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn116 { - r.EncodeNil() - } else { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn117 bool - if x.VolumeSource.Cinder == nil { - yyn117 = true - goto LABEL117 - } - LABEL117: - if yyr101 || yy2arr101 { - if yyn117 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[13] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cinder")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn117 { - r.EncodeNil() - } else { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } - } - } - var yyn118 bool - if x.VolumeSource.CephFS == nil { - yyn118 = true - goto LABEL118 - } - LABEL118: - if yyr101 || yy2arr101 { - if yyn118 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[14] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cephfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn118 { - r.EncodeNil() - } else { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } - } - } - var yyn119 bool - if x.VolumeSource.Flocker == nil { - yyn119 = true - goto LABEL119 - } - LABEL119: - if yyr101 || yy2arr101 { - if yyn119 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[15] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flocker")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn119 { - r.EncodeNil() - } else { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } - } - } - var yyn120 bool - if x.VolumeSource.DownwardAPI == nil { - yyn120 = true - goto LABEL120 - } - LABEL120: - if yyr101 || yy2arr101 { - if yyn120 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[16] { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("downwardAPI")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn120 { - r.EncodeNil() - } else { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } - } - } - var yyn121 bool - if x.VolumeSource.FC == nil { - yyn121 = true - goto LABEL121 - } - LABEL121: - if yyr101 || yy2arr101 { - if yyn121 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[17] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fc")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn121 { - r.EncodeNil() - } else { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } - } - } - var yyn122 bool - if x.VolumeSource.AzureFile == nil { - yyn122 = true - goto LABEL122 - } - LABEL122: - if yyr101 || yy2arr101 { - if yyn122 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[18] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[18] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn122 { - r.EncodeNil() - } else { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } - } - } - var yyn123 bool - if x.VolumeSource.ConfigMap == nil { - yyn123 = true - goto LABEL123 - } - LABEL123: - if yyr101 || yy2arr101 { - if yyn123 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[19] { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[19] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("configMap")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn123 { - r.EncodeNil() - } else { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } - } - } - var yyn124 bool - if x.VolumeSource.VsphereVolume == nil { - yyn124 = true - goto LABEL124 - } - LABEL124: - if yyr101 || yy2arr101 { - if yyn124 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[20] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[20] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn124 { - r.EncodeNil() - } else { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn125 bool - if x.VolumeSource.Quobyte == nil { - yyn125 = true - goto LABEL125 - } - LABEL125: - if yyr101 || yy2arr101 { - if yyn125 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[21] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[21] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn125 { - r.EncodeNil() - } else { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - } - var yyn126 bool - if x.VolumeSource.AzureDisk == nil { - yyn126 = true - goto LABEL126 - } - LABEL126: - if yyr101 || yy2arr101 { - if yyn126 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[22] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[22] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn126 { - r.EncodeNil() - } else { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } - } - } - if yyr101 || yy2arr101 { - 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 - yym127 := z.DecBinary() - _ = yym127 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct128 := r.ContainerType() - if yyct128 == codecSelferValueTypeMap1234 { - yyl128 := r.ReadMapStart() - if yyl128 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl128, d) - } - } else if yyct128 == codecSelferValueTypeArray1234 { - yyl128 := r.ReadArrayStart() - if yyl128 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl128, 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 yys129Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys129Slc - var yyhl129 bool = l >= 0 - for yyj129 := 0; ; yyj129++ { - if yyhl129 { - if yyj129 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys129Slc = r.DecodeBytes(yys129Slc, true, true) - yys129 := string(yys129Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys129 { - 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) - } - case "quobyte": - if x.VolumeSource.Quobyte == nil { - x.VolumeSource.Quobyte = new(QuobyteVolumeSource) - } - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - case "azureDisk": - if x.VolumeSource.AzureDisk == nil { - x.VolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys129) - } // end switch yys129 - } // end for yyj129 - 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 yyj153 int - var yyb153 bool - var yyhl153 bool = l >= 0 - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - 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) - } - if x.VolumeSource.Quobyte == nil { - x.VolumeSource.Quobyte = new(QuobyteVolumeSource) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - if x.VolumeSource.AzureDisk == nil { - x.VolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - for { - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l - } else { - yyb153 = r.CheckBreak() - } - if yyb153 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj153-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 { - yym177 := z.EncBinary() - _ = yym177 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep178 := !z.EncBinary() - yy2arr178 := z.EncBasicHandle().StructToArray - var yyq178 [22]bool - _, _, _ = yysep178, yyq178, yy2arr178 - const yyr178 bool = false - yyq178[0] = x.HostPath != nil - yyq178[1] = x.EmptyDir != nil - yyq178[2] = x.GCEPersistentDisk != nil - yyq178[3] = x.AWSElasticBlockStore != nil - yyq178[4] = x.GitRepo != nil - yyq178[5] = x.Secret != nil - yyq178[6] = x.NFS != nil - yyq178[7] = x.ISCSI != nil - yyq178[8] = x.Glusterfs != nil - yyq178[9] = x.PersistentVolumeClaim != nil - yyq178[10] = x.RBD != nil - yyq178[11] = x.FlexVolume != nil - yyq178[12] = x.Cinder != nil - yyq178[13] = x.CephFS != nil - yyq178[14] = x.Flocker != nil - yyq178[15] = x.DownwardAPI != nil - yyq178[16] = x.FC != nil - yyq178[17] = x.AzureFile != nil - yyq178[18] = x.ConfigMap != nil - yyq178[19] = x.VsphereVolume != nil - yyq178[20] = x.Quobyte != nil - yyq178[21] = x.AzureDisk != nil - var yynn178 int - if yyr178 || yy2arr178 { - r.EncodeArrayStart(22) - } else { - yynn178 = 0 - for _, b := range yyq178 { - if b { - yynn178++ - } - } - r.EncodeMapStart(yynn178) - yynn178 = 0 - } - if yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[0] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[1] { - if x.EmptyDir == nil { - r.EncodeNil() - } else { - x.EmptyDir.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[2] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[3] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[4] { - if x.GitRepo == nil { - r.EncodeNil() - } else { - x.GitRepo.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[5] { - if x.Secret == nil { - r.EncodeNil() - } else { - x.Secret.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[6] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[7] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[8] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[9] { - if x.PersistentVolumeClaim == nil { - r.EncodeNil() - } else { - x.PersistentVolumeClaim.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[10] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[11] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[12] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[13] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[14] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[15] { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[16] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[17] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[18] { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[19] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[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 yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[20] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[20] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - if yyr178 || yy2arr178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq178[21] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq178[21] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } - } - if yyr178 || yy2arr178 { - 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 - yym201 := z.DecBinary() - _ = yym201 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct202 := r.ContainerType() - if yyct202 == codecSelferValueTypeMap1234 { - yyl202 := r.ReadMapStart() - if yyl202 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl202, d) - } - } else if yyct202 == codecSelferValueTypeArray1234 { - yyl202 := r.ReadArrayStart() - if yyl202 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl202, 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 yys203Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys203Slc - var yyhl203 bool = l >= 0 - for yyj203 := 0; ; yyj203++ { - if yyhl203 { - if yyj203 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys203Slc = r.DecodeBytes(yys203Slc, true, true) - yys203 := string(yys203Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys203 { - 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) - } - case "quobyte": - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - case "azureDisk": - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys203) - } // end switch yys203 - } // end for yyj203 - 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 yyj226 int - var yyb226 bool - var yyhl226 bool = l >= 0 - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - 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) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - for { - yyj226++ - if yyhl226 { - yyb226 = yyj226 > l - } else { - yyb226 = r.CheckBreak() - } - if yyb226 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj226-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 { - yym249 := z.EncBinary() - _ = yym249 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep250 := !z.EncBinary() - yy2arr250 := z.EncBasicHandle().StructToArray - var yyq250 [2]bool - _, _, _ = yysep250, yyq250, yy2arr250 - const yyr250 bool = false - yyq250[1] = x.ReadOnly != false - var yynn250 int - if yyr250 || yy2arr250 { - r.EncodeArrayStart(2) - } else { - yynn250 = 1 - for _, b := range yyq250 { - if b { - yynn250++ - } - } - r.EncodeMapStart(yynn250) - yynn250 = 0 - } - if yyr250 || yy2arr250 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym252 := z.EncBinary() - _ = yym252 - 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) - yym253 := z.EncBinary() - _ = yym253 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName)) - } - } - if yyr250 || yy2arr250 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq250[1] { - yym255 := z.EncBinary() - _ = yym255 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq250[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym256 := z.EncBinary() - _ = yym256 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr250 || yy2arr250 { - 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 - yym257 := z.DecBinary() - _ = yym257 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct258 := r.ContainerType() - if yyct258 == codecSelferValueTypeMap1234 { - yyl258 := r.ReadMapStart() - if yyl258 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl258, d) - } - } else if yyct258 == codecSelferValueTypeArray1234 { - yyl258 := r.ReadArrayStart() - if yyl258 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl258, 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 yys259Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys259Slc - var yyhl259 bool = l >= 0 - for yyj259 := 0; ; yyj259++ { - if yyhl259 { - if yyj259 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys259Slc = r.DecodeBytes(yys259Slc, true, true) - yys259 := string(yys259Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys259 { - 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, yys259) - } // end switch yys259 - } // end for yyj259 - 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 yyj262 int - var yyb262 bool - var yyhl262 bool = l >= 0 - yyj262++ - if yyhl262 { - yyb262 = yyj262 > l - } else { - yyb262 = r.CheckBreak() - } - if yyb262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClaimName = "" - } else { - x.ClaimName = string(r.DecodeString()) - } - yyj262++ - if yyhl262 { - yyb262 = yyj262 > l - } else { - yyb262 = r.CheckBreak() - } - if yyb262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj262++ - if yyhl262 { - yyb262 = yyj262 > l - } else { - yyb262 = r.CheckBreak() - } - if yyb262 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj262-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 { - yym265 := z.EncBinary() - _ = yym265 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep266 := !z.EncBinary() - yy2arr266 := z.EncBasicHandle().StructToArray - var yyq266 [16]bool - _, _, _ = yysep266, yyq266, yy2arr266 - const yyr266 bool = false - yyq266[0] = x.GCEPersistentDisk != nil - yyq266[1] = x.AWSElasticBlockStore != nil - yyq266[2] = x.HostPath != nil - yyq266[3] = x.Glusterfs != nil - yyq266[4] = x.NFS != nil - yyq266[5] = x.RBD != nil - yyq266[6] = x.ISCSI != nil - yyq266[7] = x.Cinder != nil - yyq266[8] = x.CephFS != nil - yyq266[9] = x.FC != nil - yyq266[10] = x.Flocker != nil - yyq266[11] = x.FlexVolume != nil - yyq266[12] = x.AzureFile != nil - yyq266[13] = x.VsphereVolume != nil - yyq266[14] = x.Quobyte != nil - yyq266[15] = x.AzureDisk != nil - var yynn266 int - if yyr266 || yy2arr266 { - r.EncodeArrayStart(16) - } else { - yynn266 = 0 - for _, b := range yyq266 { - if b { - yynn266++ - } - } - r.EncodeMapStart(yynn266) - yynn266 = 0 - } - if yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[0] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[1] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[2] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[3] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[4] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[5] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[6] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[7] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[8] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[9] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[10] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[11] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[12] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[13] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[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 yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[14] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - if yyr266 || yy2arr266 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq266[15] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq266[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } - } - if yyr266 || yy2arr266 { - 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 - yym283 := z.DecBinary() - _ = yym283 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct284 := r.ContainerType() - if yyct284 == codecSelferValueTypeMap1234 { - yyl284 := r.ReadMapStart() - if yyl284 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl284, d) - } - } else if yyct284 == codecSelferValueTypeArray1234 { - yyl284 := r.ReadArrayStart() - if yyl284 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl284, 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 yys285Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys285Slc - var yyhl285 bool = l >= 0 - for yyj285 := 0; ; yyj285++ { - if yyhl285 { - if yyj285 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys285Slc = r.DecodeBytes(yys285Slc, true, true) - yys285 := string(yys285Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys285 { - 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) - } - case "quobyte": - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - case "azureDisk": - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys285) - } // end switch yys285 - } // end for yyj285 - 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 yyj302 int - var yyb302 bool - var yyhl302 bool = l >= 0 - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - 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) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - for { - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj302-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 { - yym319 := z.EncBinary() - _ = yym319 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep320 := !z.EncBinary() - yy2arr320 := z.EncBasicHandle().StructToArray - var yyq320 [5]bool - _, _, _ = yysep320, yyq320, yy2arr320 - const yyr320 bool = false - yyq320[0] = x.Kind != "" - yyq320[1] = x.APIVersion != "" - yyq320[2] = true - yyq320[3] = true - yyq320[4] = true - var yynn320 int - if yyr320 || yy2arr320 { - r.EncodeArrayStart(5) - } else { - yynn320 = 0 - for _, b := range yyq320 { - if b { - yynn320++ - } - } - r.EncodeMapStart(yynn320) - yynn320 = 0 - } - if yyr320 || yy2arr320 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq320[0] { - yym322 := z.EncBinary() - _ = yym322 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq320[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym323 := z.EncBinary() - _ = yym323 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr320 || yy2arr320 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq320[1] { - yym325 := z.EncBinary() - _ = yym325 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq320[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym326 := z.EncBinary() - _ = yym326 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr320 || yy2arr320 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq320[2] { - yy328 := &x.ObjectMeta - yy328.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq320[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy329 := &x.ObjectMeta - yy329.CodecEncodeSelf(e) - } - } - if yyr320 || yy2arr320 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq320[3] { - yy331 := &x.Spec - yy331.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq320[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy332 := &x.Spec - yy332.CodecEncodeSelf(e) - } - } - if yyr320 || yy2arr320 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq320[4] { - yy334 := &x.Status - yy334.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq320[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy335 := &x.Status - yy335.CodecEncodeSelf(e) - } - } - if yyr320 || yy2arr320 { - 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 - yym336 := z.DecBinary() - _ = yym336 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct337 := r.ContainerType() - if yyct337 == codecSelferValueTypeMap1234 { - yyl337 := r.ReadMapStart() - if yyl337 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl337, d) - } - } else if yyct337 == codecSelferValueTypeArray1234 { - yyl337 := r.ReadArrayStart() - if yyl337 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl337, 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 yys338Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys338Slc - var yyhl338 bool = l >= 0 - for yyj338 := 0; ; yyj338++ { - if yyhl338 { - if yyj338 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys338Slc = r.DecodeBytes(yys338Slc, true, true) - yys338 := string(yys338Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys338 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv341 := &x.ObjectMeta - yyv341.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeSpec{} - } else { - yyv342 := &x.Spec - yyv342.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeStatus{} - } else { - yyv343 := &x.Status - yyv343.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys338) - } // end switch yys338 - } // end for yyj338 - 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 yyj344 int - var yyb344 bool - var yyhl344 bool = l >= 0 - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv347 := &x.ObjectMeta - yyv347.CodecDecodeSelf(d) - } - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeSpec{} - } else { - yyv348 := &x.Spec - yyv348.CodecDecodeSelf(d) - } - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeStatus{} - } else { - yyv349 := &x.Status - yyv349.CodecDecodeSelf(d) - } - for { - yyj344++ - if yyhl344 { - yyb344 = yyj344 > l - } else { - yyb344 = r.CheckBreak() - } - if yyb344 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj344-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 { - yym350 := z.EncBinary() - _ = yym350 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep351 := !z.EncBinary() - yy2arr351 := z.EncBasicHandle().StructToArray - var yyq351 [20]bool - _, _, _ = yysep351, yyq351, yy2arr351 - const yyr351 bool = false - yyq351[0] = len(x.Capacity) != 0 - yyq351[1] = x.PersistentVolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil - yyq351[2] = x.PersistentVolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil - yyq351[3] = x.PersistentVolumeSource.HostPath != nil && x.HostPath != nil - yyq351[4] = x.PersistentVolumeSource.Glusterfs != nil && x.Glusterfs != nil - yyq351[5] = x.PersistentVolumeSource.NFS != nil && x.NFS != nil - yyq351[6] = x.PersistentVolumeSource.RBD != nil && x.RBD != nil - yyq351[7] = x.PersistentVolumeSource.ISCSI != nil && x.ISCSI != nil - yyq351[8] = x.PersistentVolumeSource.Cinder != nil && x.Cinder != nil - yyq351[9] = x.PersistentVolumeSource.CephFS != nil && x.CephFS != nil - yyq351[10] = x.PersistentVolumeSource.FC != nil && x.FC != nil - yyq351[11] = x.PersistentVolumeSource.Flocker != nil && x.Flocker != nil - yyq351[12] = x.PersistentVolumeSource.FlexVolume != nil && x.FlexVolume != nil - yyq351[13] = x.PersistentVolumeSource.AzureFile != nil && x.AzureFile != nil - yyq351[14] = x.PersistentVolumeSource.VsphereVolume != nil && x.VsphereVolume != nil - yyq351[15] = x.PersistentVolumeSource.Quobyte != nil && x.Quobyte != nil - yyq351[16] = x.PersistentVolumeSource.AzureDisk != nil && x.AzureDisk != nil - yyq351[17] = len(x.AccessModes) != 0 - yyq351[18] = x.ClaimRef != nil - yyq351[19] = x.PersistentVolumeReclaimPolicy != "" - var yynn351 int - if yyr351 || yy2arr351 { - r.EncodeArrayStart(20) - } else { - yynn351 = 0 - for _, b := range yyq351 { - if b { - yynn351++ - } - } - r.EncodeMapStart(yynn351) - yynn351 = 0 - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[0] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq351[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) - } - } - } - var yyn353 bool - if x.PersistentVolumeSource.GCEPersistentDisk == nil { - yyn353 = true - goto LABEL353 - } - LABEL353: - if yyr351 || yy2arr351 { - if yyn353 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[1] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn353 { - r.EncodeNil() - } else { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } - } - } - var yyn354 bool - if x.PersistentVolumeSource.AWSElasticBlockStore == nil { - yyn354 = true - goto LABEL354 - } - LABEL354: - if yyr351 || yy2arr351 { - if yyn354 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[2] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn354 { - r.EncodeNil() - } else { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } - } - } - var yyn355 bool - if x.PersistentVolumeSource.HostPath == nil { - yyn355 = true - goto LABEL355 - } - LABEL355: - if yyr351 || yy2arr351 { - if yyn355 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[3] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn355 { - r.EncodeNil() - } else { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } - } - } - var yyn356 bool - if x.PersistentVolumeSource.Glusterfs == nil { - yyn356 = true - goto LABEL356 - } - LABEL356: - if yyr351 || yy2arr351 { - if yyn356 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[4] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn356 { - r.EncodeNil() - } else { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } - } - } - var yyn357 bool - if x.PersistentVolumeSource.NFS == nil { - yyn357 = true - goto LABEL357 - } - LABEL357: - if yyr351 || yy2arr351 { - if yyn357 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[5] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn357 { - r.EncodeNil() - } else { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } - } - } - var yyn358 bool - if x.PersistentVolumeSource.RBD == nil { - yyn358 = true - goto LABEL358 - } - LABEL358: - if yyr351 || yy2arr351 { - if yyn358 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[6] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rbd")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn358 { - r.EncodeNil() - } else { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } - } - } - var yyn359 bool - if x.PersistentVolumeSource.ISCSI == nil { - yyn359 = true - goto LABEL359 - } - LABEL359: - if yyr351 || yy2arr351 { - if yyn359 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[7] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsi")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn359 { - r.EncodeNil() - } else { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } - } - } - var yyn360 bool - if x.PersistentVolumeSource.Cinder == nil { - yyn360 = true - goto LABEL360 - } - LABEL360: - if yyr351 || yy2arr351 { - if yyn360 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[8] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cinder")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn360 { - r.EncodeNil() - } else { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } - } - } - var yyn361 bool - if x.PersistentVolumeSource.CephFS == nil { - yyn361 = true - goto LABEL361 - } - LABEL361: - if yyr351 || yy2arr351 { - if yyn361 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[9] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cephfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn361 { - r.EncodeNil() - } else { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } - } - } - var yyn362 bool - if x.PersistentVolumeSource.FC == nil { - yyn362 = true - goto LABEL362 - } - LABEL362: - if yyr351 || yy2arr351 { - if yyn362 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[10] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fc")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn362 { - r.EncodeNil() - } else { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } - } - } - var yyn363 bool - if x.PersistentVolumeSource.Flocker == nil { - yyn363 = true - goto LABEL363 - } - LABEL363: - if yyr351 || yy2arr351 { - if yyn363 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[11] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flocker")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn363 { - r.EncodeNil() - } else { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } - } - } - var yyn364 bool - if x.PersistentVolumeSource.FlexVolume == nil { - yyn364 = true - goto LABEL364 - } - LABEL364: - if yyr351 || yy2arr351 { - if yyn364 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[12] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn364 { - r.EncodeNil() - } else { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn365 bool - if x.PersistentVolumeSource.AzureFile == nil { - yyn365 = true - goto LABEL365 - } - LABEL365: - if yyr351 || yy2arr351 { - if yyn365 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[13] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn365 { - r.EncodeNil() - } else { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } - } - } - var yyn366 bool - if x.PersistentVolumeSource.VsphereVolume == nil { - yyn366 = true - goto LABEL366 - } - LABEL366: - if yyr351 || yy2arr351 { - if yyn366 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[14] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn366 { - r.EncodeNil() - } else { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn367 bool - if x.PersistentVolumeSource.Quobyte == nil { - yyn367 = true - goto LABEL367 - } - LABEL367: - if yyr351 || yy2arr351 { - if yyn367 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[15] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn367 { - r.EncodeNil() - } else { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - } - var yyn368 bool - if x.PersistentVolumeSource.AzureDisk == nil { - yyn368 = true - goto LABEL368 - } - LABEL368: - if yyr351 || yy2arr351 { - if yyn368 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[16] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq351[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn368 { - r.EncodeNil() - } else { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } - } - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[17] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym370 := z.EncBinary() - _ = yym370 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq351[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym371 := z.EncBinary() - _ = yym371 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[18] { - if x.ClaimRef == nil { - r.EncodeNil() - } else { - x.ClaimRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq351[18] { - 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 yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[19] { - x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq351[19] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeReclaimPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) - } - } - if yyr351 || yy2arr351 { - 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 - yym374 := z.DecBinary() - _ = yym374 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct375 := r.ContainerType() - if yyct375 == codecSelferValueTypeMap1234 { - yyl375 := r.ReadMapStart() - if yyl375 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl375, d) - } - } else if yyct375 == codecSelferValueTypeArray1234 { - yyl375 := r.ReadArrayStart() - if yyl375 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl375, 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 yys376Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys376Slc - var yyhl376 bool = l >= 0 - for yyj376 := 0; ; yyj376++ { - if yyhl376 { - if yyj376 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys376Slc = r.DecodeBytes(yys376Slc, true, true) - yys376 := string(yys376Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys376 { - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv377 := &x.Capacity - yyv377.CodecDecodeSelf(d) - } - 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) - } - case "quobyte": - if x.PersistentVolumeSource.Quobyte == nil { - x.PersistentVolumeSource.Quobyte = new(QuobyteVolumeSource) - } - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - case "azureDisk": - if x.PersistentVolumeSource.AzureDisk == nil { - x.PersistentVolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv394 := &x.AccessModes - yym395 := z.DecBinary() - _ = yym395 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv394), 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()) - } - default: - z.DecStructFieldNotFound(-1, yys376) - } // end switch yys376 - } // end for yyj376 - 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 yyj398 int - var yyb398 bool - var yyhl398 bool = l >= 0 - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv399 := &x.Capacity - yyv399.CodecDecodeSelf(d) - } - if x.PersistentVolumeSource.GCEPersistentDisk == nil { - x.PersistentVolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - if x.PersistentVolumeSource.Quobyte == nil { - x.PersistentVolumeSource.Quobyte = new(QuobyteVolumeSource) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Quobyte != nil { - x.Quobyte = nil - } - } else { - if x.Quobyte == nil { - x.Quobyte = new(QuobyteVolumeSource) - } - x.Quobyte.CodecDecodeSelf(d) - } - if x.PersistentVolumeSource.AzureDisk == nil { - x.PersistentVolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv416 := &x.AccessModes - yym417 := z.DecBinary() - _ = yym417 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv416), d) - } - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - 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) - } - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PersistentVolumeReclaimPolicy = "" - } else { - x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString()) - } - for { - yyj398++ - if yyhl398 { - yyb398 = yyj398 > l - } else { - yyb398 = r.CheckBreak() - } - if yyb398 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj398-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PersistentVolumeReclaimPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym420 := z.EncBinary() - _ = yym420 - 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 - yym421 := z.DecBinary() - _ = yym421 - 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 { - yym422 := z.EncBinary() - _ = yym422 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep423 := !z.EncBinary() - yy2arr423 := z.EncBasicHandle().StructToArray - var yyq423 [3]bool - _, _, _ = yysep423, yyq423, yy2arr423 - const yyr423 bool = false - yyq423[0] = x.Phase != "" - yyq423[1] = x.Message != "" - yyq423[2] = x.Reason != "" - var yynn423 int - if yyr423 || yy2arr423 { - r.EncodeArrayStart(3) - } else { - yynn423 = 0 - for _, b := range yyq423 { - if b { - yynn423++ - } - } - r.EncodeMapStart(yynn423) - yynn423 = 0 - } - if yyr423 || yy2arr423 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq423[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq423[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr423 || yy2arr423 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq423[1] { - yym426 := z.EncBinary() - _ = yym426 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq423[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym427 := z.EncBinary() - _ = yym427 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr423 || yy2arr423 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq423[2] { - yym429 := z.EncBinary() - _ = yym429 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq423[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym430 := z.EncBinary() - _ = yym430 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr423 || yy2arr423 { - 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 - yym431 := z.DecBinary() - _ = yym431 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct432 := r.ContainerType() - if yyct432 == codecSelferValueTypeMap1234 { - yyl432 := r.ReadMapStart() - if yyl432 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl432, d) - } - } else if yyct432 == codecSelferValueTypeArray1234 { - yyl432 := r.ReadArrayStart() - if yyl432 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl432, 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 yys433Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys433Slc - var yyhl433 bool = l >= 0 - for yyj433 := 0; ; yyj433++ { - if yyhl433 { - if yyj433 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys433Slc = r.DecodeBytes(yys433Slc, true, true) - yys433 := string(yys433Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys433 { - 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, yys433) - } // end switch yys433 - } // end for yyj433 - 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 yyj437 int - var yyb437 bool - var yyhl437 bool = l >= 0 - yyj437++ - if yyhl437 { - yyb437 = yyj437 > l - } else { - yyb437 = r.CheckBreak() - } - if yyb437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumePhase(r.DecodeString()) - } - yyj437++ - if yyhl437 { - yyb437 = yyj437 > l - } else { - yyb437 = r.CheckBreak() - } - if yyb437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj437++ - if yyhl437 { - yyb437 = yyj437 > l - } else { - yyb437 = r.CheckBreak() - } - if yyb437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - for { - yyj437++ - if yyhl437 { - yyb437 = yyj437 > l - } else { - yyb437 = r.CheckBreak() - } - if yyb437 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj437-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 { - yym441 := z.EncBinary() - _ = yym441 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep442 := !z.EncBinary() - yy2arr442 := z.EncBasicHandle().StructToArray - var yyq442 [4]bool - _, _, _ = yysep442, yyq442, yy2arr442 - const yyr442 bool = false - yyq442[0] = x.Kind != "" - yyq442[1] = x.APIVersion != "" - yyq442[2] = true - var yynn442 int - if yyr442 || yy2arr442 { - r.EncodeArrayStart(4) - } else { - yynn442 = 1 - for _, b := range yyq442 { - if b { - yynn442++ - } - } - r.EncodeMapStart(yynn442) - yynn442 = 0 - } - if yyr442 || yy2arr442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq442[0] { - yym444 := z.EncBinary() - _ = yym444 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq442[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym445 := z.EncBinary() - _ = yym445 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr442 || yy2arr442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq442[1] { - yym447 := z.EncBinary() - _ = yym447 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq442[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym448 := z.EncBinary() - _ = yym448 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr442 || yy2arr442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq442[2] { - yy450 := &x.ListMeta - yym451 := z.EncBinary() - _ = yym451 - if false { - } else if z.HasExtensions() && z.EncExt(yy450) { - } else { - z.EncFallback(yy450) - } - } else { - r.EncodeNil() - } - } else { - if yyq442[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy452 := &x.ListMeta - yym453 := z.EncBinary() - _ = yym453 - if false { - } else if z.HasExtensions() && z.EncExt(yy452) { - } else { - z.EncFallback(yy452) - } - } - } - if yyr442 || yy2arr442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym455 := z.EncBinary() - _ = yym455 - 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 { - yym456 := z.EncBinary() - _ = yym456 - if false { - } else { - h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e) - } - } - } - if yyr442 || yy2arr442 { - 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 - yym457 := z.DecBinary() - _ = yym457 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct458 := r.ContainerType() - if yyct458 == codecSelferValueTypeMap1234 { - yyl458 := r.ReadMapStart() - if yyl458 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl458, d) - } - } else if yyct458 == codecSelferValueTypeArray1234 { - yyl458 := r.ReadArrayStart() - if yyl458 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl458, 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 yys459Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys459Slc - var yyhl459 bool = l >= 0 - for yyj459 := 0; ; yyj459++ { - if yyhl459 { - if yyj459 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys459Slc = r.DecodeBytes(yys459Slc, true, true) - yys459 := string(yys459Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys459 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv462 := &x.ListMeta - yym463 := z.DecBinary() - _ = yym463 - if false { - } else if z.HasExtensions() && z.DecExt(yyv462) { - } else { - z.DecFallback(yyv462, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv464 := &x.Items - yym465 := z.DecBinary() - _ = yym465 - if false { - } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv464), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys459) - } // end switch yys459 - } // end for yyj459 - 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 yyj466 int - var yyb466 bool - var yyhl466 bool = l >= 0 - yyj466++ - if yyhl466 { - yyb466 = yyj466 > l - } else { - yyb466 = r.CheckBreak() - } - if yyb466 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj466++ - if yyhl466 { - yyb466 = yyj466 > l - } else { - yyb466 = r.CheckBreak() - } - if yyb466 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj466++ - if yyhl466 { - yyb466 = yyj466 > l - } else { - yyb466 = r.CheckBreak() - } - if yyb466 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv469 := &x.ListMeta - yym470 := z.DecBinary() - _ = yym470 - if false { - } else if z.HasExtensions() && z.DecExt(yyv469) { - } else { - z.DecFallback(yyv469, false) - } - } - yyj466++ - if yyhl466 { - yyb466 = yyj466 > l - } else { - yyb466 = r.CheckBreak() - } - if yyb466 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv471 := &x.Items - yym472 := z.DecBinary() - _ = yym472 - if false { - } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv471), d) - } - } - for { - yyj466++ - if yyhl466 { - yyb466 = yyj466 > l - } else { - yyb466 = r.CheckBreak() - } - if yyb466 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj466-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 { - yym473 := z.EncBinary() - _ = yym473 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep474 := !z.EncBinary() - yy2arr474 := z.EncBasicHandle().StructToArray - var yyq474 [5]bool - _, _, _ = yysep474, yyq474, yy2arr474 - const yyr474 bool = false - yyq474[0] = x.Kind != "" - yyq474[1] = x.APIVersion != "" - yyq474[2] = true - yyq474[3] = true - yyq474[4] = true - var yynn474 int - if yyr474 || yy2arr474 { - r.EncodeArrayStart(5) - } else { - yynn474 = 0 - for _, b := range yyq474 { - if b { - yynn474++ - } - } - r.EncodeMapStart(yynn474) - yynn474 = 0 - } - if yyr474 || yy2arr474 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq474[0] { - yym476 := z.EncBinary() - _ = yym476 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq474[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym477 := z.EncBinary() - _ = yym477 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr474 || yy2arr474 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq474[1] { - yym479 := z.EncBinary() - _ = yym479 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq474[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym480 := z.EncBinary() - _ = yym480 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr474 || yy2arr474 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq474[2] { - yy482 := &x.ObjectMeta - yy482.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq474[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy483 := &x.ObjectMeta - yy483.CodecEncodeSelf(e) - } - } - if yyr474 || yy2arr474 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq474[3] { - yy485 := &x.Spec - yy485.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq474[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy486 := &x.Spec - yy486.CodecEncodeSelf(e) - } - } - if yyr474 || yy2arr474 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq474[4] { - yy488 := &x.Status - yy488.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq474[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy489 := &x.Status - yy489.CodecEncodeSelf(e) - } - } - if yyr474 || yy2arr474 { - 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 - yym490 := z.DecBinary() - _ = yym490 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct491 := r.ContainerType() - if yyct491 == codecSelferValueTypeMap1234 { - yyl491 := r.ReadMapStart() - if yyl491 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl491, d) - } - } else if yyct491 == codecSelferValueTypeArray1234 { - yyl491 := r.ReadArrayStart() - if yyl491 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl491, 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 yys492Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys492Slc - var yyhl492 bool = l >= 0 - for yyj492 := 0; ; yyj492++ { - if yyhl492 { - if yyj492 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys492Slc = r.DecodeBytes(yys492Slc, true, true) - yys492 := string(yys492Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys492 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv495 := &x.ObjectMeta - yyv495.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeClaimSpec{} - } else { - yyv496 := &x.Spec - yyv496.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeClaimStatus{} - } else { - yyv497 := &x.Status - yyv497.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys492) - } // end switch yys492 - } // end for yyj492 - 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 yyj498 int - var yyb498 bool - var yyhl498 bool = l >= 0 - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv501 := &x.ObjectMeta - yyv501.CodecDecodeSelf(d) - } - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeClaimSpec{} - } else { - yyv502 := &x.Spec - yyv502.CodecDecodeSelf(d) - } - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeClaimStatus{} - } else { - yyv503 := &x.Status - yyv503.CodecDecodeSelf(d) - } - for { - yyj498++ - if yyhl498 { - yyb498 = yyj498 > l - } else { - yyb498 = r.CheckBreak() - } - if yyb498 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj498-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 { - yym504 := z.EncBinary() - _ = yym504 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep505 := !z.EncBinary() - yy2arr505 := z.EncBasicHandle().StructToArray - var yyq505 [4]bool - _, _, _ = yysep505, yyq505, yy2arr505 - const yyr505 bool = false - yyq505[0] = x.Kind != "" - yyq505[1] = x.APIVersion != "" - yyq505[2] = true - var yynn505 int - if yyr505 || yy2arr505 { - r.EncodeArrayStart(4) - } else { - yynn505 = 1 - for _, b := range yyq505 { - if b { - yynn505++ - } - } - r.EncodeMapStart(yynn505) - yynn505 = 0 - } - if yyr505 || yy2arr505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq505[0] { - yym507 := z.EncBinary() - _ = yym507 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq505[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym508 := z.EncBinary() - _ = yym508 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr505 || yy2arr505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq505[1] { - yym510 := z.EncBinary() - _ = yym510 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq505[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym511 := z.EncBinary() - _ = yym511 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr505 || yy2arr505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq505[2] { - yy513 := &x.ListMeta - yym514 := z.EncBinary() - _ = yym514 - if false { - } else if z.HasExtensions() && z.EncExt(yy513) { - } else { - z.EncFallback(yy513) - } - } else { - r.EncodeNil() - } - } else { - if yyq505[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy515 := &x.ListMeta - yym516 := z.EncBinary() - _ = yym516 - if false { - } else if z.HasExtensions() && z.EncExt(yy515) { - } else { - z.EncFallback(yy515) - } - } - } - if yyr505 || yy2arr505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym518 := z.EncBinary() - _ = yym518 - 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 { - yym519 := z.EncBinary() - _ = yym519 - if false { - } else { - h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e) - } - } - } - if yyr505 || yy2arr505 { - 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 - yym520 := z.DecBinary() - _ = yym520 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct521 := r.ContainerType() - if yyct521 == codecSelferValueTypeMap1234 { - yyl521 := r.ReadMapStart() - if yyl521 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl521, d) - } - } else if yyct521 == codecSelferValueTypeArray1234 { - yyl521 := r.ReadArrayStart() - if yyl521 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl521, 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 yys522Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys522Slc - var yyhl522 bool = l >= 0 - for yyj522 := 0; ; yyj522++ { - if yyhl522 { - if yyj522 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys522Slc = r.DecodeBytes(yys522Slc, true, true) - yys522 := string(yys522Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys522 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv525 := &x.ListMeta - yym526 := z.DecBinary() - _ = yym526 - if false { - } else if z.HasExtensions() && z.DecExt(yyv525) { - } else { - z.DecFallback(yyv525, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv527 := &x.Items - yym528 := z.DecBinary() - _ = yym528 - if false { - } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv527), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys522) - } // end switch yys522 - } // end for yyj522 - 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 yyj529 int - var yyb529 bool - var yyhl529 bool = l >= 0 - yyj529++ - if yyhl529 { - yyb529 = yyj529 > l - } else { - yyb529 = r.CheckBreak() - } - if yyb529 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj529++ - if yyhl529 { - yyb529 = yyj529 > l - } else { - yyb529 = r.CheckBreak() - } - if yyb529 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj529++ - if yyhl529 { - yyb529 = yyj529 > l - } else { - yyb529 = r.CheckBreak() - } - if yyb529 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv532 := &x.ListMeta - yym533 := z.DecBinary() - _ = yym533 - if false { - } else if z.HasExtensions() && z.DecExt(yyv532) { - } else { - z.DecFallback(yyv532, false) - } - } - yyj529++ - if yyhl529 { - yyb529 = yyj529 > l - } else { - yyb529 = r.CheckBreak() - } - if yyb529 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv534 := &x.Items - yym535 := z.DecBinary() - _ = yym535 - if false { - } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv534), d) - } - } - for { - yyj529++ - if yyhl529 { - yyb529 = yyj529 > l - } else { - yyb529 = r.CheckBreak() - } - if yyb529 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj529-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 { - yym536 := z.EncBinary() - _ = yym536 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep537 := !z.EncBinary() - yy2arr537 := z.EncBasicHandle().StructToArray - var yyq537 [4]bool - _, _, _ = yysep537, yyq537, yy2arr537 - const yyr537 bool = false - yyq537[0] = len(x.AccessModes) != 0 - yyq537[1] = x.Selector != nil - yyq537[2] = true - yyq537[3] = x.VolumeName != "" - var yynn537 int - if yyr537 || yy2arr537 { - r.EncodeArrayStart(4) - } else { - yynn537 = 0 - for _, b := range yyq537 { - if b { - yynn537++ - } - } - r.EncodeMapStart(yynn537) - yynn537 = 0 - } - if yyr537 || yy2arr537 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq537[0] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym539 := z.EncBinary() - _ = yym539 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq537[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym540 := z.EncBinary() - _ = yym540 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr537 || yy2arr537 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq537[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym542 := z.EncBinary() - _ = yym542 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq537[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym543 := z.EncBinary() - _ = yym543 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr537 || yy2arr537 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq537[2] { - yy545 := &x.Resources - yy545.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq537[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resources")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy546 := &x.Resources - yy546.CodecEncodeSelf(e) - } - } - if yyr537 || yy2arr537 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq537[3] { - yym548 := z.EncBinary() - _ = yym548 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq537[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym549 := z.EncBinary() - _ = yym549 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) - } - } - } - if yyr537 || yy2arr537 { - 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 - yym550 := z.DecBinary() - _ = yym550 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct551 := r.ContainerType() - if yyct551 == codecSelferValueTypeMap1234 { - yyl551 := r.ReadMapStart() - if yyl551 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl551, d) - } - } else if yyct551 == codecSelferValueTypeArray1234 { - yyl551 := r.ReadArrayStart() - if yyl551 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl551, 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 yys552Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys552Slc - var yyhl552 bool = l >= 0 - for yyj552 := 0; ; yyj552++ { - if yyhl552 { - if yyj552 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys552Slc = r.DecodeBytes(yys552Slc, true, true) - yys552 := string(yys552Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys552 { - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv553 := &x.AccessModes - yym554 := z.DecBinary() - _ = yym554 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv553), d) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) - } - yym556 := z.DecBinary() - _ = yym556 - 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 { - yyv557 := &x.Resources - yyv557.CodecDecodeSelf(d) - } - case "volumeName": - if r.TryDecodeAsNil() { - x.VolumeName = "" - } else { - x.VolumeName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys552) - } // end switch yys552 - } // end for yyj552 - 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 yyj559 int - var yyb559 bool - var yyhl559 bool = l >= 0 - yyj559++ - if yyhl559 { - yyb559 = yyj559 > l - } else { - yyb559 = r.CheckBreak() - } - if yyb559 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv560 := &x.AccessModes - yym561 := z.DecBinary() - _ = yym561 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv560), d) - } - } - yyj559++ - if yyhl559 { - yyb559 = yyj559 > l - } else { - yyb559 = r.CheckBreak() - } - if yyb559 { - 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) - } - yym563 := z.DecBinary() - _ = yym563 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj559++ - if yyhl559 { - yyb559 = yyj559 > l - } else { - yyb559 = r.CheckBreak() - } - if yyb559 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resources = ResourceRequirements{} - } else { - yyv564 := &x.Resources - yyv564.CodecDecodeSelf(d) - } - yyj559++ - if yyhl559 { - yyb559 = yyj559 > l - } else { - yyb559 = r.CheckBreak() - } - if yyb559 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeName = "" - } else { - x.VolumeName = string(r.DecodeString()) - } - for { - yyj559++ - if yyhl559 { - yyb559 = yyj559 > l - } else { - yyb559 = r.CheckBreak() - } - if yyb559 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj559-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 { - yym566 := z.EncBinary() - _ = yym566 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep567 := !z.EncBinary() - yy2arr567 := z.EncBasicHandle().StructToArray - var yyq567 [3]bool - _, _, _ = yysep567, yyq567, yy2arr567 - const yyr567 bool = false - yyq567[0] = x.Phase != "" - yyq567[1] = len(x.AccessModes) != 0 - yyq567[2] = len(x.Capacity) != 0 - var yynn567 int - if yyr567 || yy2arr567 { - r.EncodeArrayStart(3) - } else { - yynn567 = 0 - for _, b := range yyq567 { - if b { - yynn567++ - } - } - r.EncodeMapStart(yynn567) - yynn567 = 0 - } - if yyr567 || yy2arr567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq567[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq567[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr567 || yy2arr567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq567[1] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym570 := z.EncBinary() - _ = yym570 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq567[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym571 := z.EncBinary() - _ = yym571 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr567 || yy2arr567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq567[2] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq567[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 yyr567 || yy2arr567 { - 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 - yym573 := z.DecBinary() - _ = yym573 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct574 := r.ContainerType() - if yyct574 == codecSelferValueTypeMap1234 { - yyl574 := r.ReadMapStart() - if yyl574 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl574, d) - } - } else if yyct574 == codecSelferValueTypeArray1234 { - yyl574 := r.ReadArrayStart() - if yyl574 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl574, 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 yys575Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys575Slc - var yyhl575 bool = l >= 0 - for yyj575 := 0; ; yyj575++ { - if yyhl575 { - if yyj575 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys575Slc = r.DecodeBytes(yys575Slc, true, true) - yys575 := string(yys575Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys575 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) - } - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv577 := &x.AccessModes - yym578 := z.DecBinary() - _ = yym578 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv577), d) - } - } - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv579 := &x.Capacity - yyv579.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys575) - } // end switch yys575 - } // end for yyj575 - 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 yyj580 int - var yyb580 bool - var yyhl580 bool = l >= 0 - yyj580++ - if yyhl580 { - yyb580 = yyj580 > l - } else { - yyb580 = r.CheckBreak() - } - if yyb580 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) - } - yyj580++ - if yyhl580 { - yyb580 = yyj580 > l - } else { - yyb580 = r.CheckBreak() - } - if yyb580 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv582 := &x.AccessModes - yym583 := z.DecBinary() - _ = yym583 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv582), d) - } - } - yyj580++ - if yyhl580 { - yyb580 = yyj580 > l - } else { - yyb580 = r.CheckBreak() - } - if yyb580 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv584 := &x.Capacity - yyv584.CodecDecodeSelf(d) - } - for { - yyj580++ - if yyhl580 { - yyb580 = yyj580 > l - } else { - yyb580 = r.CheckBreak() - } - if yyb580 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj580-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PersistentVolumeAccessMode) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym585 := z.EncBinary() - _ = yym585 - 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 - yym586 := z.DecBinary() - _ = yym586 - 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 - yym587 := z.EncBinary() - _ = yym587 - 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 - yym588 := z.DecBinary() - _ = yym588 - 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 - yym589 := z.EncBinary() - _ = yym589 - 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 - yym590 := z.DecBinary() - _ = yym590 - 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 { - yym591 := z.EncBinary() - _ = yym591 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep592 := !z.EncBinary() - yy2arr592 := z.EncBasicHandle().StructToArray - var yyq592 [1]bool - _, _, _ = yysep592, yyq592, yy2arr592 - const yyr592 bool = false - var yynn592 int - if yyr592 || yy2arr592 { - r.EncodeArrayStart(1) - } else { - yynn592 = 1 - for _, b := range yyq592 { - if b { - yynn592++ - } - } - r.EncodeMapStart(yynn592) - yynn592 = 0 - } - if yyr592 || yy2arr592 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym594 := z.EncBinary() - _ = yym594 - 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) - yym595 := z.EncBinary() - _ = yym595 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr592 || yy2arr592 { - 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 - yym596 := z.DecBinary() - _ = yym596 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct597 := r.ContainerType() - if yyct597 == codecSelferValueTypeMap1234 { - yyl597 := r.ReadMapStart() - if yyl597 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl597, d) - } - } else if yyct597 == codecSelferValueTypeArray1234 { - yyl597 := r.ReadArrayStart() - if yyl597 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl597, 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 yys598Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys598Slc - var yyhl598 bool = l >= 0 - for yyj598 := 0; ; yyj598++ { - if yyhl598 { - if yyj598 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys598Slc = r.DecodeBytes(yys598Slc, true, true) - yys598 := string(yys598Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys598 { - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys598) - } // end switch yys598 - } // end for yyj598 - 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 yyj600 int - var yyb600 bool - var yyhl600 bool = l >= 0 - yyj600++ - if yyhl600 { - yyb600 = yyj600 > l - } else { - yyb600 = r.CheckBreak() - } - if yyb600 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj600++ - if yyhl600 { - yyb600 = yyj600 > l - } else { - yyb600 = r.CheckBreak() - } - if yyb600 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj600-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 { - yym602 := z.EncBinary() - _ = yym602 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep603 := !z.EncBinary() - yy2arr603 := z.EncBasicHandle().StructToArray - var yyq603 [1]bool - _, _, _ = yysep603, yyq603, yy2arr603 - const yyr603 bool = false - yyq603[0] = x.Medium != "" - var yynn603 int - if yyr603 || yy2arr603 { - r.EncodeArrayStart(1) - } else { - yynn603 = 0 - for _, b := range yyq603 { - if b { - yynn603++ - } - } - r.EncodeMapStart(yynn603) - yynn603 = 0 - } - if yyr603 || yy2arr603 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq603[0] { - x.Medium.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq603[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("medium")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Medium.CodecEncodeSelf(e) - } - } - if yyr603 || yy2arr603 { - 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 - yym605 := z.DecBinary() - _ = yym605 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct606 := r.ContainerType() - if yyct606 == codecSelferValueTypeMap1234 { - yyl606 := r.ReadMapStart() - if yyl606 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl606, d) - } - } else if yyct606 == codecSelferValueTypeArray1234 { - yyl606 := r.ReadArrayStart() - if yyl606 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl606, 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 yys607Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys607Slc - var yyhl607 bool = l >= 0 - for yyj607 := 0; ; yyj607++ { - if yyhl607 { - if yyj607 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys607Slc = r.DecodeBytes(yys607Slc, true, true) - yys607 := string(yys607Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys607 { - case "medium": - if r.TryDecodeAsNil() { - x.Medium = "" - } else { - x.Medium = StorageMedium(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys607) - } // end switch yys607 - } // end for yyj607 - 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 yyj609 int - var yyb609 bool - var yyhl609 bool = l >= 0 - yyj609++ - if yyhl609 { - yyb609 = yyj609 > l - } else { - yyb609 = r.CheckBreak() - } - if yyb609 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Medium = "" - } else { - x.Medium = StorageMedium(r.DecodeString()) - } - for { - yyj609++ - if yyhl609 { - yyb609 = yyj609 > l - } else { - yyb609 = r.CheckBreak() - } - if yyb609 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj609-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 { - yym611 := z.EncBinary() - _ = yym611 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep612 := !z.EncBinary() - yy2arr612 := z.EncBasicHandle().StructToArray - var yyq612 [3]bool - _, _, _ = yysep612, yyq612, yy2arr612 - const yyr612 bool = false - yyq612[2] = x.ReadOnly != false - var yynn612 int - if yyr612 || yy2arr612 { - r.EncodeArrayStart(3) - } else { - yynn612 = 2 - for _, b := range yyq612 { - if b { - yynn612++ - } - } - r.EncodeMapStart(yynn612) - yynn612 = 0 - } - if yyr612 || yy2arr612 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym614 := z.EncBinary() - _ = yym614 - 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) - yym615 := z.EncBinary() - _ = yym615 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName)) - } - } - if yyr612 || yy2arr612 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym617 := z.EncBinary() - _ = yym617 - 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) - yym618 := z.EncBinary() - _ = yym618 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr612 || yy2arr612 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq612[2] { - yym620 := z.EncBinary() - _ = yym620 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq612[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym621 := z.EncBinary() - _ = yym621 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr612 || yy2arr612 { - 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 - yym622 := z.DecBinary() - _ = yym622 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct623 := r.ContainerType() - if yyct623 == codecSelferValueTypeMap1234 { - yyl623 := r.ReadMapStart() - if yyl623 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl623, d) - } - } else if yyct623 == codecSelferValueTypeArray1234 { - yyl623 := r.ReadArrayStart() - if yyl623 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl623, 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 yys624Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys624Slc - var yyhl624 bool = l >= 0 - for yyj624 := 0; ; yyj624++ { - if yyhl624 { - if yyj624 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys624Slc = r.DecodeBytes(yys624Slc, true, true) - yys624 := string(yys624Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys624 { - 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, yys624) - } // end switch yys624 - } // end for yyj624 - 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 yyj628 int - var yyb628 bool - var yyhl628 bool = l >= 0 - yyj628++ - if yyhl628 { - yyb628 = yyj628 > l - } else { - yyb628 = r.CheckBreak() - } - if yyb628 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.EndpointsName = "" - } else { - x.EndpointsName = string(r.DecodeString()) - } - yyj628++ - if yyhl628 { - yyb628 = yyj628 > l - } else { - yyb628 = r.CheckBreak() - } - if yyb628 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj628++ - if yyhl628 { - yyb628 = yyj628 > l - } else { - yyb628 = r.CheckBreak() - } - if yyb628 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj628++ - if yyhl628 { - yyb628 = yyj628 > l - } else { - yyb628 = r.CheckBreak() - } - if yyb628 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj628-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 { - yym632 := z.EncBinary() - _ = yym632 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep633 := !z.EncBinary() - yy2arr633 := z.EncBasicHandle().StructToArray - var yyq633 [8]bool - _, _, _ = yysep633, yyq633, yy2arr633 - const yyr633 bool = false - yyq633[2] = x.FSType != "" - yyq633[3] = x.RBDPool != "" - yyq633[4] = x.RadosUser != "" - yyq633[5] = x.Keyring != "" - yyq633[6] = x.SecretRef != nil - yyq633[7] = x.ReadOnly != false - var yynn633 int - if yyr633 || yy2arr633 { - r.EncodeArrayStart(8) - } else { - yynn633 = 2 - for _, b := range yyq633 { - if b { - yynn633++ - } - } - r.EncodeMapStart(yynn633) - yynn633 = 0 - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.CephMonitors == nil { - r.EncodeNil() - } else { - yym635 := z.EncBinary() - _ = yym635 - 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 { - yym636 := z.EncBinary() - _ = yym636 - if false { - } else { - z.F.EncSliceStringV(x.CephMonitors, false, e) - } - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym638 := z.EncBinary() - _ = yym638 - 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) - yym639 := z.EncBinary() - _ = yym639 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage)) - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[2] { - yym641 := z.EncBinary() - _ = yym641 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq633[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym642 := z.EncBinary() - _ = yym642 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[3] { - yym644 := z.EncBinary() - _ = yym644 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq633[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("pool")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym645 := z.EncBinary() - _ = yym645 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) - } - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[4] { - yym647 := z.EncBinary() - _ = yym647 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq633[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym648 := z.EncBinary() - _ = yym648 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) - } - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[5] { - yym650 := z.EncBinary() - _ = yym650 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq633[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("keyring")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym651 := z.EncBinary() - _ = yym651 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) - } - } - } - if yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[6] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq633[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 yyr633 || yy2arr633 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq633[7] { - yym654 := z.EncBinary() - _ = yym654 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq633[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym655 := z.EncBinary() - _ = yym655 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr633 || yy2arr633 { - 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 - yym656 := z.DecBinary() - _ = yym656 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct657 := r.ContainerType() - if yyct657 == codecSelferValueTypeMap1234 { - yyl657 := r.ReadMapStart() - if yyl657 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl657, d) - } - } else if yyct657 == codecSelferValueTypeArray1234 { - yyl657 := r.ReadArrayStart() - if yyl657 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl657, 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 yys658Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys658Slc - var yyhl658 bool = l >= 0 - for yyj658 := 0; ; yyj658++ { - if yyhl658 { - if yyj658 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys658Slc = r.DecodeBytes(yys658Slc, true, true) - yys658 := string(yys658Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys658 { - case "monitors": - if r.TryDecodeAsNil() { - x.CephMonitors = nil - } else { - yyv659 := &x.CephMonitors - yym660 := z.DecBinary() - _ = yym660 - if false { - } else { - z.F.DecSliceStringX(yyv659, 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, yys658) - } // end switch yys658 - } // end for yyj658 - 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 yyj668 int - var yyb668 bool - var yyhl668 bool = l >= 0 - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CephMonitors = nil - } else { - yyv669 := &x.CephMonitors - yym670 := z.DecBinary() - _ = yym670 - if false { - } else { - z.F.DecSliceStringX(yyv669, false, d) - } - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RBDImage = "" - } else { - x.RBDImage = string(r.DecodeString()) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RBDPool = "" - } else { - x.RBDPool = string(r.DecodeString()) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RadosUser = "" - } else { - x.RadosUser = string(r.DecodeString()) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Keyring = "" - } else { - x.Keyring = string(r.DecodeString()) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - 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) - } - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj668++ - if yyhl668 { - yyb668 = yyj668 > l - } else { - yyb668 = r.CheckBreak() - } - if yyb668 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj668-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 { - yym678 := z.EncBinary() - _ = yym678 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep679 := !z.EncBinary() - yy2arr679 := z.EncBasicHandle().StructToArray - var yyq679 [3]bool - _, _, _ = yysep679, yyq679, yy2arr679 - const yyr679 bool = false - yyq679[1] = x.FSType != "" - yyq679[2] = x.ReadOnly != false - var yynn679 int - if yyr679 || yy2arr679 { - r.EncodeArrayStart(3) - } else { - yynn679 = 1 - for _, b := range yyq679 { - if b { - yynn679++ - } - } - r.EncodeMapStart(yynn679) - yynn679 = 0 - } - if yyr679 || yy2arr679 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym681 := z.EncBinary() - _ = yym681 - 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) - yym682 := z.EncBinary() - _ = yym682 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) - } - } - if yyr679 || yy2arr679 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq679[1] { - yym684 := z.EncBinary() - _ = yym684 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq679[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym685 := z.EncBinary() - _ = yym685 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr679 || yy2arr679 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq679[2] { - yym687 := z.EncBinary() - _ = yym687 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq679[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym688 := z.EncBinary() - _ = yym688 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr679 || yy2arr679 { - 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 - yym689 := z.DecBinary() - _ = yym689 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct690 := r.ContainerType() - if yyct690 == codecSelferValueTypeMap1234 { - yyl690 := r.ReadMapStart() - if yyl690 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl690, d) - } - } else if yyct690 == codecSelferValueTypeArray1234 { - yyl690 := r.ReadArrayStart() - if yyl690 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl690, 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 yys691Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys691Slc - var yyhl691 bool = l >= 0 - for yyj691 := 0; ; yyj691++ { - if yyhl691 { - if yyj691 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys691Slc = r.DecodeBytes(yys691Slc, true, true) - yys691 := string(yys691Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys691 { - 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, yys691) - } // end switch yys691 - } // end for yyj691 - 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 yyj695 int - var yyb695 bool - var yyhl695 bool = l >= 0 - yyj695++ - if yyhl695 { - yyb695 = yyj695 > l - } else { - yyb695 = r.CheckBreak() - } - if yyb695 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeID = "" - } else { - x.VolumeID = string(r.DecodeString()) - } - yyj695++ - if yyhl695 { - yyb695 = yyj695 > l - } else { - yyb695 = r.CheckBreak() - } - if yyb695 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj695++ - if yyhl695 { - yyb695 = yyj695 > l - } else { - yyb695 = r.CheckBreak() - } - if yyb695 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj695++ - if yyhl695 { - yyb695 = yyj695 > l - } else { - yyb695 = r.CheckBreak() - } - if yyb695 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj695-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 { - yym699 := z.EncBinary() - _ = yym699 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep700 := !z.EncBinary() - yy2arr700 := z.EncBasicHandle().StructToArray - var yyq700 [6]bool - _, _, _ = yysep700, yyq700, yy2arr700 - const yyr700 bool = false - yyq700[1] = x.Path != "" - yyq700[2] = x.User != "" - yyq700[3] = x.SecretFile != "" - yyq700[4] = x.SecretRef != nil - yyq700[5] = x.ReadOnly != false - var yynn700 int - if yyr700 || yy2arr700 { - r.EncodeArrayStart(6) - } else { - yynn700 = 1 - for _, b := range yyq700 { - if b { - yynn700++ - } - } - r.EncodeMapStart(yynn700) - yynn700 = 0 - } - if yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Monitors == nil { - r.EncodeNil() - } else { - yym702 := z.EncBinary() - _ = yym702 - 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 { - yym703 := z.EncBinary() - _ = yym703 - if false { - } else { - z.F.EncSliceStringV(x.Monitors, false, e) - } - } - } - if yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq700[1] { - yym705 := z.EncBinary() - _ = yym705 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq700[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym706 := z.EncBinary() - _ = yym706 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq700[2] { - yym708 := z.EncBinary() - _ = yym708 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq700[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym709 := z.EncBinary() - _ = yym709 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq700[3] { - yym711 := z.EncBinary() - _ = yym711 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq700[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym712 := z.EncBinary() - _ = yym712 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) - } - } - } - if yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq700[4] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq700[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 yyr700 || yy2arr700 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq700[5] { - yym715 := z.EncBinary() - _ = yym715 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq700[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym716 := z.EncBinary() - _ = yym716 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr700 || yy2arr700 { - 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 - yym717 := z.DecBinary() - _ = yym717 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct718 := r.ContainerType() - if yyct718 == codecSelferValueTypeMap1234 { - yyl718 := r.ReadMapStart() - if yyl718 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl718, d) - } - } else if yyct718 == codecSelferValueTypeArray1234 { - yyl718 := r.ReadArrayStart() - if yyl718 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl718, 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 yys719Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys719Slc - var yyhl719 bool = l >= 0 - for yyj719 := 0; ; yyj719++ { - if yyhl719 { - if yyj719 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys719Slc = r.DecodeBytes(yys719Slc, true, true) - yys719 := string(yys719Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys719 { - case "monitors": - if r.TryDecodeAsNil() { - x.Monitors = nil - } else { - yyv720 := &x.Monitors - yym721 := z.DecBinary() - _ = yym721 - if false { - } else { - z.F.DecSliceStringX(yyv720, 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, yys719) - } // end switch yys719 - } // end for yyj719 - 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 yyj727 int - var yyb727 bool - var yyhl727 bool = l >= 0 - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Monitors = nil - } else { - yyv728 := &x.Monitors - yym729 := z.DecBinary() - _ = yym729 - if false { - } else { - z.F.DecSliceStringX(yyv728, false, d) - } - } - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretFile = "" - } else { - x.SecretFile = string(r.DecodeString()) - } - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - 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) - } - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj727++ - if yyhl727 { - yyb727 = yyj727 > l - } else { - yyb727 = r.CheckBreak() - } - if yyb727 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj727-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 { - yym735 := z.EncBinary() - _ = yym735 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep736 := !z.EncBinary() - yy2arr736 := z.EncBasicHandle().StructToArray - var yyq736 [1]bool - _, _, _ = yysep736, yyq736, yy2arr736 - const yyr736 bool = false - var yynn736 int - if yyr736 || yy2arr736 { - r.EncodeArrayStart(1) - } else { - yynn736 = 1 - for _, b := range yyq736 { - if b { - yynn736++ - } - } - r.EncodeMapStart(yynn736) - yynn736 = 0 - } - if yyr736 || yy2arr736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym738 := z.EncBinary() - _ = yym738 - 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) - yym739 := z.EncBinary() - _ = yym739 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName)) - } - } - if yyr736 || yy2arr736 { - 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 - yym740 := z.DecBinary() - _ = yym740 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct741 := r.ContainerType() - if yyct741 == codecSelferValueTypeMap1234 { - yyl741 := r.ReadMapStart() - if yyl741 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl741, d) - } - } else if yyct741 == codecSelferValueTypeArray1234 { - yyl741 := r.ReadArrayStart() - if yyl741 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl741, 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 yys742Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys742Slc - var yyhl742 bool = l >= 0 - for yyj742 := 0; ; yyj742++ { - if yyhl742 { - if yyj742 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys742Slc = r.DecodeBytes(yys742Slc, true, true) - yys742 := string(yys742Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys742 { - case "datasetName": - if r.TryDecodeAsNil() { - x.DatasetName = "" - } else { - x.DatasetName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys742) - } // end switch yys742 - } // end for yyj742 - 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 yyj744 int - var yyb744 bool - var yyhl744 bool = l >= 0 - yyj744++ - if yyhl744 { - yyb744 = yyj744 > l - } else { - yyb744 = r.CheckBreak() - } - if yyb744 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DatasetName = "" - } else { - x.DatasetName = string(r.DecodeString()) - } - for { - yyj744++ - if yyhl744 { - yyb744 = yyj744 > l - } else { - yyb744 = r.CheckBreak() - } - if yyb744 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj744-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x StorageMedium) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym746 := z.EncBinary() - _ = yym746 - 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 - yym747 := z.DecBinary() - _ = yym747 - 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 - yym748 := z.EncBinary() - _ = yym748 - 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 - yym749 := z.DecBinary() - _ = yym749 - 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 { - yym750 := z.EncBinary() - _ = yym750 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep751 := !z.EncBinary() - yy2arr751 := z.EncBasicHandle().StructToArray - var yyq751 [4]bool - _, _, _ = yysep751, yyq751, yy2arr751 - const yyr751 bool = false - yyq751[1] = x.FSType != "" - yyq751[2] = x.Partition != 0 - yyq751[3] = x.ReadOnly != false - var yynn751 int - if yyr751 || yy2arr751 { - r.EncodeArrayStart(4) - } else { - yynn751 = 1 - for _, b := range yyq751 { - if b { - yynn751++ - } - } - r.EncodeMapStart(yynn751) - yynn751 = 0 - } - if yyr751 || yy2arr751 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym753 := z.EncBinary() - _ = yym753 - 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) - yym754 := z.EncBinary() - _ = yym754 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PDName)) - } - } - if yyr751 || yy2arr751 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq751[1] { - yym756 := z.EncBinary() - _ = yym756 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq751[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym757 := z.EncBinary() - _ = yym757 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr751 || yy2arr751 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq751[2] { - yym759 := z.EncBinary() - _ = yym759 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq751[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("partition")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym760 := z.EncBinary() - _ = yym760 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } - } - if yyr751 || yy2arr751 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq751[3] { - yym762 := z.EncBinary() - _ = yym762 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq751[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym763 := z.EncBinary() - _ = yym763 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr751 || yy2arr751 { - 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 - yym764 := z.DecBinary() - _ = yym764 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct765 := r.ContainerType() - if yyct765 == codecSelferValueTypeMap1234 { - yyl765 := r.ReadMapStart() - if yyl765 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl765, d) - } - } else if yyct765 == codecSelferValueTypeArray1234 { - yyl765 := r.ReadArrayStart() - if yyl765 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl765, 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 yys766Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys766Slc - var yyhl766 bool = l >= 0 - for yyj766 := 0; ; yyj766++ { - if yyhl766 { - if yyj766 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys766Slc = r.DecodeBytes(yys766Slc, true, true) - yys766 := string(yys766Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys766 { - 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, yys766) - } // end switch yys766 - } // end for yyj766 - 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 yyj771 int - var yyb771 bool - var yyhl771 bool = l >= 0 - yyj771++ - if yyhl771 { - yyb771 = yyj771 > l - } else { - yyb771 = r.CheckBreak() - } - if yyb771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PDName = "" - } else { - x.PDName = string(r.DecodeString()) - } - yyj771++ - if yyhl771 { - yyb771 = yyj771 > l - } else { - yyb771 = r.CheckBreak() - } - if yyb771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj771++ - if yyhl771 { - yyb771 = yyj771 > l - } else { - yyb771 = r.CheckBreak() - } - if yyb771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Partition = 0 - } else { - x.Partition = int32(r.DecodeInt(32)) - } - yyj771++ - if yyhl771 { - yyb771 = yyj771 > l - } else { - yyb771 = r.CheckBreak() - } - if yyb771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj771++ - if yyhl771 { - yyb771 = yyj771 > l - } else { - yyb771 = r.CheckBreak() - } - if yyb771 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj771-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym776 := z.EncBinary() - _ = yym776 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep777 := !z.EncBinary() - yy2arr777 := z.EncBasicHandle().StructToArray - var yyq777 [5]bool - _, _, _ = yysep777, yyq777, yy2arr777 - const yyr777 bool = false - yyq777[2] = x.ReadOnly != false - yyq777[3] = x.User != "" - yyq777[4] = x.Group != "" - var yynn777 int - if yyr777 || yy2arr777 { - r.EncodeArrayStart(5) - } else { - yynn777 = 2 - for _, b := range yyq777 { - if b { - yynn777++ - } - } - r.EncodeMapStart(yynn777) - yynn777 = 0 - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym779 := z.EncBinary() - _ = yym779 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Registry)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("registry")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym780 := z.EncBinary() - _ = yym780 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Registry)) - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym782 := z.EncBinary() - _ = yym782 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Volume)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym783 := z.EncBinary() - _ = yym783 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Volume)) - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq777[2] { - yym785 := z.EncBinary() - _ = yym785 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq777[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym786 := z.EncBinary() - _ = yym786 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq777[3] { - yym788 := z.EncBinary() - _ = yym788 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq777[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym789 := z.EncBinary() - _ = yym789 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq777[4] { - yym791 := z.EncBinary() - _ = yym791 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq777[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("group")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym792 := z.EncBinary() - _ = yym792 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *QuobyteVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym793 := z.DecBinary() - _ = yym793 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct794 := r.ContainerType() - if yyct794 == codecSelferValueTypeMap1234 { - yyl794 := r.ReadMapStart() - if yyl794 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl794, d) - } - } else if yyct794 == codecSelferValueTypeArray1234 { - yyl794 := r.ReadArrayStart() - if yyl794 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl794, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *QuobyteVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys795Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys795Slc - var yyhl795 bool = l >= 0 - for yyj795 := 0; ; yyj795++ { - if yyhl795 { - if yyj795 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys795Slc = r.DecodeBytes(yys795Slc, true, true) - yys795 := string(yys795Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys795 { - case "registry": - if r.TryDecodeAsNil() { - x.Registry = "" - } else { - x.Registry = string(r.DecodeString()) - } - case "volume": - if r.TryDecodeAsNil() { - x.Volume = "" - } else { - x.Volume = string(r.DecodeString()) - } - case "readOnly": - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - case "user": - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - case "group": - if r.TryDecodeAsNil() { - x.Group = "" - } else { - x.Group = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys795) - } // end switch yys795 - } // end for yyj795 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj801 int - var yyb801 bool - var yyhl801 bool = l >= 0 - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Registry = "" - } else { - x.Registry = string(r.DecodeString()) - } - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Volume = "" - } else { - x.Volume = string(r.DecodeString()) - } - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Group = "" - } else { - x.Group = string(r.DecodeString()) - } - for { - yyj801++ - if yyhl801 { - yyb801 = yyj801 > l - } else { - yyb801 = r.CheckBreak() - } - if yyb801 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj801-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 { - yym807 := z.EncBinary() - _ = yym807 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep808 := !z.EncBinary() - yy2arr808 := z.EncBasicHandle().StructToArray - var yyq808 [5]bool - _, _, _ = yysep808, yyq808, yy2arr808 - const yyr808 bool = false - yyq808[1] = x.FSType != "" - yyq808[2] = x.SecretRef != nil - yyq808[3] = x.ReadOnly != false - yyq808[4] = len(x.Options) != 0 - var yynn808 int - if yyr808 || yy2arr808 { - r.EncodeArrayStart(5) - } else { - yynn808 = 1 - for _, b := range yyq808 { - if b { - yynn808++ - } - } - r.EncodeMapStart(yynn808) - yynn808 = 0 - } - if yyr808 || yy2arr808 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym810 := z.EncBinary() - _ = yym810 - 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) - yym811 := z.EncBinary() - _ = yym811 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Driver)) - } - } - if yyr808 || yy2arr808 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq808[1] { - yym813 := z.EncBinary() - _ = yym813 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq808[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym814 := z.EncBinary() - _ = yym814 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr808 || yy2arr808 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq808[2] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq808[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 yyr808 || yy2arr808 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq808[3] { - yym817 := z.EncBinary() - _ = yym817 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq808[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym818 := z.EncBinary() - _ = yym818 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr808 || yy2arr808 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq808[4] { - if x.Options == nil { - r.EncodeNil() - } else { - yym820 := z.EncBinary() - _ = yym820 - if false { - } else { - z.F.EncMapStringStringV(x.Options, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq808[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("options")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Options == nil { - r.EncodeNil() - } else { - yym821 := z.EncBinary() - _ = yym821 - if false { - } else { - z.F.EncMapStringStringV(x.Options, false, e) - } - } - } - } - if yyr808 || yy2arr808 { - 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 - yym822 := z.DecBinary() - _ = yym822 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct823 := r.ContainerType() - if yyct823 == codecSelferValueTypeMap1234 { - yyl823 := r.ReadMapStart() - if yyl823 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl823, d) - } - } else if yyct823 == codecSelferValueTypeArray1234 { - yyl823 := r.ReadArrayStart() - if yyl823 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl823, 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 yys824Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys824Slc - var yyhl824 bool = l >= 0 - for yyj824 := 0; ; yyj824++ { - if yyhl824 { - if yyj824 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys824Slc = r.DecodeBytes(yys824Slc, true, true) - yys824 := string(yys824Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys824 { - 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 { - yyv829 := &x.Options - yym830 := z.DecBinary() - _ = yym830 - if false { - } else { - z.F.DecMapStringStringX(yyv829, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys824) - } // end switch yys824 - } // end for yyj824 - 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 yyj831 int - var yyb831 bool - var yyhl831 bool = l >= 0 - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Driver = "" - } else { - x.Driver = string(r.DecodeString()) - } - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - 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) - } - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Options = nil - } else { - yyv836 := &x.Options - yym837 := z.DecBinary() - _ = yym837 - if false { - } else { - z.F.DecMapStringStringX(yyv836, false, d) - } - } - for { - yyj831++ - if yyhl831 { - yyb831 = yyj831 > l - } else { - yyb831 = r.CheckBreak() - } - if yyb831 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj831-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 { - yym838 := z.EncBinary() - _ = yym838 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep839 := !z.EncBinary() - yy2arr839 := z.EncBasicHandle().StructToArray - var yyq839 [4]bool - _, _, _ = yysep839, yyq839, yy2arr839 - const yyr839 bool = false - yyq839[1] = x.FSType != "" - yyq839[2] = x.Partition != 0 - yyq839[3] = x.ReadOnly != false - var yynn839 int - if yyr839 || yy2arr839 { - r.EncodeArrayStart(4) - } else { - yynn839 = 1 - for _, b := range yyq839 { - if b { - yynn839++ - } - } - r.EncodeMapStart(yynn839) - yynn839 = 0 - } - if yyr839 || yy2arr839 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym841 := z.EncBinary() - _ = yym841 - 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) - yym842 := z.EncBinary() - _ = yym842 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) - } - } - if yyr839 || yy2arr839 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq839[1] { - yym844 := z.EncBinary() - _ = yym844 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq839[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym845 := z.EncBinary() - _ = yym845 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr839 || yy2arr839 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq839[2] { - yym847 := z.EncBinary() - _ = yym847 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq839[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("partition")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym848 := z.EncBinary() - _ = yym848 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } - } - if yyr839 || yy2arr839 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq839[3] { - yym850 := z.EncBinary() - _ = yym850 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq839[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym851 := z.EncBinary() - _ = yym851 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr839 || yy2arr839 { - 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 - yym852 := z.DecBinary() - _ = yym852 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct853 := r.ContainerType() - if yyct853 == codecSelferValueTypeMap1234 { - yyl853 := r.ReadMapStart() - if yyl853 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl853, d) - } - } else if yyct853 == codecSelferValueTypeArray1234 { - yyl853 := r.ReadArrayStart() - if yyl853 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl853, 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 yys854Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys854Slc - var yyhl854 bool = l >= 0 - for yyj854 := 0; ; yyj854++ { - if yyhl854 { - if yyj854 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys854Slc = r.DecodeBytes(yys854Slc, true, true) - yys854 := string(yys854Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys854 { - 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, yys854) - } // end switch yys854 - } // end for yyj854 - 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 yyj859 int - var yyb859 bool - var yyhl859 bool = l >= 0 - yyj859++ - if yyhl859 { - yyb859 = yyj859 > l - } else { - yyb859 = r.CheckBreak() - } - if yyb859 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeID = "" - } else { - x.VolumeID = string(r.DecodeString()) - } - yyj859++ - if yyhl859 { - yyb859 = yyj859 > l - } else { - yyb859 = r.CheckBreak() - } - if yyb859 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj859++ - if yyhl859 { - yyb859 = yyj859 > l - } else { - yyb859 = r.CheckBreak() - } - if yyb859 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Partition = 0 - } else { - x.Partition = int32(r.DecodeInt(32)) - } - yyj859++ - if yyhl859 { - yyb859 = yyj859 > l - } else { - yyb859 = r.CheckBreak() - } - if yyb859 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj859++ - if yyhl859 { - yyb859 = yyj859 > l - } else { - yyb859 = r.CheckBreak() - } - if yyb859 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj859-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 { - yym864 := z.EncBinary() - _ = yym864 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep865 := !z.EncBinary() - yy2arr865 := z.EncBasicHandle().StructToArray - var yyq865 [3]bool - _, _, _ = yysep865, yyq865, yy2arr865 - const yyr865 bool = false - yyq865[1] = x.Revision != "" - yyq865[2] = x.Directory != "" - var yynn865 int - if yyr865 || yy2arr865 { - r.EncodeArrayStart(3) - } else { - yynn865 = 1 - for _, b := range yyq865 { - if b { - yynn865++ - } - } - r.EncodeMapStart(yynn865) - yynn865 = 0 - } - if yyr865 || yy2arr865 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym867 := z.EncBinary() - _ = yym867 - 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) - yym868 := z.EncBinary() - _ = yym868 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Repository)) - } - } - if yyr865 || yy2arr865 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq865[1] { - yym870 := z.EncBinary() - _ = yym870 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq865[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revision")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym871 := z.EncBinary() - _ = yym871 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) - } - } - } - if yyr865 || yy2arr865 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq865[2] { - yym873 := z.EncBinary() - _ = yym873 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq865[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("directory")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym874 := z.EncBinary() - _ = yym874 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) - } - } - } - if yyr865 || yy2arr865 { - 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 - yym875 := z.DecBinary() - _ = yym875 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct876 := r.ContainerType() - if yyct876 == codecSelferValueTypeMap1234 { - yyl876 := r.ReadMapStart() - if yyl876 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl876, d) - } - } else if yyct876 == codecSelferValueTypeArray1234 { - yyl876 := r.ReadArrayStart() - if yyl876 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl876, 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 yys877Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys877Slc - var yyhl877 bool = l >= 0 - for yyj877 := 0; ; yyj877++ { - if yyhl877 { - if yyj877 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys877Slc = r.DecodeBytes(yys877Slc, true, true) - yys877 := string(yys877Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys877 { - 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, yys877) - } // end switch yys877 - } // end for yyj877 - 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 yyj881 int - var yyb881 bool - var yyhl881 bool = l >= 0 - yyj881++ - if yyhl881 { - yyb881 = yyj881 > l - } else { - yyb881 = r.CheckBreak() - } - if yyb881 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Repository = "" - } else { - x.Repository = string(r.DecodeString()) - } - yyj881++ - if yyhl881 { - yyb881 = yyj881 > l - } else { - yyb881 = r.CheckBreak() - } - if yyb881 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Revision = "" - } else { - x.Revision = string(r.DecodeString()) - } - yyj881++ - if yyhl881 { - yyb881 = yyj881 > l - } else { - yyb881 = r.CheckBreak() - } - if yyb881 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Directory = "" - } else { - x.Directory = string(r.DecodeString()) - } - for { - yyj881++ - if yyhl881 { - yyb881 = yyj881 > l - } else { - yyb881 = r.CheckBreak() - } - if yyb881 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj881-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 { - yym885 := z.EncBinary() - _ = yym885 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep886 := !z.EncBinary() - yy2arr886 := z.EncBasicHandle().StructToArray - var yyq886 [3]bool - _, _, _ = yysep886, yyq886, yy2arr886 - const yyr886 bool = false - yyq886[0] = x.SecretName != "" - yyq886[1] = len(x.Items) != 0 - yyq886[2] = x.DefaultMode != nil - var yynn886 int - if yyr886 || yy2arr886 { - r.EncodeArrayStart(3) - } else { - yynn886 = 0 - for _, b := range yyq886 { - if b { - yynn886++ - } - } - r.EncodeMapStart(yynn886) - yynn886 = 0 - } - if yyr886 || yy2arr886 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq886[0] { - yym888 := z.EncBinary() - _ = yym888 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq886[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym889 := z.EncBinary() - _ = yym889 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } - } - if yyr886 || yy2arr886 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq886[1] { - if x.Items == nil { - r.EncodeNil() - } else { - yym891 := z.EncBinary() - _ = yym891 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq886[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym892 := z.EncBinary() - _ = yym892 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } - } - if yyr886 || yy2arr886 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq886[2] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy894 := *x.DefaultMode - yym895 := z.EncBinary() - _ = yym895 - if false { - } else { - r.EncodeInt(int64(yy894)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq886[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy896 := *x.DefaultMode - yym897 := z.EncBinary() - _ = yym897 - if false { - } else { - r.EncodeInt(int64(yy896)) - } - } - } - } - if yyr886 || yy2arr886 { - 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 - yym898 := z.DecBinary() - _ = yym898 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct899 := r.ContainerType() - if yyct899 == codecSelferValueTypeMap1234 { - yyl899 := r.ReadMapStart() - if yyl899 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl899, d) - } - } else if yyct899 == codecSelferValueTypeArray1234 { - yyl899 := r.ReadArrayStart() - if yyl899 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl899, 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 yys900Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys900Slc - var yyhl900 bool = l >= 0 - for yyj900 := 0; ; yyj900++ { - if yyhl900 { - if yyj900 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys900Slc = r.DecodeBytes(yys900Slc, true, true) - yys900 := string(yys900Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys900 { - case "secretName": - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv902 := &x.Items - yym903 := z.DecBinary() - _ = yym903 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv902), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym905 := z.DecBinary() - _ = yym905 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys900) - } // end switch yys900 - } // end for yyj900 - 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 yyj906 int - var yyb906 bool - var yyhl906 bool = l >= 0 - yyj906++ - if yyhl906 { - yyb906 = yyj906 > l - } else { - yyb906 = r.CheckBreak() - } - if yyb906 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - yyj906++ - if yyhl906 { - yyb906 = yyj906 > l - } else { - yyb906 = r.CheckBreak() - } - if yyb906 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv908 := &x.Items - yym909 := z.DecBinary() - _ = yym909 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv908), d) - } - } - yyj906++ - if yyhl906 { - yyb906 = yyj906 > l - } else { - yyb906 = r.CheckBreak() - } - if yyb906 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym911 := z.DecBinary() - _ = yym911 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj906++ - if yyhl906 { - yyb906 = yyj906 > l - } else { - yyb906 = r.CheckBreak() - } - if yyb906 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj906-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 { - yym912 := z.EncBinary() - _ = yym912 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep913 := !z.EncBinary() - yy2arr913 := z.EncBasicHandle().StructToArray - var yyq913 [3]bool - _, _, _ = yysep913, yyq913, yy2arr913 - const yyr913 bool = false - yyq913[2] = x.ReadOnly != false - var yynn913 int - if yyr913 || yy2arr913 { - r.EncodeArrayStart(3) - } else { - yynn913 = 2 - for _, b := range yyq913 { - if b { - yynn913++ - } - } - r.EncodeMapStart(yynn913) - yynn913 = 0 - } - if yyr913 || yy2arr913 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym915 := z.EncBinary() - _ = yym915 - 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) - yym916 := z.EncBinary() - _ = yym916 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Server)) - } - } - if yyr913 || yy2arr913 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym918 := z.EncBinary() - _ = yym918 - 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) - yym919 := z.EncBinary() - _ = yym919 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr913 || yy2arr913 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq913[2] { - yym921 := z.EncBinary() - _ = yym921 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq913[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym922 := z.EncBinary() - _ = yym922 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr913 || yy2arr913 { - 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 - yym923 := z.DecBinary() - _ = yym923 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct924 := r.ContainerType() - if yyct924 == codecSelferValueTypeMap1234 { - yyl924 := r.ReadMapStart() - if yyl924 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl924, d) - } - } else if yyct924 == codecSelferValueTypeArray1234 { - yyl924 := r.ReadArrayStart() - if yyl924 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl924, 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 yys925Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys925Slc - var yyhl925 bool = l >= 0 - for yyj925 := 0; ; yyj925++ { - if yyhl925 { - if yyj925 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys925Slc = r.DecodeBytes(yys925Slc, true, true) - yys925 := string(yys925Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys925 { - 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, yys925) - } // end switch yys925 - } // end for yyj925 - 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 yyj929 int - var yyb929 bool - var yyhl929 bool = l >= 0 - yyj929++ - if yyhl929 { - yyb929 = yyj929 > l - } else { - yyb929 = r.CheckBreak() - } - if yyb929 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Server = "" - } else { - x.Server = string(r.DecodeString()) - } - yyj929++ - if yyhl929 { - yyb929 = yyj929 > l - } else { - yyb929 = r.CheckBreak() - } - if yyb929 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj929++ - if yyhl929 { - yyb929 = yyj929 > l - } else { - yyb929 = r.CheckBreak() - } - if yyb929 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj929++ - if yyhl929 { - yyb929 = yyj929 > l - } else { - yyb929 = r.CheckBreak() - } - if yyb929 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj929-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 { - yym933 := z.EncBinary() - _ = yym933 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep934 := !z.EncBinary() - yy2arr934 := z.EncBasicHandle().StructToArray - var yyq934 [6]bool - _, _, _ = yysep934, yyq934, yy2arr934 - const yyr934 bool = false - yyq934[3] = x.ISCSIInterface != "" - yyq934[4] = x.FSType != "" - yyq934[5] = x.ReadOnly != false - var yynn934 int - if yyr934 || yy2arr934 { - r.EncodeArrayStart(6) - } else { - yynn934 = 3 - for _, b := range yyq934 { - if b { - yynn934++ - } - } - r.EncodeMapStart(yynn934) - yynn934 = 0 - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym936 := z.EncBinary() - _ = yym936 - 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) - yym937 := z.EncBinary() - _ = yym937 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) - } - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym939 := z.EncBinary() - _ = yym939 - 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) - yym940 := z.EncBinary() - _ = yym940 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) - } - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym942 := z.EncBinary() - _ = yym942 - if false { - } else { - r.EncodeInt(int64(x.Lun)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lun")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym943 := z.EncBinary() - _ = yym943 - if false { - } else { - r.EncodeInt(int64(x.Lun)) - } - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq934[3] { - yym945 := z.EncBinary() - _ = yym945 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq934[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsiInterface")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym946 := z.EncBinary() - _ = yym946 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq934[4] { - yym948 := z.EncBinary() - _ = yym948 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq934[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym949 := z.EncBinary() - _ = yym949 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr934 || yy2arr934 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq934[5] { - yym951 := z.EncBinary() - _ = yym951 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq934[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym952 := z.EncBinary() - _ = yym952 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr934 || yy2arr934 { - 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 - yym953 := z.DecBinary() - _ = yym953 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct954 := r.ContainerType() - if yyct954 == codecSelferValueTypeMap1234 { - yyl954 := r.ReadMapStart() - if yyl954 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl954, d) - } - } else if yyct954 == codecSelferValueTypeArray1234 { - yyl954 := r.ReadArrayStart() - if yyl954 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl954, 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 yys955Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys955Slc - var yyhl955 bool = l >= 0 - for yyj955 := 0; ; yyj955++ { - if yyhl955 { - if yyj955 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys955Slc = r.DecodeBytes(yys955Slc, true, true) - yys955 := string(yys955Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys955 { - 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, yys955) - } // end switch yys955 - } // end for yyj955 - 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 yyj962 int - var yyb962 bool - var yyhl962 bool = l >= 0 - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetPortal = "" - } else { - x.TargetPortal = string(r.DecodeString()) - } - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IQN = "" - } else { - x.IQN = string(r.DecodeString()) - } - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Lun = 0 - } else { - x.Lun = int32(r.DecodeInt(32)) - } - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ISCSIInterface = "" - } else { - x.ISCSIInterface = string(r.DecodeString()) - } - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj962++ - if yyhl962 { - yyb962 = yyj962 > l - } else { - yyb962 = r.CheckBreak() - } - if yyb962 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj962-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 { - yym969 := z.EncBinary() - _ = yym969 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep970 := !z.EncBinary() - yy2arr970 := z.EncBasicHandle().StructToArray - var yyq970 [4]bool - _, _, _ = yysep970, yyq970, yy2arr970 - const yyr970 bool = false - yyq970[2] = x.FSType != "" - yyq970[3] = x.ReadOnly != false - var yynn970 int - if yyr970 || yy2arr970 { - r.EncodeArrayStart(4) - } else { - yynn970 = 2 - for _, b := range yyq970 { - if b { - yynn970++ - } - } - r.EncodeMapStart(yynn970) - yynn970 = 0 - } - if yyr970 || yy2arr970 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.TargetWWNs == nil { - r.EncodeNil() - } else { - yym972 := z.EncBinary() - _ = yym972 - 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 { - yym973 := z.EncBinary() - _ = yym973 - if false { - } else { - z.F.EncSliceStringV(x.TargetWWNs, false, e) - } - } - } - if yyr970 || yy2arr970 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Lun == nil { - r.EncodeNil() - } else { - yy975 := *x.Lun - yym976 := z.EncBinary() - _ = yym976 - if false { - } else { - r.EncodeInt(int64(yy975)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lun")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Lun == nil { - r.EncodeNil() - } else { - yy977 := *x.Lun - yym978 := z.EncBinary() - _ = yym978 - if false { - } else { - r.EncodeInt(int64(yy977)) - } - } - } - if yyr970 || yy2arr970 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq970[2] { - yym980 := z.EncBinary() - _ = yym980 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq970[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym981 := z.EncBinary() - _ = yym981 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr970 || yy2arr970 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq970[3] { - yym983 := z.EncBinary() - _ = yym983 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq970[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym984 := z.EncBinary() - _ = yym984 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr970 || yy2arr970 { - 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 - yym985 := z.DecBinary() - _ = yym985 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct986 := r.ContainerType() - if yyct986 == codecSelferValueTypeMap1234 { - yyl986 := r.ReadMapStart() - if yyl986 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl986, d) - } - } else if yyct986 == codecSelferValueTypeArray1234 { - yyl986 := r.ReadArrayStart() - if yyl986 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl986, 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 yys987Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys987Slc - var yyhl987 bool = l >= 0 - for yyj987 := 0; ; yyj987++ { - if yyhl987 { - if yyj987 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys987Slc = r.DecodeBytes(yys987Slc, true, true) - yys987 := string(yys987Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys987 { - case "targetWWNs": - if r.TryDecodeAsNil() { - x.TargetWWNs = nil - } else { - yyv988 := &x.TargetWWNs - yym989 := z.DecBinary() - _ = yym989 - if false { - } else { - z.F.DecSliceStringX(yyv988, false, d) - } - } - case "lun": - if r.TryDecodeAsNil() { - if x.Lun != nil { - x.Lun = nil - } - } else { - if x.Lun == nil { - x.Lun = new(int32) - } - yym991 := z.DecBinary() - _ = yym991 - 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, yys987) - } // end switch yys987 - } // end for yyj987 - 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 yyj994 int - var yyb994 bool - var yyhl994 bool = l >= 0 - yyj994++ - if yyhl994 { - yyb994 = yyj994 > l - } else { - yyb994 = r.CheckBreak() - } - if yyb994 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetWWNs = nil - } else { - yyv995 := &x.TargetWWNs - yym996 := z.DecBinary() - _ = yym996 - if false { - } else { - z.F.DecSliceStringX(yyv995, false, d) - } - } - yyj994++ - if yyhl994 { - yyb994 = yyj994 > l - } else { - yyb994 = r.CheckBreak() - } - if yyb994 { - 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) - } - yym998 := z.DecBinary() - _ = yym998 - if false { - } else { - *((*int32)(x.Lun)) = int32(r.DecodeInt(32)) - } - } - yyj994++ - if yyhl994 { - yyb994 = yyj994 > l - } else { - yyb994 = r.CheckBreak() - } - if yyb994 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj994++ - if yyhl994 { - yyb994 = yyj994 > l - } else { - yyb994 = r.CheckBreak() - } - if yyb994 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj994++ - if yyhl994 { - yyb994 = yyj994 > l - } else { - yyb994 = r.CheckBreak() - } - if yyb994 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj994-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 { - yym1001 := z.EncBinary() - _ = yym1001 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1002 := !z.EncBinary() - yy2arr1002 := z.EncBasicHandle().StructToArray - var yyq1002 [3]bool - _, _, _ = yysep1002, yyq1002, yy2arr1002 - const yyr1002 bool = false - yyq1002[2] = x.ReadOnly != false - var yynn1002 int - if yyr1002 || yy2arr1002 { - r.EncodeArrayStart(3) - } else { - yynn1002 = 2 - for _, b := range yyq1002 { - if b { - yynn1002++ - } - } - r.EncodeMapStart(yynn1002) - yynn1002 = 0 - } - if yyr1002 || yy2arr1002 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1004 := z.EncBinary() - _ = yym1004 - 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) - yym1005 := z.EncBinary() - _ = yym1005 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } - if yyr1002 || yy2arr1002 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1007 := z.EncBinary() - _ = yym1007 - 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) - yym1008 := z.EncBinary() - _ = yym1008 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) - } - } - if yyr1002 || yy2arr1002 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1002[2] { - yym1010 := z.EncBinary() - _ = yym1010 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1002[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1011 := z.EncBinary() - _ = yym1011 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr1002 || yy2arr1002 { - 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 - yym1012 := z.DecBinary() - _ = yym1012 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1013 := r.ContainerType() - if yyct1013 == codecSelferValueTypeMap1234 { - yyl1013 := r.ReadMapStart() - if yyl1013 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1013, d) - } - } else if yyct1013 == codecSelferValueTypeArray1234 { - yyl1013 := r.ReadArrayStart() - if yyl1013 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1013, 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 yys1014Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1014Slc - var yyhl1014 bool = l >= 0 - for yyj1014 := 0; ; yyj1014++ { - if yyhl1014 { - if yyj1014 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1014Slc = r.DecodeBytes(yys1014Slc, true, true) - yys1014 := string(yys1014Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1014 { - 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, yys1014) - } // end switch yys1014 - } // end for yyj1014 - 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 yyj1018 int - var yyb1018 bool - var yyhl1018 bool = l >= 0 - yyj1018++ - if yyhl1018 { - yyb1018 = yyj1018 > l - } else { - yyb1018 = r.CheckBreak() - } - if yyb1018 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - yyj1018++ - if yyhl1018 { - yyb1018 = yyj1018 > l - } else { - yyb1018 = r.CheckBreak() - } - if yyb1018 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ShareName = "" - } else { - x.ShareName = string(r.DecodeString()) - } - yyj1018++ - if yyhl1018 { - yyb1018 = yyj1018 > l - } else { - yyb1018 = r.CheckBreak() - } - if yyb1018 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj1018++ - if yyhl1018 { - yyb1018 = yyj1018 > l - } else { - yyb1018 = r.CheckBreak() - } - if yyb1018 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1018-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 { - yym1022 := z.EncBinary() - _ = yym1022 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1023 := !z.EncBinary() - yy2arr1023 := z.EncBasicHandle().StructToArray - var yyq1023 [2]bool - _, _, _ = yysep1023, yyq1023, yy2arr1023 - const yyr1023 bool = false - yyq1023[1] = x.FSType != "" - var yynn1023 int - if yyr1023 || yy2arr1023 { - r.EncodeArrayStart(2) - } else { - yynn1023 = 1 - for _, b := range yyq1023 { - if b { - yynn1023++ - } - } - r.EncodeMapStart(yynn1023) - yynn1023 = 0 - } - if yyr1023 || yy2arr1023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1025 := z.EncBinary() - _ = yym1025 - 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) - yym1026 := z.EncBinary() - _ = yym1026 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) - } - } - if yyr1023 || yy2arr1023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1023[1] { - yym1028 := z.EncBinary() - _ = yym1028 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1023[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1029 := z.EncBinary() - _ = yym1029 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr1023 || yy2arr1023 { - 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 - yym1030 := z.DecBinary() - _ = yym1030 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1031 := r.ContainerType() - if yyct1031 == codecSelferValueTypeMap1234 { - yyl1031 := r.ReadMapStart() - if yyl1031 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1031, d) - } - } else if yyct1031 == codecSelferValueTypeArray1234 { - yyl1031 := r.ReadArrayStart() - if yyl1031 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1031, 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 yys1032Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1032Slc - var yyhl1032 bool = l >= 0 - for yyj1032 := 0; ; yyj1032++ { - if yyhl1032 { - if yyj1032 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1032Slc = r.DecodeBytes(yys1032Slc, true, true) - yys1032 := string(yys1032Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1032 { - 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, yys1032) - } // end switch yys1032 - } // end for yyj1032 - 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 yyj1035 int - var yyb1035 bool - var yyhl1035 bool = l >= 0 - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l - } else { - yyb1035 = r.CheckBreak() - } - if yyb1035 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumePath = "" - } else { - x.VolumePath = string(r.DecodeString()) - } - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l - } else { - yyb1035 = r.CheckBreak() - } - if yyb1035 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - for { - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l - } else { - yyb1035 = r.CheckBreak() - } - if yyb1035 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1035-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x AzureDataDiskCachingMode) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1038 := z.EncBinary() - _ = yym1038 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *AzureDataDiskCachingMode) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1039 := z.DecBinary() - _ = yym1039 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *AzureDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1040 := z.EncBinary() - _ = yym1040 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1041 := !z.EncBinary() - yy2arr1041 := z.EncBasicHandle().StructToArray - var yyq1041 [5]bool - _, _, _ = yysep1041, yyq1041, yy2arr1041 - const yyr1041 bool = false - yyq1041[2] = x.CachingMode != nil - yyq1041[3] = x.FSType != nil - yyq1041[4] = x.ReadOnly != nil - var yynn1041 int - if yyr1041 || yy2arr1041 { - r.EncodeArrayStart(5) - } else { - yynn1041 = 2 - for _, b := range yyq1041 { - if b { - yynn1041++ - } - } - r.EncodeMapStart(yynn1041) - yynn1041 = 0 - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1043 := z.EncBinary() - _ = yym1043 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DiskName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("diskName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1044 := z.EncBinary() - _ = yym1044 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DiskName)) - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1046 := z.EncBinary() - _ = yym1046 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("diskURI")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1047 := z.EncBinary() - _ = yym1047 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[2] { - if x.CachingMode == nil { - r.EncodeNil() - } else { - yy1049 := *x.CachingMode - yy1049.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cachingMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CachingMode == nil { - r.EncodeNil() - } else { - yy1050 := *x.CachingMode - yy1050.CodecEncodeSelf(e) - } - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[3] { - if x.FSType == nil { - r.EncodeNil() - } else { - yy1052 := *x.FSType - yym1053 := z.EncBinary() - _ = yym1053 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1052)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FSType == nil { - r.EncodeNil() - } else { - yy1054 := *x.FSType - yym1055 := z.EncBinary() - _ = yym1055 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1054)) - } - } - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[4] { - if x.ReadOnly == nil { - r.EncodeNil() - } else { - yy1057 := *x.ReadOnly - yym1058 := z.EncBinary() - _ = yym1058 - if false { - } else { - r.EncodeBool(bool(yy1057)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ReadOnly == nil { - r.EncodeNil() - } else { - yy1059 := *x.ReadOnly - yym1060 := z.EncBinary() - _ = yym1060 - if false { - } else { - r.EncodeBool(bool(yy1059)) - } - } - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *AzureDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1061 := z.DecBinary() - _ = yym1061 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1062 := r.ContainerType() - if yyct1062 == codecSelferValueTypeMap1234 { - yyl1062 := r.ReadMapStart() - if yyl1062 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1062, d) - } - } else if yyct1062 == codecSelferValueTypeArray1234 { - yyl1062 := r.ReadArrayStart() - if yyl1062 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1062, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *AzureDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1063Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1063Slc - var yyhl1063 bool = l >= 0 - for yyj1063 := 0; ; yyj1063++ { - if yyhl1063 { - if yyj1063 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1063Slc = r.DecodeBytes(yys1063Slc, true, true) - yys1063 := string(yys1063Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1063 { - case "diskName": - if r.TryDecodeAsNil() { - x.DiskName = "" - } else { - x.DiskName = string(r.DecodeString()) - } - case "diskURI": - if r.TryDecodeAsNil() { - x.DataDiskURI = "" - } else { - x.DataDiskURI = string(r.DecodeString()) - } - case "cachingMode": - if r.TryDecodeAsNil() { - if x.CachingMode != nil { - x.CachingMode = nil - } - } else { - if x.CachingMode == nil { - x.CachingMode = new(AzureDataDiskCachingMode) - } - x.CachingMode.CodecDecodeSelf(d) - } - case "fsType": - if r.TryDecodeAsNil() { - if x.FSType != nil { - x.FSType = nil - } - } else { - if x.FSType == nil { - x.FSType = new(string) - } - yym1068 := z.DecBinary() - _ = yym1068 - if false { - } else { - *((*string)(x.FSType)) = r.DecodeString() - } - } - case "readOnly": - if r.TryDecodeAsNil() { - if x.ReadOnly != nil { - x.ReadOnly = nil - } - } else { - if x.ReadOnly == nil { - x.ReadOnly = new(bool) - } - yym1070 := z.DecBinary() - _ = yym1070 - if false { - } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys1063) - } // end switch yys1063 - } // end for yyj1063 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *AzureDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1071 int - var yyb1071 bool - var yyhl1071 bool = l >= 0 - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DiskName = "" - } else { - x.DiskName = string(r.DecodeString()) - } - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DataDiskURI = "" - } else { - x.DataDiskURI = string(r.DecodeString()) - } - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.CachingMode != nil { - x.CachingMode = nil - } - } else { - if x.CachingMode == nil { - x.CachingMode = new(AzureDataDiskCachingMode) - } - x.CachingMode.CodecDecodeSelf(d) - } - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.FSType != nil { - x.FSType = nil - } - } else { - if x.FSType == nil { - x.FSType = new(string) - } - yym1076 := z.DecBinary() - _ = yym1076 - if false { - } else { - *((*string)(x.FSType)) = r.DecodeString() - } - } - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ReadOnly != nil { - x.ReadOnly = nil - } - } else { - if x.ReadOnly == nil { - x.ReadOnly = new(bool) - } - yym1078 := z.DecBinary() - _ = yym1078 - if false { - } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() - } - } - for { - yyj1071++ - if yyhl1071 { - yyb1071 = yyj1071 > l - } else { - yyb1071 = r.CheckBreak() - } - if yyb1071 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1071-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 { - yym1079 := z.EncBinary() - _ = yym1079 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1080 := !z.EncBinary() - yy2arr1080 := z.EncBasicHandle().StructToArray - var yyq1080 [3]bool - _, _, _ = yysep1080, yyq1080, yy2arr1080 - const yyr1080 bool = false - yyq1080[0] = x.Name != "" - yyq1080[1] = len(x.Items) != 0 - yyq1080[2] = x.DefaultMode != nil - var yynn1080 int - if yyr1080 || yy2arr1080 { - r.EncodeArrayStart(3) - } else { - yynn1080 = 0 - for _, b := range yyq1080 { - if b { - yynn1080++ - } - } - r.EncodeMapStart(yynn1080) - yynn1080 = 0 - } - if yyr1080 || yy2arr1080 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1080[0] { - yym1082 := z.EncBinary() - _ = yym1082 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1080[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1083 := z.EncBinary() - _ = yym1083 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr1080 || yy2arr1080 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1080[1] { - if x.Items == nil { - r.EncodeNil() - } else { - yym1085 := z.EncBinary() - _ = yym1085 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1080[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1086 := z.EncBinary() - _ = yym1086 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } - } - if yyr1080 || yy2arr1080 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1080[2] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1088 := *x.DefaultMode - yym1089 := z.EncBinary() - _ = yym1089 - if false { - } else { - r.EncodeInt(int64(yy1088)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1080[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1090 := *x.DefaultMode - yym1091 := z.EncBinary() - _ = yym1091 - if false { - } else { - r.EncodeInt(int64(yy1090)) - } - } - } - } - if yyr1080 || yy2arr1080 { - 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 - yym1092 := z.DecBinary() - _ = yym1092 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1093 := r.ContainerType() - if yyct1093 == codecSelferValueTypeMap1234 { - yyl1093 := r.ReadMapStart() - if yyl1093 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1093, d) - } - } else if yyct1093 == codecSelferValueTypeArray1234 { - yyl1093 := r.ReadArrayStart() - if yyl1093 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1093, 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 yys1094Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1094Slc - var yyhl1094 bool = l >= 0 - for yyj1094 := 0; ; yyj1094++ { - if yyhl1094 { - if yyj1094 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1094Slc = r.DecodeBytes(yys1094Slc, true, true) - yys1094 := string(yys1094Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1094 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1096 := &x.Items - yym1097 := z.DecBinary() - _ = yym1097 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1096), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym1099 := z.DecBinary() - _ = yym1099 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1094) - } // end switch yys1094 - } // end for yyj1094 - 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 yyj1100 int - var yyb1100 bool - var yyhl1100 bool = l >= 0 - yyj1100++ - if yyhl1100 { - yyb1100 = yyj1100 > l - } else { - yyb1100 = r.CheckBreak() - } - if yyb1100 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1100++ - if yyhl1100 { - yyb1100 = yyj1100 > l - } else { - yyb1100 = r.CheckBreak() - } - if yyb1100 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1102 := &x.Items - yym1103 := z.DecBinary() - _ = yym1103 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1102), d) - } - } - yyj1100++ - if yyhl1100 { - yyb1100 = yyj1100 > l - } else { - yyb1100 = r.CheckBreak() - } - if yyb1100 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym1105 := z.DecBinary() - _ = yym1105 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj1100++ - if yyhl1100 { - yyb1100 = yyj1100 > l - } else { - yyb1100 = r.CheckBreak() - } - if yyb1100 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1100-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 { - yym1106 := z.EncBinary() - _ = yym1106 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1107 := !z.EncBinary() - yy2arr1107 := z.EncBasicHandle().StructToArray - var yyq1107 [3]bool - _, _, _ = yysep1107, yyq1107, yy2arr1107 - const yyr1107 bool = false - yyq1107[2] = x.Mode != nil - var yynn1107 int - if yyr1107 || yy2arr1107 { - r.EncodeArrayStart(3) - } else { - yynn1107 = 2 - for _, b := range yyq1107 { - if b { - yynn1107++ - } - } - r.EncodeMapStart(yynn1107) - yynn1107 = 0 - } - if yyr1107 || yy2arr1107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1109 := z.EncBinary() - _ = yym1109 - 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) - yym1110 := z.EncBinary() - _ = yym1110 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1107 || yy2arr1107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1112 := z.EncBinary() - _ = yym1112 - 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) - yym1113 := z.EncBinary() - _ = yym1113 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr1107 || yy2arr1107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1107[2] { - if x.Mode == nil { - r.EncodeNil() - } else { - yy1115 := *x.Mode - yym1116 := z.EncBinary() - _ = yym1116 - if false { - } else { - r.EncodeInt(int64(yy1115)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1107[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Mode == nil { - r.EncodeNil() - } else { - yy1117 := *x.Mode - yym1118 := z.EncBinary() - _ = yym1118 - if false { - } else { - r.EncodeInt(int64(yy1117)) - } - } - } - } - if yyr1107 || yy2arr1107 { - 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 - yym1119 := z.DecBinary() - _ = yym1119 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1120 := r.ContainerType() - if yyct1120 == codecSelferValueTypeMap1234 { - yyl1120 := r.ReadMapStart() - if yyl1120 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1120, d) - } - } else if yyct1120 == codecSelferValueTypeArray1234 { - yyl1120 := r.ReadArrayStart() - if yyl1120 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1120, 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 yys1121Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1121Slc - var yyhl1121 bool = l >= 0 - for yyj1121 := 0; ; yyj1121++ { - if yyhl1121 { - if yyj1121 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1121Slc = r.DecodeBytes(yys1121Slc, true, true) - yys1121 := string(yys1121Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1121 { - 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()) - } - case "mode": - if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } - } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym1125 := z.DecBinary() - _ = yym1125 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1121) - } // end switch yys1121 - } // end for yyj1121 - 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 yyj1126 int - var yyb1126 bool - var yyhl1126 bool = l >= 0 - yyj1126++ - if yyhl1126 { - yyb1126 = yyj1126 > l - } else { - yyb1126 = r.CheckBreak() - } - if yyb1126 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1126++ - if yyhl1126 { - yyb1126 = yyj1126 > l - } else { - yyb1126 = r.CheckBreak() - } - if yyb1126 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj1126++ - if yyhl1126 { - yyb1126 = yyj1126 > l - } else { - yyb1126 = r.CheckBreak() - } - if yyb1126 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } - } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym1130 := z.DecBinary() - _ = yym1130 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj1126++ - if yyhl1126 { - yyb1126 = yyj1126 > l - } else { - yyb1126 = r.CheckBreak() - } - if yyb1126 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1126-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 { - yym1131 := z.EncBinary() - _ = yym1131 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1132 := !z.EncBinary() - yy2arr1132 := z.EncBasicHandle().StructToArray - var yyq1132 [5]bool - _, _, _ = yysep1132, yyq1132, yy2arr1132 - const yyr1132 bool = false - yyq1132[0] = x.Name != "" - yyq1132[1] = x.HostPort != 0 - yyq1132[3] = x.Protocol != "" - yyq1132[4] = x.HostIP != "" - var yynn1132 int - if yyr1132 || yy2arr1132 { - r.EncodeArrayStart(5) - } else { - yynn1132 = 1 - for _, b := range yyq1132 { - if b { - yynn1132++ - } - } - r.EncodeMapStart(yynn1132) - yynn1132 = 0 - } - if yyr1132 || yy2arr1132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1132[0] { - yym1134 := z.EncBinary() - _ = yym1134 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1132[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1135 := z.EncBinary() - _ = yym1135 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr1132 || yy2arr1132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1132[1] { - yym1137 := z.EncBinary() - _ = yym1137 - if false { - } else { - r.EncodeInt(int64(x.HostPort)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1132[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1138 := z.EncBinary() - _ = yym1138 - if false { - } else { - r.EncodeInt(int64(x.HostPort)) - } - } - } - if yyr1132 || yy2arr1132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1140 := z.EncBinary() - _ = yym1140 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1141 := z.EncBinary() - _ = yym1141 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } - if yyr1132 || yy2arr1132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1132[3] { - x.Protocol.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1132[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - } - if yyr1132 || yy2arr1132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1132[4] { - yym1144 := z.EncBinary() - _ = yym1144 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1132[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1145 := z.EncBinary() - _ = yym1145 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } - } - if yyr1132 || yy2arr1132 { - 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 - yym1146 := z.DecBinary() - _ = yym1146 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1147 := r.ContainerType() - if yyct1147 == codecSelferValueTypeMap1234 { - yyl1147 := r.ReadMapStart() - if yyl1147 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1147, d) - } - } else if yyct1147 == codecSelferValueTypeArray1234 { - yyl1147 := r.ReadArrayStart() - if yyl1147 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1147, 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 yys1148Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1148Slc - var yyhl1148 bool = l >= 0 - for yyj1148 := 0; ; yyj1148++ { - if yyhl1148 { - if yyj1148 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1148Slc = r.DecodeBytes(yys1148Slc, true, true) - yys1148 := string(yys1148Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1148 { - 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, yys1148) - } // end switch yys1148 - } // end for yyj1148 - 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 yyj1154 int - var yyb1154 bool - var yyhl1154 bool = l >= 0 - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPort = 0 - } else { - x.HostPort = int32(r.DecodeInt(32)) - } - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerPort = 0 - } else { - x.ContainerPort = int32(r.DecodeInt(32)) - } - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIP = "" - } else { - x.HostIP = string(r.DecodeString()) - } - for { - yyj1154++ - if yyhl1154 { - yyb1154 = yyj1154 > l - } else { - yyb1154 = r.CheckBreak() - } - if yyb1154 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1154-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 { - yym1160 := z.EncBinary() - _ = yym1160 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1161 := !z.EncBinary() - yy2arr1161 := z.EncBasicHandle().StructToArray - var yyq1161 [4]bool - _, _, _ = yysep1161, yyq1161, yy2arr1161 - const yyr1161 bool = false - yyq1161[1] = x.ReadOnly != false - yyq1161[3] = x.SubPath != "" - var yynn1161 int - if yyr1161 || yy2arr1161 { - r.EncodeArrayStart(4) - } else { - yynn1161 = 2 - for _, b := range yyq1161 { - if b { - yynn1161++ - } - } - r.EncodeMapStart(yynn1161) - yynn1161 = 0 - } - if yyr1161 || yy2arr1161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1163 := z.EncBinary() - _ = yym1163 - 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) - yym1164 := z.EncBinary() - _ = yym1164 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1161 || yy2arr1161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1161[1] { - yym1166 := z.EncBinary() - _ = yym1166 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1161[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1167 := z.EncBinary() - _ = yym1167 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr1161 || yy2arr1161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1169 := z.EncBinary() - _ = yym1169 - 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) - yym1170 := z.EncBinary() - _ = yym1170 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) - } - } - if yyr1161 || yy2arr1161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1161[3] { - yym1172 := z.EncBinary() - _ = yym1172 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1161[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1173 := z.EncBinary() - _ = yym1173 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } - } - } - if yyr1161 || yy2arr1161 { - 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 - yym1174 := z.DecBinary() - _ = yym1174 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1175 := r.ContainerType() - if yyct1175 == codecSelferValueTypeMap1234 { - yyl1175 := r.ReadMapStart() - if yyl1175 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1175, d) - } - } else if yyct1175 == codecSelferValueTypeArray1234 { - yyl1175 := r.ReadArrayStart() - if yyl1175 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1175, 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 yys1176Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1176Slc - var yyhl1176 bool = l >= 0 - for yyj1176 := 0; ; yyj1176++ { - if yyhl1176 { - if yyj1176 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1176Slc = r.DecodeBytes(yys1176Slc, true, true) - yys1176 := string(yys1176Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1176 { - 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, yys1176) - } // end switch yys1176 - } // end for yyj1176 - 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 yyj1181 int - var yyb1181 bool - var yyhl1181 bool = l >= 0 - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MountPath = "" - } else { - x.MountPath = string(r.DecodeString()) - } - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SubPath = "" - } else { - x.SubPath = string(r.DecodeString()) - } - for { - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1181-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 { - yym1186 := z.EncBinary() - _ = yym1186 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1187 := !z.EncBinary() - yy2arr1187 := z.EncBasicHandle().StructToArray - var yyq1187 [3]bool - _, _, _ = yysep1187, yyq1187, yy2arr1187 - const yyr1187 bool = false - yyq1187[1] = x.Value != "" - yyq1187[2] = x.ValueFrom != nil - var yynn1187 int - if yyr1187 || yy2arr1187 { - r.EncodeArrayStart(3) - } else { - yynn1187 = 1 - for _, b := range yyq1187 { - if b { - yynn1187++ - } - } - r.EncodeMapStart(yynn1187) - yynn1187 = 0 - } - if yyr1187 || yy2arr1187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1189 := z.EncBinary() - _ = yym1189 - 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) - yym1190 := z.EncBinary() - _ = yym1190 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1187 || yy2arr1187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1187[1] { - yym1192 := z.EncBinary() - _ = yym1192 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1187[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1193 := z.EncBinary() - _ = yym1193 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr1187 || yy2arr1187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1187[2] { - if x.ValueFrom == nil { - r.EncodeNil() - } else { - x.ValueFrom.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1187[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 yyr1187 || yy2arr1187 { - 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 - yym1195 := z.DecBinary() - _ = yym1195 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1196 := r.ContainerType() - if yyct1196 == codecSelferValueTypeMap1234 { - yyl1196 := r.ReadMapStart() - if yyl1196 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1196, d) - } - } else if yyct1196 == codecSelferValueTypeArray1234 { - yyl1196 := r.ReadArrayStart() - if yyl1196 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1196, 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 yys1197Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1197Slc - var yyhl1197 bool = l >= 0 - for yyj1197 := 0; ; yyj1197++ { - if yyhl1197 { - if yyj1197 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1197Slc = r.DecodeBytes(yys1197Slc, true, true) - yys1197 := string(yys1197Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1197 { - 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, yys1197) - } // end switch yys1197 - } // end for yyj1197 - 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 yyj1201 int - var yyb1201 bool - var yyhl1201 bool = l >= 0 - yyj1201++ - if yyhl1201 { - yyb1201 = yyj1201 > l - } else { - yyb1201 = r.CheckBreak() - } - if yyb1201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1201++ - if yyhl1201 { - yyb1201 = yyj1201 > l - } else { - yyb1201 = r.CheckBreak() - } - if yyb1201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj1201++ - if yyhl1201 { - yyb1201 = yyj1201 > l - } else { - yyb1201 = r.CheckBreak() - } - if yyb1201 { - 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 { - yyj1201++ - if yyhl1201 { - yyb1201 = yyj1201 > l - } else { - yyb1201 = r.CheckBreak() - } - if yyb1201 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1201-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 { - yym1205 := z.EncBinary() - _ = yym1205 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1206 := !z.EncBinary() - yy2arr1206 := z.EncBasicHandle().StructToArray - var yyq1206 [4]bool - _, _, _ = yysep1206, yyq1206, yy2arr1206 - const yyr1206 bool = false - yyq1206[0] = x.FieldRef != nil - yyq1206[1] = x.ResourceFieldRef != nil - yyq1206[2] = x.ConfigMapKeyRef != nil - yyq1206[3] = x.SecretKeyRef != nil - var yynn1206 int - if yyr1206 || yy2arr1206 { - r.EncodeArrayStart(4) - } else { - yynn1206 = 0 - for _, b := range yyq1206 { - if b { - yynn1206++ - } - } - r.EncodeMapStart(yynn1206) - yynn1206 = 0 - } - if yyr1206 || yy2arr1206 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1206[0] { - if x.FieldRef == nil { - r.EncodeNil() - } else { - x.FieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1206[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 yyr1206 || yy2arr1206 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1206[1] { - if x.ResourceFieldRef == nil { - r.EncodeNil() - } else { - x.ResourceFieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1206[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 yyr1206 || yy2arr1206 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1206[2] { - if x.ConfigMapKeyRef == nil { - r.EncodeNil() - } else { - x.ConfigMapKeyRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1206[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 yyr1206 || yy2arr1206 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1206[3] { - if x.SecretKeyRef == nil { - r.EncodeNil() - } else { - x.SecretKeyRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1206[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 yyr1206 || yy2arr1206 { - 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 - yym1211 := z.DecBinary() - _ = yym1211 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1212 := r.ContainerType() - if yyct1212 == codecSelferValueTypeMap1234 { - yyl1212 := r.ReadMapStart() - if yyl1212 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1212, d) - } - } else if yyct1212 == codecSelferValueTypeArray1234 { - yyl1212 := r.ReadArrayStart() - if yyl1212 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1212, 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 yys1213Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1213Slc - var yyhl1213 bool = l >= 0 - for yyj1213 := 0; ; yyj1213++ { - if yyhl1213 { - if yyj1213 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1213Slc = r.DecodeBytes(yys1213Slc, true, true) - yys1213 := string(yys1213Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1213 { - 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, yys1213) - } // end switch yys1213 - } // end for yyj1213 - 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 yyj1218 int - var yyb1218 bool - var yyhl1218 bool = l >= 0 - yyj1218++ - if yyhl1218 { - yyb1218 = yyj1218 > l - } else { - yyb1218 = r.CheckBreak() - } - if yyb1218 { - 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) - } - yyj1218++ - if yyhl1218 { - yyb1218 = yyj1218 > l - } else { - yyb1218 = r.CheckBreak() - } - if yyb1218 { - 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) - } - yyj1218++ - if yyhl1218 { - yyb1218 = yyj1218 > l - } else { - yyb1218 = r.CheckBreak() - } - if yyb1218 { - 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) - } - yyj1218++ - if yyhl1218 { - yyb1218 = yyj1218 > l - } else { - yyb1218 = r.CheckBreak() - } - if yyb1218 { - 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 { - yyj1218++ - if yyhl1218 { - yyb1218 = yyj1218 > l - } else { - yyb1218 = r.CheckBreak() - } - if yyb1218 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1218-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 { - yym1223 := z.EncBinary() - _ = yym1223 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1224 := !z.EncBinary() - yy2arr1224 := z.EncBasicHandle().StructToArray - var yyq1224 [2]bool - _, _, _ = yysep1224, yyq1224, yy2arr1224 - const yyr1224 bool = false - yyq1224[0] = x.APIVersion != "" - var yynn1224 int - if yyr1224 || yy2arr1224 { - r.EncodeArrayStart(2) - } else { - yynn1224 = 1 - for _, b := range yyq1224 { - if b { - yynn1224++ - } - } - r.EncodeMapStart(yynn1224) - yynn1224 = 0 - } - if yyr1224 || yy2arr1224 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1224[0] { - yym1226 := z.EncBinary() - _ = yym1226 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1224[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1227 := z.EncBinary() - _ = yym1227 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1224 || yy2arr1224 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1229 := z.EncBinary() - _ = yym1229 - 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) - yym1230 := z.EncBinary() - _ = yym1230 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } - if yyr1224 || yy2arr1224 { - 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 - yym1231 := z.DecBinary() - _ = yym1231 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1232 := r.ContainerType() - if yyct1232 == codecSelferValueTypeMap1234 { - yyl1232 := r.ReadMapStart() - if yyl1232 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1232, d) - } - } else if yyct1232 == codecSelferValueTypeArray1234 { - yyl1232 := r.ReadArrayStart() - if yyl1232 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1232, 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 yys1233Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1233Slc - var yyhl1233 bool = l >= 0 - for yyj1233 := 0; ; yyj1233++ { - if yyhl1233 { - if yyj1233 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1233Slc = r.DecodeBytes(yys1233Slc, true, true) - yys1233 := string(yys1233Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1233 { - 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, yys1233) - } // end switch yys1233 - } // end for yyj1233 - 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 yyj1236 int - var yyb1236 bool - var yyhl1236 bool = l >= 0 - yyj1236++ - if yyhl1236 { - yyb1236 = yyj1236 > l - } else { - yyb1236 = r.CheckBreak() - } - if yyb1236 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1236++ - if yyhl1236 { - yyb1236 = yyj1236 > l - } else { - yyb1236 = r.CheckBreak() - } - if yyb1236 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldPath = "" - } else { - x.FieldPath = string(r.DecodeString()) - } - for { - yyj1236++ - if yyhl1236 { - yyb1236 = yyj1236 > l - } else { - yyb1236 = r.CheckBreak() - } - if yyb1236 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1236-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 { - yym1239 := z.EncBinary() - _ = yym1239 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1240 := !z.EncBinary() - yy2arr1240 := z.EncBasicHandle().StructToArray - var yyq1240 [3]bool - _, _, _ = yysep1240, yyq1240, yy2arr1240 - const yyr1240 bool = false - yyq1240[0] = x.ContainerName != "" - yyq1240[2] = true - var yynn1240 int - if yyr1240 || yy2arr1240 { - r.EncodeArrayStart(3) - } else { - yynn1240 = 1 - for _, b := range yyq1240 { - if b { - yynn1240++ - } - } - r.EncodeMapStart(yynn1240) - yynn1240 = 0 - } - if yyr1240 || yy2arr1240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1240[0] { - yym1242 := z.EncBinary() - _ = yym1242 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1240[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1243 := z.EncBinary() - _ = yym1243 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) - } - } - } - if yyr1240 || yy2arr1240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1245 := z.EncBinary() - _ = yym1245 - 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) - yym1246 := z.EncBinary() - _ = yym1246 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) - } - } - if yyr1240 || yy2arr1240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1240[2] { - yy1248 := &x.Divisor - yym1249 := z.EncBinary() - _ = yym1249 - if false { - } else if z.HasExtensions() && z.EncExt(yy1248) { - } else if !yym1249 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1248) - } else { - z.EncFallback(yy1248) - } - } else { - r.EncodeNil() - } - } else { - if yyq1240[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("divisor")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1250 := &x.Divisor - yym1251 := z.EncBinary() - _ = yym1251 - if false { - } else if z.HasExtensions() && z.EncExt(yy1250) { - } else if !yym1251 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1250) - } else { - z.EncFallback(yy1250) - } - } - } - if yyr1240 || yy2arr1240 { - 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 - yym1252 := z.DecBinary() - _ = yym1252 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1253 := r.ContainerType() - if yyct1253 == codecSelferValueTypeMap1234 { - yyl1253 := r.ReadMapStart() - if yyl1253 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1253, d) - } - } else if yyct1253 == codecSelferValueTypeArray1234 { - yyl1253 := r.ReadArrayStart() - if yyl1253 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1253, 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 yys1254Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1254Slc - var yyhl1254 bool = l >= 0 - for yyj1254 := 0; ; yyj1254++ { - if yyhl1254 { - if yyj1254 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1254Slc = r.DecodeBytes(yys1254Slc, true, true) - yys1254 := string(yys1254Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1254 { - 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 { - yyv1257 := &x.Divisor - yym1258 := z.DecBinary() - _ = yym1258 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1257) { - } else if !yym1258 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1257) - } else { - z.DecFallback(yyv1257, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1254) - } // end switch yys1254 - } // end for yyj1254 - 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 yyj1259 int - var yyb1259 bool - var yyhl1259 bool = l >= 0 - yyj1259++ - if yyhl1259 { - yyb1259 = yyj1259 > l - } else { - yyb1259 = r.CheckBreak() - } - if yyb1259 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerName = "" - } else { - x.ContainerName = string(r.DecodeString()) - } - yyj1259++ - if yyhl1259 { - yyb1259 = yyj1259 > l - } else { - yyb1259 = r.CheckBreak() - } - if yyb1259 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resource = "" - } else { - x.Resource = string(r.DecodeString()) - } - yyj1259++ - if yyhl1259 { - yyb1259 = yyj1259 > l - } else { - yyb1259 = r.CheckBreak() - } - if yyb1259 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Divisor = pkg3_resource.Quantity{} - } else { - yyv1262 := &x.Divisor - yym1263 := z.DecBinary() - _ = yym1263 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1262) { - } else if !yym1263 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1262) - } else { - z.DecFallback(yyv1262, false) - } - } - for { - yyj1259++ - if yyhl1259 { - yyb1259 = yyj1259 > l - } else { - yyb1259 = r.CheckBreak() - } - if yyb1259 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1259-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 { - yym1264 := z.EncBinary() - _ = yym1264 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1265 := !z.EncBinary() - yy2arr1265 := z.EncBasicHandle().StructToArray - var yyq1265 [2]bool - _, _, _ = yysep1265, yyq1265, yy2arr1265 - const yyr1265 bool = false - yyq1265[0] = x.Name != "" - var yynn1265 int - if yyr1265 || yy2arr1265 { - r.EncodeArrayStart(2) - } else { - yynn1265 = 1 - for _, b := range yyq1265 { - if b { - yynn1265++ - } - } - r.EncodeMapStart(yynn1265) - yynn1265 = 0 - } - if yyr1265 || yy2arr1265 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1265[0] { - yym1267 := z.EncBinary() - _ = yym1267 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1265[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1268 := z.EncBinary() - _ = yym1268 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr1265 || yy2arr1265 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1270 := z.EncBinary() - _ = yym1270 - 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) - yym1271 := z.EncBinary() - _ = yym1271 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1265 || yy2arr1265 { - 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 - yym1272 := z.DecBinary() - _ = yym1272 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1273 := r.ContainerType() - if yyct1273 == codecSelferValueTypeMap1234 { - yyl1273 := r.ReadMapStart() - if yyl1273 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1273, d) - } - } else if yyct1273 == codecSelferValueTypeArray1234 { - yyl1273 := r.ReadArrayStart() - if yyl1273 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1273, 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 yys1274Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1274Slc - var yyhl1274 bool = l >= 0 - for yyj1274 := 0; ; yyj1274++ { - if yyhl1274 { - if yyj1274 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1274Slc = r.DecodeBytes(yys1274Slc, true, true) - yys1274 := string(yys1274Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1274 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "key": - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1274) - } // end switch yys1274 - } // end for yyj1274 - 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 yyj1277 int - var yyb1277 bool - var yyhl1277 bool = l >= 0 - yyj1277++ - if yyhl1277 { - yyb1277 = yyj1277 > l - } else { - yyb1277 = r.CheckBreak() - } - if yyb1277 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1277++ - if yyhl1277 { - yyb1277 = yyj1277 > l - } else { - yyb1277 = r.CheckBreak() - } - if yyb1277 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - for { - yyj1277++ - if yyhl1277 { - yyb1277 = yyj1277 > l - } else { - yyb1277 = r.CheckBreak() - } - if yyb1277 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1277-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 { - yym1280 := z.EncBinary() - _ = yym1280 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1281 := !z.EncBinary() - yy2arr1281 := z.EncBasicHandle().StructToArray - var yyq1281 [2]bool - _, _, _ = yysep1281, yyq1281, yy2arr1281 - const yyr1281 bool = false - yyq1281[0] = x.Name != "" - var yynn1281 int - if yyr1281 || yy2arr1281 { - r.EncodeArrayStart(2) - } else { - yynn1281 = 1 - for _, b := range yyq1281 { - if b { - yynn1281++ - } - } - r.EncodeMapStart(yynn1281) - yynn1281 = 0 - } - if yyr1281 || yy2arr1281 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1281[0] { - yym1283 := z.EncBinary() - _ = yym1283 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1281[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1284 := z.EncBinary() - _ = yym1284 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr1281 || yy2arr1281 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1286 := z.EncBinary() - _ = yym1286 - 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) - yym1287 := z.EncBinary() - _ = yym1287 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1281 || yy2arr1281 { - 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 - yym1288 := z.DecBinary() - _ = yym1288 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1289 := r.ContainerType() - if yyct1289 == codecSelferValueTypeMap1234 { - yyl1289 := r.ReadMapStart() - if yyl1289 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1289, d) - } - } else if yyct1289 == codecSelferValueTypeArray1234 { - yyl1289 := r.ReadArrayStart() - if yyl1289 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1289, 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 yys1290Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1290Slc - var yyhl1290 bool = l >= 0 - for yyj1290 := 0; ; yyj1290++ { - if yyhl1290 { - if yyj1290 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1290Slc = r.DecodeBytes(yys1290Slc, true, true) - yys1290 := string(yys1290Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1290 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "key": - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1290) - } // end switch yys1290 - } // end for yyj1290 - 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 yyj1293 int - var yyb1293 bool - var yyhl1293 bool = l >= 0 - yyj1293++ - if yyhl1293 { - yyb1293 = yyj1293 > l - } else { - yyb1293 = r.CheckBreak() - } - if yyb1293 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1293++ - if yyhl1293 { - yyb1293 = yyj1293 > l - } else { - yyb1293 = r.CheckBreak() - } - if yyb1293 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - for { - yyj1293++ - if yyhl1293 { - yyb1293 = yyj1293 > l - } else { - yyb1293 = r.CheckBreak() - } - if yyb1293 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1293-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 { - yym1296 := z.EncBinary() - _ = yym1296 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1297 := !z.EncBinary() - yy2arr1297 := z.EncBasicHandle().StructToArray - var yyq1297 [2]bool - _, _, _ = yysep1297, yyq1297, yy2arr1297 - const yyr1297 bool = false - var yynn1297 int - if yyr1297 || yy2arr1297 { - r.EncodeArrayStart(2) - } else { - yynn1297 = 2 - for _, b := range yyq1297 { - if b { - yynn1297++ - } - } - r.EncodeMapStart(yynn1297) - yynn1297 = 0 - } - if yyr1297 || yy2arr1297 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1299 := z.EncBinary() - _ = yym1299 - 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) - yym1300 := z.EncBinary() - _ = yym1300 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1297 || yy2arr1297 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1302 := z.EncBinary() - _ = yym1302 - 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) - yym1303 := z.EncBinary() - _ = yym1303 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - if yyr1297 || yy2arr1297 { - 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 - yym1304 := z.DecBinary() - _ = yym1304 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1305 := r.ContainerType() - if yyct1305 == codecSelferValueTypeMap1234 { - yyl1305 := r.ReadMapStart() - if yyl1305 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1305, d) - } - } else if yyct1305 == codecSelferValueTypeArray1234 { - yyl1305 := r.ReadArrayStart() - if yyl1305 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1305, 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 yys1306Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1306Slc - var yyhl1306 bool = l >= 0 - for yyj1306 := 0; ; yyj1306++ { - if yyhl1306 { - if yyj1306 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1306Slc = r.DecodeBytes(yys1306Slc, true, true) - yys1306 := string(yys1306Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1306 { - 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, yys1306) - } // end switch yys1306 - } // end for yyj1306 - 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 yyj1309 int - var yyb1309 bool - var yyhl1309 bool = l >= 0 - yyj1309++ - if yyhl1309 { - yyb1309 = yyj1309 > l - } else { - yyb1309 = r.CheckBreak() - } - if yyb1309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1309++ - if yyhl1309 { - yyb1309 = yyj1309 > l - } else { - yyb1309 = r.CheckBreak() - } - if yyb1309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - for { - yyj1309++ - if yyhl1309 { - yyb1309 = yyj1309 > l - } else { - yyb1309 = r.CheckBreak() - } - if yyb1309 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1309-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 { - yym1312 := z.EncBinary() - _ = yym1312 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1313 := !z.EncBinary() - yy2arr1313 := z.EncBasicHandle().StructToArray - var yyq1313 [5]bool - _, _, _ = yysep1313, yyq1313, yy2arr1313 - const yyr1313 bool = false - yyq1313[0] = x.Path != "" - yyq1313[2] = x.Host != "" - yyq1313[3] = x.Scheme != "" - yyq1313[4] = len(x.HTTPHeaders) != 0 - var yynn1313 int - if yyr1313 || yy2arr1313 { - r.EncodeArrayStart(5) - } else { - yynn1313 = 1 - for _, b := range yyq1313 { - if b { - yynn1313++ - } - } - r.EncodeMapStart(yynn1313) - yynn1313 = 0 - } - if yyr1313 || yy2arr1313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1313[0] { - yym1315 := z.EncBinary() - _ = yym1315 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1313[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1316 := z.EncBinary() - _ = yym1316 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr1313 || yy2arr1313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1318 := &x.Port - yym1319 := z.EncBinary() - _ = yym1319 - if false { - } else if z.HasExtensions() && z.EncExt(yy1318) { - } else if !yym1319 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1318) - } else { - z.EncFallback(yy1318) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1320 := &x.Port - yym1321 := z.EncBinary() - _ = yym1321 - if false { - } else if z.HasExtensions() && z.EncExt(yy1320) { - } else if !yym1321 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1320) - } else { - z.EncFallback(yy1320) - } - } - if yyr1313 || yy2arr1313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1313[2] { - yym1323 := z.EncBinary() - _ = yym1323 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1313[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("host")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1324 := z.EncBinary() - _ = yym1324 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } - } - if yyr1313 || yy2arr1313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1313[3] { - x.Scheme.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1313[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scheme")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Scheme.CodecEncodeSelf(e) - } - } - if yyr1313 || yy2arr1313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1313[4] { - if x.HTTPHeaders == nil { - r.EncodeNil() - } else { - yym1327 := z.EncBinary() - _ = yym1327 - if false { - } else { - h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1313[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("httpHeaders")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.HTTPHeaders == nil { - r.EncodeNil() - } else { - yym1328 := z.EncBinary() - _ = yym1328 - if false { - } else { - h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) - } - } - } - } - if yyr1313 || yy2arr1313 { - 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 - yym1329 := z.DecBinary() - _ = yym1329 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1330 := r.ContainerType() - if yyct1330 == codecSelferValueTypeMap1234 { - yyl1330 := r.ReadMapStart() - if yyl1330 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1330, d) - } - } else if yyct1330 == codecSelferValueTypeArray1234 { - yyl1330 := r.ReadArrayStart() - if yyl1330 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1330, 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 yys1331Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1331Slc - var yyhl1331 bool = l >= 0 - for yyj1331 := 0; ; yyj1331++ { - if yyhl1331 { - if yyj1331 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1331Slc = r.DecodeBytes(yys1331Slc, true, true) - yys1331 := string(yys1331Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1331 { - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - case "port": - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1333 := &x.Port - yym1334 := z.DecBinary() - _ = yym1334 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1333) { - } else if !yym1334 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1333) - } else { - z.DecFallback(yyv1333, 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 { - yyv1337 := &x.HTTPHeaders - yym1338 := z.DecBinary() - _ = yym1338 - if false { - } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1337), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1331) - } // end switch yys1331 - } // end for yyj1331 - 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 yyj1339 int - var yyb1339 bool - var yyhl1339 bool = l >= 0 - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1341 := &x.Port - yym1342 := z.DecBinary() - _ = yym1342 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1341) { - } else if !yym1342 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1341) - } else { - z.DecFallback(yyv1341, false) - } - } - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Scheme = "" - } else { - x.Scheme = URIScheme(r.DecodeString()) - } - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HTTPHeaders = nil - } else { - yyv1345 := &x.HTTPHeaders - yym1346 := z.DecBinary() - _ = yym1346 - if false { - } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1345), d) - } - } - for { - yyj1339++ - if yyhl1339 { - yyb1339 = yyj1339 > l - } else { - yyb1339 = r.CheckBreak() - } - if yyb1339 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1339-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x URIScheme) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1347 := z.EncBinary() - _ = yym1347 - 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 - yym1348 := z.DecBinary() - _ = yym1348 - 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 { - yym1349 := z.EncBinary() - _ = yym1349 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1350 := !z.EncBinary() - yy2arr1350 := z.EncBasicHandle().StructToArray - var yyq1350 [1]bool - _, _, _ = yysep1350, yyq1350, yy2arr1350 - const yyr1350 bool = false - var yynn1350 int - if yyr1350 || yy2arr1350 { - r.EncodeArrayStart(1) - } else { - yynn1350 = 1 - for _, b := range yyq1350 { - if b { - yynn1350++ - } - } - r.EncodeMapStart(yynn1350) - yynn1350 = 0 - } - if yyr1350 || yy2arr1350 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1352 := &x.Port - yym1353 := z.EncBinary() - _ = yym1353 - if false { - } else if z.HasExtensions() && z.EncExt(yy1352) { - } else if !yym1353 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1352) - } else { - z.EncFallback(yy1352) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1354 := &x.Port - yym1355 := z.EncBinary() - _ = yym1355 - if false { - } else if z.HasExtensions() && z.EncExt(yy1354) { - } else if !yym1355 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1354) - } else { - z.EncFallback(yy1354) - } - } - if yyr1350 || yy2arr1350 { - 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 - yym1356 := z.DecBinary() - _ = yym1356 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1357 := r.ContainerType() - if yyct1357 == codecSelferValueTypeMap1234 { - yyl1357 := r.ReadMapStart() - if yyl1357 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1357, d) - } - } else if yyct1357 == codecSelferValueTypeArray1234 { - yyl1357 := r.ReadArrayStart() - if yyl1357 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1357, 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 yys1358Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1358Slc - var yyhl1358 bool = l >= 0 - for yyj1358 := 0; ; yyj1358++ { - if yyhl1358 { - if yyj1358 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1358Slc = r.DecodeBytes(yys1358Slc, true, true) - yys1358 := string(yys1358Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1358 { - case "port": - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1359 := &x.Port - yym1360 := z.DecBinary() - _ = yym1360 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1359) { - } else if !yym1360 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1359) - } else { - z.DecFallback(yyv1359, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1358) - } // end switch yys1358 - } // end for yyj1358 - 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 yyj1361 int - var yyb1361 bool - var yyhl1361 bool = l >= 0 - yyj1361++ - if yyhl1361 { - yyb1361 = yyj1361 > l - } else { - yyb1361 = r.CheckBreak() - } - if yyb1361 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1362 := &x.Port - yym1363 := z.DecBinary() - _ = yym1363 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1362) { - } else if !yym1363 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1362) - } else { - z.DecFallback(yyv1362, false) - } - } - for { - yyj1361++ - if yyhl1361 { - yyb1361 = yyj1361 > l - } else { - yyb1361 = r.CheckBreak() - } - if yyb1361 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1361-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 { - yym1364 := z.EncBinary() - _ = yym1364 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1365 := !z.EncBinary() - yy2arr1365 := z.EncBasicHandle().StructToArray - var yyq1365 [1]bool - _, _, _ = yysep1365, yyq1365, yy2arr1365 - const yyr1365 bool = false - yyq1365[0] = len(x.Command) != 0 - var yynn1365 int - if yyr1365 || yy2arr1365 { - r.EncodeArrayStart(1) - } else { - yynn1365 = 0 - for _, b := range yyq1365 { - if b { - yynn1365++ - } - } - r.EncodeMapStart(yynn1365) - yynn1365 = 0 - } - if yyr1365 || yy2arr1365 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1365[0] { - if x.Command == nil { - r.EncodeNil() - } else { - yym1367 := z.EncBinary() - _ = yym1367 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1365[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("command")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym1368 := z.EncBinary() - _ = yym1368 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - } - if yyr1365 || yy2arr1365 { - 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 - yym1369 := z.DecBinary() - _ = yym1369 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1370 := r.ContainerType() - if yyct1370 == codecSelferValueTypeMap1234 { - yyl1370 := r.ReadMapStart() - if yyl1370 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1370, d) - } - } else if yyct1370 == codecSelferValueTypeArray1234 { - yyl1370 := r.ReadArrayStart() - if yyl1370 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1370, 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 yys1371Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1371Slc - var yyhl1371 bool = l >= 0 - for yyj1371 := 0; ; yyj1371++ { - if yyhl1371 { - if yyj1371 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1371Slc = r.DecodeBytes(yys1371Slc, true, true) - yys1371 := string(yys1371Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1371 { - case "command": - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv1372 := &x.Command - yym1373 := z.DecBinary() - _ = yym1373 - if false { - } else { - z.F.DecSliceStringX(yyv1372, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1371) - } // end switch yys1371 - } // end for yyj1371 - 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 yyj1374 int - var yyb1374 bool - var yyhl1374 bool = l >= 0 - yyj1374++ - if yyhl1374 { - yyb1374 = yyj1374 > l - } else { - yyb1374 = r.CheckBreak() - } - if yyb1374 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv1375 := &x.Command - yym1376 := z.DecBinary() - _ = yym1376 - if false { - } else { - z.F.DecSliceStringX(yyv1375, false, d) - } - } - for { - yyj1374++ - if yyhl1374 { - yyb1374 = yyj1374 > l - } else { - yyb1374 = r.CheckBreak() - } - if yyb1374 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1374-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 { - yym1377 := z.EncBinary() - _ = yym1377 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1378 := !z.EncBinary() - yy2arr1378 := z.EncBasicHandle().StructToArray - var yyq1378 [8]bool - _, _, _ = yysep1378, yyq1378, yy2arr1378 - const yyr1378 bool = false - yyq1378[0] = x.Handler.Exec != nil && x.Exec != nil - yyq1378[1] = x.Handler.HTTPGet != nil && x.HTTPGet != nil - yyq1378[2] = x.Handler.TCPSocket != nil && x.TCPSocket != nil - yyq1378[3] = x.InitialDelaySeconds != 0 - yyq1378[4] = x.TimeoutSeconds != 0 - yyq1378[5] = x.PeriodSeconds != 0 - yyq1378[6] = x.SuccessThreshold != 0 - yyq1378[7] = x.FailureThreshold != 0 - var yynn1378 int - if yyr1378 || yy2arr1378 { - r.EncodeArrayStart(8) - } else { - yynn1378 = 0 - for _, b := range yyq1378 { - if b { - yynn1378++ - } - } - r.EncodeMapStart(yynn1378) - yynn1378 = 0 - } - var yyn1379 bool - if x.Handler.Exec == nil { - yyn1379 = true - goto LABEL1379 - } - LABEL1379: - if yyr1378 || yy2arr1378 { - if yyn1379 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[0] { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1378[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1379 { - r.EncodeNil() - } else { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } - } - } - var yyn1380 bool - if x.Handler.HTTPGet == nil { - yyn1380 = true - goto LABEL1380 - } - LABEL1380: - if yyr1378 || yy2arr1378 { - if yyn1380 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[1] { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1378[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("httpGet")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1380 { - r.EncodeNil() - } else { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } - } - } - var yyn1381 bool - if x.Handler.TCPSocket == nil { - yyn1381 = true - goto LABEL1381 - } - LABEL1381: - if yyr1378 || yy2arr1378 { - if yyn1381 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[2] { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1378[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tcpSocket")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1381 { - r.EncodeNil() - } else { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[3] { - yym1383 := z.EncBinary() - _ = yym1383 - if false { - } else { - r.EncodeInt(int64(x.InitialDelaySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1378[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("initialDelaySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1384 := z.EncBinary() - _ = yym1384 - if false { - } else { - r.EncodeInt(int64(x.InitialDelaySeconds)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[4] { - yym1386 := z.EncBinary() - _ = yym1386 - if false { - } else { - r.EncodeInt(int64(x.TimeoutSeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1378[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1387 := z.EncBinary() - _ = yym1387 - if false { - } else { - r.EncodeInt(int64(x.TimeoutSeconds)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[5] { - yym1389 := z.EncBinary() - _ = yym1389 - if false { - } else { - r.EncodeInt(int64(x.PeriodSeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1378[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("periodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1390 := z.EncBinary() - _ = yym1390 - if false { - } else { - r.EncodeInt(int64(x.PeriodSeconds)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[6] { - yym1392 := z.EncBinary() - _ = yym1392 - if false { - } else { - r.EncodeInt(int64(x.SuccessThreshold)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1378[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("successThreshold")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1393 := z.EncBinary() - _ = yym1393 - if false { - } else { - r.EncodeInt(int64(x.SuccessThreshold)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[7] { - yym1395 := z.EncBinary() - _ = yym1395 - if false { - } else { - r.EncodeInt(int64(x.FailureThreshold)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1378[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("failureThreshold")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1396 := z.EncBinary() - _ = yym1396 - if false { - } else { - r.EncodeInt(int64(x.FailureThreshold)) - } - } - } - if yyr1378 || yy2arr1378 { - 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 - yym1397 := z.DecBinary() - _ = yym1397 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1398 := r.ContainerType() - if yyct1398 == codecSelferValueTypeMap1234 { - yyl1398 := r.ReadMapStart() - if yyl1398 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1398, d) - } - } else if yyct1398 == codecSelferValueTypeArray1234 { - yyl1398 := r.ReadArrayStart() - if yyl1398 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1398, 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 yys1399Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1399Slc - var yyhl1399 bool = l >= 0 - for yyj1399 := 0; ; yyj1399++ { - if yyhl1399 { - if yyj1399 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1399Slc = r.DecodeBytes(yys1399Slc, true, true) - yys1399 := string(yys1399Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1399 { - 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) - } - 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)) - } - default: - z.DecStructFieldNotFound(-1, yys1399) - } // end switch yys1399 - } // end for yyj1399 - 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 yyj1408 int - var yyb1408 bool - var yyhl1408 bool = l >= 0 - if x.Handler.Exec == nil { - x.Handler.Exec = new(ExecAction) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - 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) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - 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) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - 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) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.InitialDelaySeconds = 0 - } else { - x.InitialDelaySeconds = int32(r.DecodeInt(32)) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TimeoutSeconds = 0 - } else { - x.TimeoutSeconds = int32(r.DecodeInt(32)) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PeriodSeconds = 0 - } else { - x.PeriodSeconds = int32(r.DecodeInt(32)) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SuccessThreshold = 0 - } else { - x.SuccessThreshold = int32(r.DecodeInt(32)) - } - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FailureThreshold = 0 - } else { - x.FailureThreshold = int32(r.DecodeInt(32)) - } - for { - yyj1408++ - if yyhl1408 { - yyb1408 = yyj1408 > l - } else { - yyb1408 = r.CheckBreak() - } - if yyb1408 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1408-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PullPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1417 := z.EncBinary() - _ = yym1417 - 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 - yym1418 := z.DecBinary() - _ = yym1418 - 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 - yym1419 := z.EncBinary() - _ = yym1419 - 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 - yym1420 := z.DecBinary() - _ = yym1420 - 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 { - yym1421 := z.EncBinary() - _ = yym1421 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1422 := !z.EncBinary() - yy2arr1422 := z.EncBasicHandle().StructToArray - var yyq1422 [2]bool - _, _, _ = yysep1422, yyq1422, yy2arr1422 - const yyr1422 bool = false - yyq1422[0] = len(x.Add) != 0 - yyq1422[1] = len(x.Drop) != 0 - var yynn1422 int - if yyr1422 || yy2arr1422 { - r.EncodeArrayStart(2) - } else { - yynn1422 = 0 - for _, b := range yyq1422 { - if b { - yynn1422++ - } - } - r.EncodeMapStart(yynn1422) - yynn1422 = 0 - } - if yyr1422 || yy2arr1422 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1422[0] { - if x.Add == nil { - r.EncodeNil() - } else { - yym1424 := z.EncBinary() - _ = yym1424 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Add), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1422[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("add")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Add == nil { - r.EncodeNil() - } else { - yym1425 := z.EncBinary() - _ = yym1425 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Add), e) - } - } - } - } - if yyr1422 || yy2arr1422 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1422[1] { - if x.Drop == nil { - r.EncodeNil() - } else { - yym1427 := z.EncBinary() - _ = yym1427 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Drop), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1422[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("drop")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Drop == nil { - r.EncodeNil() - } else { - yym1428 := z.EncBinary() - _ = yym1428 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Drop), e) - } - } - } - } - if yyr1422 || yy2arr1422 { - 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 - yym1429 := z.DecBinary() - _ = yym1429 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1430 := r.ContainerType() - if yyct1430 == codecSelferValueTypeMap1234 { - yyl1430 := r.ReadMapStart() - if yyl1430 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1430, d) - } - } else if yyct1430 == codecSelferValueTypeArray1234 { - yyl1430 := r.ReadArrayStart() - if yyl1430 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1430, 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 yys1431Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1431Slc - var yyhl1431 bool = l >= 0 - for yyj1431 := 0; ; yyj1431++ { - if yyhl1431 { - if yyj1431 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1431Slc = r.DecodeBytes(yys1431Slc, true, true) - yys1431 := string(yys1431Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1431 { - case "add": - if r.TryDecodeAsNil() { - x.Add = nil - } else { - yyv1432 := &x.Add - yym1433 := z.DecBinary() - _ = yym1433 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1432), d) - } - } - case "drop": - if r.TryDecodeAsNil() { - x.Drop = nil - } else { - yyv1434 := &x.Drop - yym1435 := z.DecBinary() - _ = yym1435 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1434), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1431) - } // end switch yys1431 - } // end for yyj1431 - 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 yyj1436 int - var yyb1436 bool - var yyhl1436 bool = l >= 0 - yyj1436++ - if yyhl1436 { - yyb1436 = yyj1436 > l - } else { - yyb1436 = r.CheckBreak() - } - if yyb1436 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Add = nil - } else { - yyv1437 := &x.Add - yym1438 := z.DecBinary() - _ = yym1438 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1437), d) - } - } - yyj1436++ - if yyhl1436 { - yyb1436 = yyj1436 > l - } else { - yyb1436 = r.CheckBreak() - } - if yyb1436 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Drop = nil - } else { - yyv1439 := &x.Drop - yym1440 := z.DecBinary() - _ = yym1440 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1439), d) - } - } - for { - yyj1436++ - if yyhl1436 { - yyb1436 = yyj1436 > l - } else { - yyb1436 = r.CheckBreak() - } - if yyb1436 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1436-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 { - yym1441 := z.EncBinary() - _ = yym1441 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1442 := !z.EncBinary() - yy2arr1442 := z.EncBasicHandle().StructToArray - var yyq1442 [2]bool - _, _, _ = yysep1442, yyq1442, yy2arr1442 - const yyr1442 bool = false - yyq1442[0] = len(x.Limits) != 0 - yyq1442[1] = len(x.Requests) != 0 - var yynn1442 int - if yyr1442 || yy2arr1442 { - r.EncodeArrayStart(2) - } else { - yynn1442 = 0 - for _, b := range yyq1442 { - if b { - yynn1442++ - } - } - r.EncodeMapStart(yynn1442) - yynn1442 = 0 - } - if yyr1442 || yy2arr1442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1442[0] { - if x.Limits == nil { - r.EncodeNil() - } else { - x.Limits.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1442[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 yyr1442 || yy2arr1442 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1442[1] { - if x.Requests == nil { - r.EncodeNil() - } else { - x.Requests.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1442[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 yyr1442 || yy2arr1442 { - 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 - yym1445 := z.DecBinary() - _ = yym1445 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1446 := r.ContainerType() - if yyct1446 == codecSelferValueTypeMap1234 { - yyl1446 := r.ReadMapStart() - if yyl1446 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1446, d) - } - } else if yyct1446 == codecSelferValueTypeArray1234 { - yyl1446 := r.ReadArrayStart() - if yyl1446 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1446, 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 yys1447Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1447Slc - var yyhl1447 bool = l >= 0 - for yyj1447 := 0; ; yyj1447++ { - if yyhl1447 { - if yyj1447 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1447Slc = r.DecodeBytes(yys1447Slc, true, true) - yys1447 := string(yys1447Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1447 { - case "limits": - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv1448 := &x.Limits - yyv1448.CodecDecodeSelf(d) - } - case "requests": - if r.TryDecodeAsNil() { - x.Requests = nil - } else { - yyv1449 := &x.Requests - yyv1449.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1447) - } // end switch yys1447 - } // end for yyj1447 - 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 yyj1450 int - var yyb1450 bool - var yyhl1450 bool = l >= 0 - yyj1450++ - if yyhl1450 { - yyb1450 = yyj1450 > l - } else { - yyb1450 = r.CheckBreak() - } - if yyb1450 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv1451 := &x.Limits - yyv1451.CodecDecodeSelf(d) - } - yyj1450++ - if yyhl1450 { - yyb1450 = yyj1450 > l - } else { - yyb1450 = r.CheckBreak() - } - if yyb1450 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Requests = nil - } else { - yyv1452 := &x.Requests - yyv1452.CodecDecodeSelf(d) - } - for { - yyj1450++ - if yyhl1450 { - yyb1450 = yyj1450 > l - } else { - yyb1450 = r.CheckBreak() - } - if yyb1450 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1450-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 { - yym1453 := z.EncBinary() - _ = yym1453 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1454 := !z.EncBinary() - yy2arr1454 := z.EncBasicHandle().StructToArray - var yyq1454 [18]bool - _, _, _ = yysep1454, yyq1454, yy2arr1454 - const yyr1454 bool = false - yyq1454[1] = x.Image != "" - yyq1454[2] = len(x.Command) != 0 - yyq1454[3] = len(x.Args) != 0 - yyq1454[4] = x.WorkingDir != "" - yyq1454[5] = len(x.Ports) != 0 - yyq1454[6] = len(x.Env) != 0 - yyq1454[7] = true - yyq1454[8] = len(x.VolumeMounts) != 0 - yyq1454[9] = x.LivenessProbe != nil - yyq1454[10] = x.ReadinessProbe != nil - yyq1454[11] = x.Lifecycle != nil - yyq1454[12] = x.TerminationMessagePath != "" - yyq1454[13] = x.ImagePullPolicy != "" - yyq1454[14] = x.SecurityContext != nil - yyq1454[15] = x.Stdin != false - yyq1454[16] = x.StdinOnce != false - yyq1454[17] = x.TTY != false - var yynn1454 int - if yyr1454 || yy2arr1454 { - r.EncodeArrayStart(18) - } else { - yynn1454 = 1 - for _, b := range yyq1454 { - if b { - yynn1454++ - } - } - r.EncodeMapStart(yynn1454) - yynn1454 = 0 - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1456 := z.EncBinary() - _ = yym1456 - 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) - yym1457 := z.EncBinary() - _ = yym1457 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[1] { - yym1459 := z.EncBinary() - _ = yym1459 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1454[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("image")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1460 := z.EncBinary() - _ = yym1460 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[2] { - if x.Command == nil { - r.EncodeNil() - } else { - yym1462 := z.EncBinary() - _ = yym1462 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("command")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym1463 := z.EncBinary() - _ = yym1463 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[3] { - if x.Args == nil { - r.EncodeNil() - } else { - yym1465 := z.EncBinary() - _ = yym1465 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("args")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Args == nil { - r.EncodeNil() - } else { - yym1466 := z.EncBinary() - _ = yym1466 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[4] { - yym1468 := z.EncBinary() - _ = yym1468 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1454[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("workingDir")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1469 := z.EncBinary() - _ = yym1469 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[5] { - if x.Ports == nil { - r.EncodeNil() - } else { - yym1471 := z.EncBinary() - _ = yym1471 - if false { - } else { - h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ports")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym1472 := z.EncBinary() - _ = yym1472 - if false { - } else { - h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) - } - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[6] { - if x.Env == nil { - r.EncodeNil() - } else { - yym1474 := z.EncBinary() - _ = yym1474 - if false { - } else { - h.encSliceEnvVar(([]EnvVar)(x.Env), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("env")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Env == nil { - r.EncodeNil() - } else { - yym1475 := z.EncBinary() - _ = yym1475 - if false { - } else { - h.encSliceEnvVar(([]EnvVar)(x.Env), e) - } - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[7] { - yy1477 := &x.Resources - yy1477.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1454[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resources")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1478 := &x.Resources - yy1478.CodecEncodeSelf(e) - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[8] { - if x.VolumeMounts == nil { - r.EncodeNil() - } else { - yym1480 := z.EncBinary() - _ = yym1480 - if false { - } else { - h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeMounts")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumeMounts == nil { - r.EncodeNil() - } else { - yym1481 := z.EncBinary() - _ = yym1481 - if false { - } else { - h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) - } - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[9] { - if x.LivenessProbe == nil { - r.EncodeNil() - } else { - x.LivenessProbe.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[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 yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[10] { - if x.ReadinessProbe == nil { - r.EncodeNil() - } else { - x.ReadinessProbe.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[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 yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[11] { - if x.Lifecycle == nil { - r.EncodeNil() - } else { - x.Lifecycle.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[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 yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[12] { - yym1486 := z.EncBinary() - _ = yym1486 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1454[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("terminationMessagePath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1487 := z.EncBinary() - _ = yym1487 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[13] { - x.ImagePullPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1454[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.ImagePullPolicy.CodecEncodeSelf(e) - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[14] { - if x.SecurityContext == nil { - r.EncodeNil() - } else { - x.SecurityContext.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1454[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 yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[15] { - yym1491 := z.EncBinary() - _ = yym1491 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1454[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1492 := z.EncBinary() - _ = yym1492 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[16] { - yym1494 := z.EncBinary() - _ = yym1494 - if false { - } else { - r.EncodeBool(bool(x.StdinOnce)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1454[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdinOnce")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1495 := z.EncBinary() - _ = yym1495 - if false { - } else { - r.EncodeBool(bool(x.StdinOnce)) - } - } - } - if yyr1454 || yy2arr1454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1454[17] { - yym1497 := z.EncBinary() - _ = yym1497 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1454[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tty")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1498 := z.EncBinary() - _ = yym1498 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - } - if yyr1454 || yy2arr1454 { - 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 - yym1499 := z.DecBinary() - _ = yym1499 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1500 := r.ContainerType() - if yyct1500 == codecSelferValueTypeMap1234 { - yyl1500 := r.ReadMapStart() - if yyl1500 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1500, d) - } - } else if yyct1500 == codecSelferValueTypeArray1234 { - yyl1500 := r.ReadArrayStart() - if yyl1500 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1500, 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 yys1501Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1501Slc - var yyhl1501 bool = l >= 0 - for yyj1501 := 0; ; yyj1501++ { - if yyhl1501 { - if yyj1501 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1501Slc = r.DecodeBytes(yys1501Slc, true, true) - yys1501 := string(yys1501Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1501 { - 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 { - yyv1504 := &x.Command - yym1505 := z.DecBinary() - _ = yym1505 - if false { - } else { - z.F.DecSliceStringX(yyv1504, false, d) - } - } - case "args": - if r.TryDecodeAsNil() { - x.Args = nil - } else { - yyv1506 := &x.Args - yym1507 := z.DecBinary() - _ = yym1507 - if false { - } else { - z.F.DecSliceStringX(yyv1506, false, d) - } - } - case "workingDir": - if r.TryDecodeAsNil() { - x.WorkingDir = "" - } else { - x.WorkingDir = string(r.DecodeString()) - } - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv1509 := &x.Ports - yym1510 := z.DecBinary() - _ = yym1510 - if false { - } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1509), d) - } - } - case "env": - if r.TryDecodeAsNil() { - x.Env = nil - } else { - yyv1511 := &x.Env - yym1512 := z.DecBinary() - _ = yym1512 - if false { - } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1511), d) - } - } - case "resources": - if r.TryDecodeAsNil() { - x.Resources = ResourceRequirements{} - } else { - yyv1513 := &x.Resources - yyv1513.CodecDecodeSelf(d) - } - case "volumeMounts": - if r.TryDecodeAsNil() { - x.VolumeMounts = nil - } else { - yyv1514 := &x.VolumeMounts - yym1515 := z.DecBinary() - _ = yym1515 - if false { - } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1514), 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, yys1501) - } // end switch yys1501 - } // end for yyj1501 - 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 yyj1525 int - var yyb1525 bool - var yyhl1525 bool = l >= 0 - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Image = "" - } else { - x.Image = string(r.DecodeString()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv1528 := &x.Command - yym1529 := z.DecBinary() - _ = yym1529 - if false { - } else { - z.F.DecSliceStringX(yyv1528, false, d) - } - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Args = nil - } else { - yyv1530 := &x.Args - yym1531 := z.DecBinary() - _ = yym1531 - if false { - } else { - z.F.DecSliceStringX(yyv1530, false, d) - } - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.WorkingDir = "" - } else { - x.WorkingDir = string(r.DecodeString()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv1533 := &x.Ports - yym1534 := z.DecBinary() - _ = yym1534 - if false { - } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1533), d) - } - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Env = nil - } else { - yyv1535 := &x.Env - yym1536 := z.DecBinary() - _ = yym1536 - if false { - } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1535), d) - } - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resources = ResourceRequirements{} - } else { - yyv1537 := &x.Resources - yyv1537.CodecDecodeSelf(d) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeMounts = nil - } else { - yyv1538 := &x.VolumeMounts - yym1539 := z.DecBinary() - _ = yym1539 - if false { - } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1538), d) - } - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - 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) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - 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) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - 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) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TerminationMessagePath = "" - } else { - x.TerminationMessagePath = string(r.DecodeString()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImagePullPolicy = "" - } else { - x.ImagePullPolicy = PullPolicy(r.DecodeString()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - 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) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StdinOnce = false - } else { - x.StdinOnce = bool(r.DecodeBool()) - } - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - for { - yyj1525++ - if yyhl1525 { - yyb1525 = yyj1525 > l - } else { - yyb1525 = r.CheckBreak() - } - if yyb1525 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1525-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 { - yym1549 := z.EncBinary() - _ = yym1549 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1550 := !z.EncBinary() - yy2arr1550 := z.EncBasicHandle().StructToArray - var yyq1550 [3]bool - _, _, _ = yysep1550, yyq1550, yy2arr1550 - const yyr1550 bool = false - yyq1550[0] = x.Exec != nil - yyq1550[1] = x.HTTPGet != nil - yyq1550[2] = x.TCPSocket != nil - var yynn1550 int - if yyr1550 || yy2arr1550 { - r.EncodeArrayStart(3) - } else { - yynn1550 = 0 - for _, b := range yyq1550 { - if b { - yynn1550++ - } - } - r.EncodeMapStart(yynn1550) - yynn1550 = 0 - } - if yyr1550 || yy2arr1550 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1550[0] { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1550[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 yyr1550 || yy2arr1550 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1550[1] { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1550[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 yyr1550 || yy2arr1550 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1550[2] { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1550[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 yyr1550 || yy2arr1550 { - 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 - yym1554 := z.DecBinary() - _ = yym1554 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1555 := r.ContainerType() - if yyct1555 == codecSelferValueTypeMap1234 { - yyl1555 := r.ReadMapStart() - if yyl1555 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1555, d) - } - } else if yyct1555 == codecSelferValueTypeArray1234 { - yyl1555 := r.ReadArrayStart() - if yyl1555 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1555, 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 yys1556Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1556Slc - var yyhl1556 bool = l >= 0 - for yyj1556 := 0; ; yyj1556++ { - if yyhl1556 { - if yyj1556 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1556Slc = r.DecodeBytes(yys1556Slc, true, true) - yys1556 := string(yys1556Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1556 { - 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, yys1556) - } // end switch yys1556 - } // end for yyj1556 - 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 yyj1560 int - var yyb1560 bool - var yyhl1560 bool = l >= 0 - yyj1560++ - if yyhl1560 { - yyb1560 = yyj1560 > l - } else { - yyb1560 = r.CheckBreak() - } - if yyb1560 { - 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) - } - yyj1560++ - if yyhl1560 { - yyb1560 = yyj1560 > l - } else { - yyb1560 = r.CheckBreak() - } - if yyb1560 { - 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) - } - yyj1560++ - if yyhl1560 { - yyb1560 = yyj1560 > l - } else { - yyb1560 = r.CheckBreak() - } - if yyb1560 { - 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 { - yyj1560++ - if yyhl1560 { - yyb1560 = yyj1560 > l - } else { - yyb1560 = r.CheckBreak() - } - if yyb1560 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1560-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 { - yym1564 := z.EncBinary() - _ = yym1564 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1565 := !z.EncBinary() - yy2arr1565 := z.EncBasicHandle().StructToArray - var yyq1565 [2]bool - _, _, _ = yysep1565, yyq1565, yy2arr1565 - const yyr1565 bool = false - yyq1565[0] = x.PostStart != nil - yyq1565[1] = x.PreStop != nil - var yynn1565 int - if yyr1565 || yy2arr1565 { - r.EncodeArrayStart(2) - } else { - yynn1565 = 0 - for _, b := range yyq1565 { - if b { - yynn1565++ - } - } - r.EncodeMapStart(yynn1565) - yynn1565 = 0 - } - if yyr1565 || yy2arr1565 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1565[0] { - if x.PostStart == nil { - r.EncodeNil() - } else { - x.PostStart.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1565[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 yyr1565 || yy2arr1565 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1565[1] { - if x.PreStop == nil { - r.EncodeNil() - } else { - x.PreStop.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1565[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 yyr1565 || yy2arr1565 { - 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 - yym1568 := z.DecBinary() - _ = yym1568 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1569 := r.ContainerType() - if yyct1569 == codecSelferValueTypeMap1234 { - yyl1569 := r.ReadMapStart() - if yyl1569 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1569, d) - } - } else if yyct1569 == codecSelferValueTypeArray1234 { - yyl1569 := r.ReadArrayStart() - if yyl1569 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1569, 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 yys1570Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1570Slc - var yyhl1570 bool = l >= 0 - for yyj1570 := 0; ; yyj1570++ { - if yyhl1570 { - if yyj1570 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1570Slc = r.DecodeBytes(yys1570Slc, true, true) - yys1570 := string(yys1570Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1570 { - 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, yys1570) - } // end switch yys1570 - } // end for yyj1570 - 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 yyj1573 int - var yyb1573 bool - var yyhl1573 bool = l >= 0 - yyj1573++ - if yyhl1573 { - yyb1573 = yyj1573 > l - } else { - yyb1573 = r.CheckBreak() - } - if yyb1573 { - 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) - } - yyj1573++ - if yyhl1573 { - yyb1573 = yyj1573 > l - } else { - yyb1573 = r.CheckBreak() - } - if yyb1573 { - 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 { - yyj1573++ - if yyhl1573 { - yyb1573 = yyj1573 > l - } else { - yyb1573 = r.CheckBreak() - } - if yyb1573 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1573-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ConditionStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1576 := z.EncBinary() - _ = yym1576 - 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 - yym1577 := z.DecBinary() - _ = yym1577 - 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 { - yym1578 := z.EncBinary() - _ = yym1578 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1579 := !z.EncBinary() - yy2arr1579 := z.EncBasicHandle().StructToArray - var yyq1579 [2]bool - _, _, _ = yysep1579, yyq1579, yy2arr1579 - const yyr1579 bool = false - yyq1579[0] = x.Reason != "" - yyq1579[1] = x.Message != "" - var yynn1579 int - if yyr1579 || yy2arr1579 { - r.EncodeArrayStart(2) - } else { - yynn1579 = 0 - for _, b := range yyq1579 { - if b { - yynn1579++ - } - } - r.EncodeMapStart(yynn1579) - yynn1579 = 0 - } - if yyr1579 || yy2arr1579 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1579[0] { - yym1581 := z.EncBinary() - _ = yym1581 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1579[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1582 := z.EncBinary() - _ = yym1582 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1579 || yy2arr1579 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1579[1] { - yym1584 := z.EncBinary() - _ = yym1584 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1579[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1585 := z.EncBinary() - _ = yym1585 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1579 || yy2arr1579 { - 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 - yym1586 := z.DecBinary() - _ = yym1586 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1587 := r.ContainerType() - if yyct1587 == codecSelferValueTypeMap1234 { - yyl1587 := r.ReadMapStart() - if yyl1587 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1587, d) - } - } else if yyct1587 == codecSelferValueTypeArray1234 { - yyl1587 := r.ReadArrayStart() - if yyl1587 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1587, 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 yys1588Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1588Slc - var yyhl1588 bool = l >= 0 - for yyj1588 := 0; ; yyj1588++ { - if yyhl1588 { - if yyj1588 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1588Slc = r.DecodeBytes(yys1588Slc, true, true) - yys1588 := string(yys1588Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1588 { - 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, yys1588) - } // end switch yys1588 - } // end for yyj1588 - 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 yyj1591 int - var yyb1591 bool - var yyhl1591 bool = l >= 0 - yyj1591++ - if yyhl1591 { - yyb1591 = yyj1591 > l - } else { - yyb1591 = r.CheckBreak() - } - if yyb1591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1591++ - if yyhl1591 { - yyb1591 = yyj1591 > l - } else { - yyb1591 = r.CheckBreak() - } - if yyb1591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj1591++ - if yyhl1591 { - yyb1591 = yyj1591 > l - } else { - yyb1591 = r.CheckBreak() - } - if yyb1591 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1591-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 { - yym1594 := z.EncBinary() - _ = yym1594 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1595 := !z.EncBinary() - yy2arr1595 := z.EncBasicHandle().StructToArray - var yyq1595 [1]bool - _, _, _ = yysep1595, yyq1595, yy2arr1595 - const yyr1595 bool = false - yyq1595[0] = true - var yynn1595 int - if yyr1595 || yy2arr1595 { - r.EncodeArrayStart(1) - } else { - yynn1595 = 0 - for _, b := range yyq1595 { - if b { - yynn1595++ - } - } - r.EncodeMapStart(yynn1595) - yynn1595 = 0 - } - if yyr1595 || yy2arr1595 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1595[0] { - yy1597 := &x.StartedAt - yym1598 := z.EncBinary() - _ = yym1598 - if false { - } else if z.HasExtensions() && z.EncExt(yy1597) { - } else if yym1598 { - z.EncBinaryMarshal(yy1597) - } else if !yym1598 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1597) - } else { - z.EncFallback(yy1597) - } - } else { - r.EncodeNil() - } - } else { - if yyq1595[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1599 := &x.StartedAt - yym1600 := z.EncBinary() - _ = yym1600 - if false { - } else if z.HasExtensions() && z.EncExt(yy1599) { - } else if yym1600 { - z.EncBinaryMarshal(yy1599) - } else if !yym1600 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1599) - } else { - z.EncFallback(yy1599) - } - } - } - if yyr1595 || yy2arr1595 { - 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 - yym1601 := z.DecBinary() - _ = yym1601 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1602 := r.ContainerType() - if yyct1602 == codecSelferValueTypeMap1234 { - yyl1602 := r.ReadMapStart() - if yyl1602 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1602, d) - } - } else if yyct1602 == codecSelferValueTypeArray1234 { - yyl1602 := r.ReadArrayStart() - if yyl1602 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1602, 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 yys1603Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1603Slc - var yyhl1603 bool = l >= 0 - for yyj1603 := 0; ; yyj1603++ { - if yyhl1603 { - if yyj1603 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1603Slc = r.DecodeBytes(yys1603Slc, true, true) - yys1603 := string(yys1603Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1603 { - case "startedAt": - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1604 := &x.StartedAt - yym1605 := z.DecBinary() - _ = yym1605 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1604) { - } else if yym1605 { - z.DecBinaryUnmarshal(yyv1604) - } else if !yym1605 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1604) - } else { - z.DecFallback(yyv1604, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1603) - } // end switch yys1603 - } // end for yyj1603 - 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 yyj1606 int - var yyb1606 bool - var yyhl1606 bool = l >= 0 - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1607 := &x.StartedAt - yym1608 := z.DecBinary() - _ = yym1608 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1607) { - } else if yym1608 { - z.DecBinaryUnmarshal(yyv1607) - } else if !yym1608 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1607) - } else { - z.DecFallback(yyv1607, false) - } - } - for { - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1606-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 { - yym1609 := z.EncBinary() - _ = yym1609 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1610 := !z.EncBinary() - yy2arr1610 := z.EncBasicHandle().StructToArray - var yyq1610 [7]bool - _, _, _ = yysep1610, yyq1610, yy2arr1610 - const yyr1610 bool = false - yyq1610[1] = x.Signal != 0 - yyq1610[2] = x.Reason != "" - yyq1610[3] = x.Message != "" - yyq1610[4] = true - yyq1610[5] = true - yyq1610[6] = x.ContainerID != "" - var yynn1610 int - if yyr1610 || yy2arr1610 { - r.EncodeArrayStart(7) - } else { - yynn1610 = 1 - for _, b := range yyq1610 { - if b { - yynn1610++ - } - } - r.EncodeMapStart(yynn1610) - yynn1610 = 0 - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1612 := z.EncBinary() - _ = yym1612 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exitCode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1613 := z.EncBinary() - _ = yym1613 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[1] { - yym1615 := z.EncBinary() - _ = yym1615 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1610[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("signal")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1616 := z.EncBinary() - _ = yym1616 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[2] { - yym1618 := z.EncBinary() - _ = yym1618 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1610[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1619 := z.EncBinary() - _ = yym1619 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[3] { - yym1621 := z.EncBinary() - _ = yym1621 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1610[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1622 := z.EncBinary() - _ = yym1622 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[4] { - yy1624 := &x.StartedAt - yym1625 := z.EncBinary() - _ = yym1625 - if false { - } else if z.HasExtensions() && z.EncExt(yy1624) { - } else if yym1625 { - z.EncBinaryMarshal(yy1624) - } else if !yym1625 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1624) - } else { - z.EncFallback(yy1624) - } - } else { - r.EncodeNil() - } - } else { - if yyq1610[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1626 := &x.StartedAt - yym1627 := z.EncBinary() - _ = yym1627 - if false { - } else if z.HasExtensions() && z.EncExt(yy1626) { - } else if yym1627 { - z.EncBinaryMarshal(yy1626) - } else if !yym1627 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1626) - } else { - z.EncFallback(yy1626) - } - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[5] { - yy1629 := &x.FinishedAt - yym1630 := z.EncBinary() - _ = yym1630 - if false { - } else if z.HasExtensions() && z.EncExt(yy1629) { - } else if yym1630 { - z.EncBinaryMarshal(yy1629) - } else if !yym1630 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1629) - } else { - z.EncFallback(yy1629) - } - } else { - r.EncodeNil() - } - } else { - if yyq1610[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finishedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1631 := &x.FinishedAt - yym1632 := z.EncBinary() - _ = yym1632 - if false { - } else if z.HasExtensions() && z.EncExt(yy1631) { - } else if yym1632 { - z.EncBinaryMarshal(yy1631) - } else if !yym1632 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1631) - } else { - z.EncFallback(yy1631) - } - } - } - if yyr1610 || yy2arr1610 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1610[6] { - yym1634 := z.EncBinary() - _ = yym1634 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1610[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1635 := z.EncBinary() - _ = yym1635 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } - } - if yyr1610 || yy2arr1610 { - 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 - yym1636 := z.DecBinary() - _ = yym1636 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1637 := r.ContainerType() - if yyct1637 == codecSelferValueTypeMap1234 { - yyl1637 := r.ReadMapStart() - if yyl1637 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1637, d) - } - } else if yyct1637 == codecSelferValueTypeArray1234 { - yyl1637 := r.ReadArrayStart() - if yyl1637 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1637, 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 yys1638Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1638Slc - var yyhl1638 bool = l >= 0 - for yyj1638 := 0; ; yyj1638++ { - if yyhl1638 { - if yyj1638 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1638Slc = r.DecodeBytes(yys1638Slc, true, true) - yys1638 := string(yys1638Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1638 { - 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 { - yyv1643 := &x.StartedAt - yym1644 := z.DecBinary() - _ = yym1644 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1643) { - } else if yym1644 { - z.DecBinaryUnmarshal(yyv1643) - } else if !yym1644 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1643) - } else { - z.DecFallback(yyv1643, false) - } - } - case "finishedAt": - if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} - } else { - yyv1645 := &x.FinishedAt - yym1646 := z.DecBinary() - _ = yym1646 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1645) { - } else if yym1646 { - z.DecBinaryUnmarshal(yyv1645) - } else if !yym1646 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1645) - } else { - z.DecFallback(yyv1645, false) - } - } - case "containerID": - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1638) - } // end switch yys1638 - } // end for yyj1638 - 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 yyj1648 int - var yyb1648 bool - var yyhl1648 bool = l >= 0 - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExitCode = 0 - } else { - x.ExitCode = int32(r.DecodeInt(32)) - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Signal = 0 - } else { - x.Signal = int32(r.DecodeInt(32)) - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1653 := &x.StartedAt - yym1654 := z.DecBinary() - _ = yym1654 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1653) { - } else if yym1654 { - z.DecBinaryUnmarshal(yyv1653) - } else if !yym1654 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1653) - } else { - z.DecFallback(yyv1653, false) - } - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} - } else { - yyv1655 := &x.FinishedAt - yym1656 := z.DecBinary() - _ = yym1656 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1655) { - } else if yym1656 { - z.DecBinaryUnmarshal(yyv1655) - } else if !yym1656 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1655) - } else { - z.DecFallback(yyv1655, false) - } - } - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - for { - yyj1648++ - if yyhl1648 { - yyb1648 = yyj1648 > l - } else { - yyb1648 = r.CheckBreak() - } - if yyb1648 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1648-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 { - yym1658 := z.EncBinary() - _ = yym1658 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1659 := !z.EncBinary() - yy2arr1659 := z.EncBasicHandle().StructToArray - var yyq1659 [3]bool - _, _, _ = yysep1659, yyq1659, yy2arr1659 - const yyr1659 bool = false - yyq1659[0] = x.Waiting != nil - yyq1659[1] = x.Running != nil - yyq1659[2] = x.Terminated != nil - var yynn1659 int - if yyr1659 || yy2arr1659 { - r.EncodeArrayStart(3) - } else { - yynn1659 = 0 - for _, b := range yyq1659 { - if b { - yynn1659++ - } - } - r.EncodeMapStart(yynn1659) - yynn1659 = 0 - } - if yyr1659 || yy2arr1659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1659[0] { - if x.Waiting == nil { - r.EncodeNil() - } else { - x.Waiting.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1659[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 yyr1659 || yy2arr1659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1659[1] { - if x.Running == nil { - r.EncodeNil() - } else { - x.Running.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1659[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 yyr1659 || yy2arr1659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1659[2] { - if x.Terminated == nil { - r.EncodeNil() - } else { - x.Terminated.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1659[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 yyr1659 || yy2arr1659 { - 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 - yym1663 := z.DecBinary() - _ = yym1663 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1664 := r.ContainerType() - if yyct1664 == codecSelferValueTypeMap1234 { - yyl1664 := r.ReadMapStart() - if yyl1664 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1664, d) - } - } else if yyct1664 == codecSelferValueTypeArray1234 { - yyl1664 := r.ReadArrayStart() - if yyl1664 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1664, 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 yys1665Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1665Slc - var yyhl1665 bool = l >= 0 - for yyj1665 := 0; ; yyj1665++ { - if yyhl1665 { - if yyj1665 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1665Slc = r.DecodeBytes(yys1665Slc, true, true) - yys1665 := string(yys1665Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1665 { - 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, yys1665) - } // end switch yys1665 - } // end for yyj1665 - 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 yyj1669 int - var yyb1669 bool - var yyhl1669 bool = l >= 0 - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l - } else { - yyb1669 = r.CheckBreak() - } - if yyb1669 { - 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) - } - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l - } else { - yyb1669 = r.CheckBreak() - } - if yyb1669 { - 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) - } - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l - } else { - yyb1669 = r.CheckBreak() - } - if yyb1669 { - 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 { - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l - } else { - yyb1669 = r.CheckBreak() - } - if yyb1669 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1669-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 { - yym1673 := z.EncBinary() - _ = yym1673 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1674 := !z.EncBinary() - yy2arr1674 := z.EncBasicHandle().StructToArray - var yyq1674 [8]bool - _, _, _ = yysep1674, yyq1674, yy2arr1674 - const yyr1674 bool = false - yyq1674[1] = true - yyq1674[2] = true - yyq1674[7] = x.ContainerID != "" - var yynn1674 int - if yyr1674 || yy2arr1674 { - r.EncodeArrayStart(8) - } else { - yynn1674 = 5 - for _, b := range yyq1674 { - if b { - yynn1674++ - } - } - r.EncodeMapStart(yynn1674) - yynn1674 = 0 - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1676 := z.EncBinary() - _ = yym1676 - 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) - yym1677 := z.EncBinary() - _ = yym1677 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1674[1] { - yy1679 := &x.State - yy1679.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1674[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("state")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1680 := &x.State - yy1680.CodecEncodeSelf(e) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1674[2] { - yy1682 := &x.LastTerminationState - yy1682.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1674[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastState")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1683 := &x.LastTerminationState - yy1683.CodecEncodeSelf(e) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1685 := z.EncBinary() - _ = yym1685 - if false { - } else { - r.EncodeBool(bool(x.Ready)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ready")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1686 := z.EncBinary() - _ = yym1686 - if false { - } else { - r.EncodeBool(bool(x.Ready)) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1688 := z.EncBinary() - _ = yym1688 - if false { - } else { - r.EncodeInt(int64(x.RestartCount)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("restartCount")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1689 := z.EncBinary() - _ = yym1689 - if false { - } else { - r.EncodeInt(int64(x.RestartCount)) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1691 := z.EncBinary() - _ = yym1691 - 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) - yym1692 := z.EncBinary() - _ = yym1692 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1694 := z.EncBinary() - _ = yym1694 - 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) - yym1695 := z.EncBinary() - _ = yym1695 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ImageID)) - } - } - if yyr1674 || yy2arr1674 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1674[7] { - yym1697 := z.EncBinary() - _ = yym1697 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1674[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1698 := z.EncBinary() - _ = yym1698 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } - } - if yyr1674 || yy2arr1674 { - 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 - yym1699 := z.DecBinary() - _ = yym1699 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1700 := r.ContainerType() - if yyct1700 == codecSelferValueTypeMap1234 { - yyl1700 := r.ReadMapStart() - if yyl1700 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1700, d) - } - } else if yyct1700 == codecSelferValueTypeArray1234 { - yyl1700 := r.ReadArrayStart() - if yyl1700 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1700, 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 yys1701Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1701Slc - var yyhl1701 bool = l >= 0 - for yyj1701 := 0; ; yyj1701++ { - if yyhl1701 { - if yyj1701 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1701Slc = r.DecodeBytes(yys1701Slc, true, true) - yys1701 := string(yys1701Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1701 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "state": - if r.TryDecodeAsNil() { - x.State = ContainerState{} - } else { - yyv1703 := &x.State - yyv1703.CodecDecodeSelf(d) - } - case "lastState": - if r.TryDecodeAsNil() { - x.LastTerminationState = ContainerState{} - } else { - yyv1704 := &x.LastTerminationState - yyv1704.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, yys1701) - } // end switch yys1701 - } // end for yyj1701 - 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 yyj1710 int - var yyb1710 bool - var yyhl1710 bool = l >= 0 - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.State = ContainerState{} - } else { - yyv1712 := &x.State - yyv1712.CodecDecodeSelf(d) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTerminationState = ContainerState{} - } else { - yyv1713 := &x.LastTerminationState - yyv1713.CodecDecodeSelf(d) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ready = false - } else { - x.Ready = bool(r.DecodeBool()) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RestartCount = 0 - } else { - x.RestartCount = int32(r.DecodeInt(32)) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Image = "" - } else { - x.Image = string(r.DecodeString()) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImageID = "" - } else { - x.ImageID = string(r.DecodeString()) - } - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - for { - yyj1710++ - if yyhl1710 { - yyb1710 = yyj1710 > l - } else { - yyb1710 = r.CheckBreak() - } - if yyb1710 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1710-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PodPhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1719 := z.EncBinary() - _ = yym1719 - 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 - yym1720 := z.DecBinary() - _ = yym1720 - 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 - yym1721 := z.EncBinary() - _ = yym1721 - 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 - yym1722 := z.DecBinary() - _ = yym1722 - 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 { - yym1723 := z.EncBinary() - _ = yym1723 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1724 := !z.EncBinary() - yy2arr1724 := z.EncBasicHandle().StructToArray - var yyq1724 [6]bool - _, _, _ = yysep1724, yyq1724, yy2arr1724 - const yyr1724 bool = false - yyq1724[2] = true - yyq1724[3] = true - yyq1724[4] = x.Reason != "" - yyq1724[5] = x.Message != "" - var yynn1724 int - if yyr1724 || yy2arr1724 { - r.EncodeArrayStart(6) - } else { - yynn1724 = 2 - for _, b := range yyq1724 { - if b { - yynn1724++ - } - } - r.EncodeMapStart(yynn1724) - yynn1724 = 0 - } - if yyr1724 || yy2arr1724 { - 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 yyr1724 || yy2arr1724 { - 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 yyr1724 || yy2arr1724 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1724[2] { - yy1728 := &x.LastProbeTime - yym1729 := z.EncBinary() - _ = yym1729 - if false { - } else if z.HasExtensions() && z.EncExt(yy1728) { - } else if yym1729 { - z.EncBinaryMarshal(yy1728) - } else if !yym1729 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1728) - } else { - z.EncFallback(yy1728) - } - } else { - r.EncodeNil() - } - } else { - if yyq1724[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1730 := &x.LastProbeTime - yym1731 := z.EncBinary() - _ = yym1731 - if false { - } else if z.HasExtensions() && z.EncExt(yy1730) { - } else if yym1731 { - z.EncBinaryMarshal(yy1730) - } else if !yym1731 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1730) - } else { - z.EncFallback(yy1730) - } - } - } - if yyr1724 || yy2arr1724 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1724[3] { - yy1733 := &x.LastTransitionTime - yym1734 := z.EncBinary() - _ = yym1734 - if false { - } else if z.HasExtensions() && z.EncExt(yy1733) { - } else if yym1734 { - z.EncBinaryMarshal(yy1733) - } else if !yym1734 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1733) - } else { - z.EncFallback(yy1733) - } - } else { - r.EncodeNil() - } - } else { - if yyq1724[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1735 := &x.LastTransitionTime - yym1736 := z.EncBinary() - _ = yym1736 - if false { - } else if z.HasExtensions() && z.EncExt(yy1735) { - } else if yym1736 { - z.EncBinaryMarshal(yy1735) - } else if !yym1736 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1735) - } else { - z.EncFallback(yy1735) - } - } - } - if yyr1724 || yy2arr1724 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1724[4] { - yym1738 := z.EncBinary() - _ = yym1738 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1724[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1739 := z.EncBinary() - _ = yym1739 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1724 || yy2arr1724 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1724[5] { - yym1741 := z.EncBinary() - _ = yym1741 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1724[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1742 := z.EncBinary() - _ = yym1742 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1724 || yy2arr1724 { - 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 - yym1743 := z.DecBinary() - _ = yym1743 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1744 := r.ContainerType() - if yyct1744 == codecSelferValueTypeMap1234 { - yyl1744 := r.ReadMapStart() - if yyl1744 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1744, d) - } - } else if yyct1744 == codecSelferValueTypeArray1234 { - yyl1744 := r.ReadArrayStart() - if yyl1744 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1744, 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 yys1745Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1745Slc - var yyhl1745 bool = l >= 0 - for yyj1745 := 0; ; yyj1745++ { - if yyhl1745 { - if yyj1745 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1745Slc = r.DecodeBytes(yys1745Slc, true, true) - yys1745 := string(yys1745Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1745 { - 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 { - yyv1748 := &x.LastProbeTime - yym1749 := z.DecBinary() - _ = yym1749 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1748) { - } else if yym1749 { - z.DecBinaryUnmarshal(yyv1748) - } else if !yym1749 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1748) - } else { - z.DecFallback(yyv1748, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv1750 := &x.LastTransitionTime - yym1751 := z.DecBinary() - _ = yym1751 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1750) { - } else if yym1751 { - z.DecBinaryUnmarshal(yyv1750) - } else if !yym1751 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1750) - } else { - z.DecFallback(yyv1750, 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, yys1745) - } // end switch yys1745 - } // end for yyj1745 - 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 yyj1754 int - var yyb1754 bool - var yyhl1754 bool = l >= 0 - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = PodConditionType(r.DecodeString()) - } - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg2_unversioned.Time{} - } else { - yyv1757 := &x.LastProbeTime - yym1758 := z.DecBinary() - _ = yym1758 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1757) { - } else if yym1758 { - z.DecBinaryUnmarshal(yyv1757) - } else if !yym1758 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1757) - } else { - z.DecFallback(yyv1757, false) - } - } - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv1759 := &x.LastTransitionTime - yym1760 := z.DecBinary() - _ = yym1760 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1759) { - } else if yym1760 { - z.DecBinaryUnmarshal(yyv1759) - } else if !yym1760 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1759) - } else { - z.DecFallback(yyv1759, false) - } - } - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj1754++ - if yyhl1754 { - yyb1754 = yyj1754 > l - } else { - yyb1754 = r.CheckBreak() - } - if yyb1754 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1754-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1763 := z.EncBinary() - _ = yym1763 - 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 - yym1764 := z.DecBinary() - _ = yym1764 - 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 - yym1765 := z.EncBinary() - _ = yym1765 - 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 - yym1766 := z.DecBinary() - _ = yym1766 - 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 { - yym1767 := z.EncBinary() - _ = yym1767 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1768 := !z.EncBinary() - yy2arr1768 := z.EncBasicHandle().StructToArray - var yyq1768 [1]bool - _, _, _ = yysep1768, yyq1768, yy2arr1768 - const yyr1768 bool = false - var yynn1768 int - if yyr1768 || yy2arr1768 { - r.EncodeArrayStart(1) - } else { - yynn1768 = 1 - for _, b := range yyq1768 { - if b { - yynn1768++ - } - } - r.EncodeMapStart(yynn1768) - yynn1768 = 0 - } - if yyr1768 || yy2arr1768 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.NodeSelectorTerms == nil { - r.EncodeNil() - } else { - yym1770 := z.EncBinary() - _ = yym1770 - 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 { - yym1771 := z.EncBinary() - _ = yym1771 - if false { - } else { - h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e) - } - } - } - if yyr1768 || yy2arr1768 { - 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 - yym1772 := z.DecBinary() - _ = yym1772 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1773 := r.ContainerType() - if yyct1773 == codecSelferValueTypeMap1234 { - yyl1773 := r.ReadMapStart() - if yyl1773 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1773, d) - } - } else if yyct1773 == codecSelferValueTypeArray1234 { - yyl1773 := r.ReadArrayStart() - if yyl1773 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1773, 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 yys1774Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1774Slc - var yyhl1774 bool = l >= 0 - for yyj1774 := 0; ; yyj1774++ { - if yyhl1774 { - if yyj1774 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1774Slc = r.DecodeBytes(yys1774Slc, true, true) - yys1774 := string(yys1774Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1774 { - case "nodeSelectorTerms": - if r.TryDecodeAsNil() { - x.NodeSelectorTerms = nil - } else { - yyv1775 := &x.NodeSelectorTerms - yym1776 := z.DecBinary() - _ = yym1776 - if false { - } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1775), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1774) - } // end switch yys1774 - } // end for yyj1774 - 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 yyj1777 int - var yyb1777 bool - var yyhl1777 bool = l >= 0 - yyj1777++ - if yyhl1777 { - yyb1777 = yyj1777 > l - } else { - yyb1777 = r.CheckBreak() - } - if yyb1777 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeSelectorTerms = nil - } else { - yyv1778 := &x.NodeSelectorTerms - yym1779 := z.DecBinary() - _ = yym1779 - if false { - } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1778), d) - } - } - for { - yyj1777++ - if yyhl1777 { - yyb1777 = yyj1777 > l - } else { - yyb1777 = r.CheckBreak() - } - if yyb1777 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1777-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 { - yym1780 := z.EncBinary() - _ = yym1780 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1781 := !z.EncBinary() - yy2arr1781 := z.EncBasicHandle().StructToArray - var yyq1781 [1]bool - _, _, _ = yysep1781, yyq1781, yy2arr1781 - const yyr1781 bool = false - var yynn1781 int - if yyr1781 || yy2arr1781 { - r.EncodeArrayStart(1) - } else { - yynn1781 = 1 - for _, b := range yyq1781 { - if b { - yynn1781++ - } - } - r.EncodeMapStart(yynn1781) - yynn1781 = 0 - } - if yyr1781 || yy2arr1781 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.MatchExpressions == nil { - r.EncodeNil() - } else { - yym1783 := z.EncBinary() - _ = yym1783 - 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 { - yym1784 := z.EncBinary() - _ = yym1784 - if false { - } else { - h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e) - } - } - } - if yyr1781 || yy2arr1781 { - 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 - yym1785 := z.DecBinary() - _ = yym1785 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1786 := r.ContainerType() - if yyct1786 == codecSelferValueTypeMap1234 { - yyl1786 := r.ReadMapStart() - if yyl1786 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1786, d) - } - } else if yyct1786 == codecSelferValueTypeArray1234 { - yyl1786 := r.ReadArrayStart() - if yyl1786 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1786, 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 yys1787Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1787Slc - var yyhl1787 bool = l >= 0 - for yyj1787 := 0; ; yyj1787++ { - if yyhl1787 { - if yyj1787 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1787Slc = r.DecodeBytes(yys1787Slc, true, true) - yys1787 := string(yys1787Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1787 { - case "matchExpressions": - if r.TryDecodeAsNil() { - x.MatchExpressions = nil - } else { - yyv1788 := &x.MatchExpressions - yym1789 := z.DecBinary() - _ = yym1789 - if false { - } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1788), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1787) - } // end switch yys1787 - } // end for yyj1787 - 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 yyj1790 int - var yyb1790 bool - var yyhl1790 bool = l >= 0 - yyj1790++ - if yyhl1790 { - yyb1790 = yyj1790 > l - } else { - yyb1790 = r.CheckBreak() - } - if yyb1790 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MatchExpressions = nil - } else { - yyv1791 := &x.MatchExpressions - yym1792 := z.DecBinary() - _ = yym1792 - if false { - } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1791), d) - } - } - for { - yyj1790++ - if yyhl1790 { - yyb1790 = yyj1790 > l - } else { - yyb1790 = r.CheckBreak() - } - if yyb1790 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1790-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 { - yym1793 := z.EncBinary() - _ = yym1793 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1794 := !z.EncBinary() - yy2arr1794 := z.EncBasicHandle().StructToArray - var yyq1794 [3]bool - _, _, _ = yysep1794, yyq1794, yy2arr1794 - const yyr1794 bool = false - yyq1794[2] = len(x.Values) != 0 - var yynn1794 int - if yyr1794 || yy2arr1794 { - r.EncodeArrayStart(3) - } else { - yynn1794 = 2 - for _, b := range yyq1794 { - if b { - yynn1794++ - } - } - r.EncodeMapStart(yynn1794) - yynn1794 = 0 - } - if yyr1794 || yy2arr1794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1796 := z.EncBinary() - _ = yym1796 - 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) - yym1797 := z.EncBinary() - _ = yym1797 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1794 || yy2arr1794 { - 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 yyr1794 || yy2arr1794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1794[2] { - if x.Values == nil { - r.EncodeNil() - } else { - yym1800 := z.EncBinary() - _ = yym1800 - if false { - } else { - z.F.EncSliceStringV(x.Values, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1794[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("values")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Values == nil { - r.EncodeNil() - } else { - yym1801 := z.EncBinary() - _ = yym1801 - if false { - } else { - z.F.EncSliceStringV(x.Values, false, e) - } - } - } - } - if yyr1794 || yy2arr1794 { - 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 - yym1802 := z.DecBinary() - _ = yym1802 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1803 := r.ContainerType() - if yyct1803 == codecSelferValueTypeMap1234 { - yyl1803 := r.ReadMapStart() - if yyl1803 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1803, d) - } - } else if yyct1803 == codecSelferValueTypeArray1234 { - yyl1803 := r.ReadArrayStart() - if yyl1803 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1803, 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 yys1804Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1804Slc - var yyhl1804 bool = l >= 0 - for yyj1804 := 0; ; yyj1804++ { - if yyhl1804 { - if yyj1804 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1804Slc = r.DecodeBytes(yys1804Slc, true, true) - yys1804 := string(yys1804Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1804 { - 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 { - yyv1807 := &x.Values - yym1808 := z.DecBinary() - _ = yym1808 - if false { - } else { - z.F.DecSliceStringX(yyv1807, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1804) - } // end switch yys1804 - } // end for yyj1804 - 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 yyj1809 int - var yyb1809 bool - var yyhl1809 bool = l >= 0 - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l - } else { - yyb1809 = r.CheckBreak() - } - if yyb1809 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l - } else { - yyb1809 = r.CheckBreak() - } - if yyb1809 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Operator = "" - } else { - x.Operator = NodeSelectorOperator(r.DecodeString()) - } - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l - } else { - yyb1809 = r.CheckBreak() - } - if yyb1809 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Values = nil - } else { - yyv1812 := &x.Values - yym1813 := z.DecBinary() - _ = yym1813 - if false { - } else { - z.F.DecSliceStringX(yyv1812, false, d) - } - } - for { - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l - } else { - yyb1809 = r.CheckBreak() - } - if yyb1809 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1809-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodeSelectorOperator) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1814 := z.EncBinary() - _ = yym1814 - 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 - yym1815 := z.DecBinary() - _ = yym1815 - 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 { - yym1816 := z.EncBinary() - _ = yym1816 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1817 := !z.EncBinary() - yy2arr1817 := z.EncBasicHandle().StructToArray - var yyq1817 [3]bool - _, _, _ = yysep1817, yyq1817, yy2arr1817 - const yyr1817 bool = false - yyq1817[0] = x.NodeAffinity != nil - yyq1817[1] = x.PodAffinity != nil - yyq1817[2] = x.PodAntiAffinity != nil - var yynn1817 int - if yyr1817 || yy2arr1817 { - r.EncodeArrayStart(3) - } else { - yynn1817 = 0 - for _, b := range yyq1817 { - if b { - yynn1817++ - } - } - r.EncodeMapStart(yynn1817) - yynn1817 = 0 - } - if yyr1817 || yy2arr1817 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1817[0] { - if x.NodeAffinity == nil { - r.EncodeNil() - } else { - x.NodeAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1817[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 yyr1817 || yy2arr1817 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1817[1] { - if x.PodAffinity == nil { - r.EncodeNil() - } else { - x.PodAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1817[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 yyr1817 || yy2arr1817 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1817[2] { - if x.PodAntiAffinity == nil { - r.EncodeNil() - } else { - x.PodAntiAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1817[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 yyr1817 || yy2arr1817 { - 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 - yym1821 := z.DecBinary() - _ = yym1821 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1822 := r.ContainerType() - if yyct1822 == codecSelferValueTypeMap1234 { - yyl1822 := r.ReadMapStart() - if yyl1822 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1822, d) - } - } else if yyct1822 == codecSelferValueTypeArray1234 { - yyl1822 := r.ReadArrayStart() - if yyl1822 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1822, 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 yys1823Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1823Slc - var yyhl1823 bool = l >= 0 - for yyj1823 := 0; ; yyj1823++ { - if yyhl1823 { - if yyj1823 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1823Slc = r.DecodeBytes(yys1823Slc, true, true) - yys1823 := string(yys1823Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1823 { - 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, yys1823) - } // end switch yys1823 - } // end for yyj1823 - 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 yyj1827 int - var yyb1827 bool - var yyhl1827 bool = l >= 0 - yyj1827++ - if yyhl1827 { - yyb1827 = yyj1827 > l - } else { - yyb1827 = r.CheckBreak() - } - if yyb1827 { - 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) - } - yyj1827++ - if yyhl1827 { - yyb1827 = yyj1827 > l - } else { - yyb1827 = r.CheckBreak() - } - if yyb1827 { - 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) - } - yyj1827++ - if yyhl1827 { - yyb1827 = yyj1827 > l - } else { - yyb1827 = r.CheckBreak() - } - if yyb1827 { - 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 { - yyj1827++ - if yyhl1827 { - yyb1827 = yyj1827 > l - } else { - yyb1827 = r.CheckBreak() - } - if yyb1827 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1827-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 { - yym1831 := z.EncBinary() - _ = yym1831 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1832 := !z.EncBinary() - yy2arr1832 := z.EncBasicHandle().StructToArray - var yyq1832 [2]bool - _, _, _ = yysep1832, yyq1832, yy2arr1832 - const yyr1832 bool = false - yyq1832[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1832[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1832 int - if yyr1832 || yy2arr1832 { - r.EncodeArrayStart(2) - } else { - yynn1832 = 0 - for _, b := range yyq1832 { - if b { - yynn1832++ - } - } - r.EncodeMapStart(yynn1832) - yynn1832 = 0 - } - if yyr1832 || yy2arr1832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1832[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1834 := z.EncBinary() - _ = yym1834 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1832[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1835 := z.EncBinary() - _ = yym1835 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1832 || yy2arr1832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1832[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1837 := z.EncBinary() - _ = yym1837 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1832[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1838 := z.EncBinary() - _ = yym1838 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1832 || yy2arr1832 { - 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 - yym1839 := z.DecBinary() - _ = yym1839 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1840 := r.ContainerType() - if yyct1840 == codecSelferValueTypeMap1234 { - yyl1840 := r.ReadMapStart() - if yyl1840 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1840, d) - } - } else if yyct1840 == codecSelferValueTypeArray1234 { - yyl1840 := r.ReadArrayStart() - if yyl1840 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1840, 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 yys1841Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1841Slc - var yyhl1841 bool = l >= 0 - for yyj1841 := 0; ; yyj1841++ { - if yyhl1841 { - if yyj1841 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1841Slc = r.DecodeBytes(yys1841Slc, true, true) - yys1841 := string(yys1841Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1841 { - case "requiredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1842 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1843 := z.DecBinary() - _ = yym1843 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1842), d) - } - } - case "preferredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1844 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1845 := z.DecBinary() - _ = yym1845 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1844), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1841) - } // end switch yys1841 - } // end for yyj1841 - 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 yyj1846 int - var yyb1846 bool - var yyhl1846 bool = l >= 0 - yyj1846++ - if yyhl1846 { - yyb1846 = yyj1846 > l - } else { - yyb1846 = r.CheckBreak() - } - if yyb1846 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1847 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1848 := z.DecBinary() - _ = yym1848 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1847), d) - } - } - yyj1846++ - if yyhl1846 { - yyb1846 = yyj1846 > l - } else { - yyb1846 = r.CheckBreak() - } - if yyb1846 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1849 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1850 := z.DecBinary() - _ = yym1850 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1849), d) - } - } - for { - yyj1846++ - if yyhl1846 { - yyb1846 = yyj1846 > l - } else { - yyb1846 = r.CheckBreak() - } - if yyb1846 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1846-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 { - yym1851 := z.EncBinary() - _ = yym1851 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1852 := !z.EncBinary() - yy2arr1852 := z.EncBasicHandle().StructToArray - var yyq1852 [2]bool - _, _, _ = yysep1852, yyq1852, yy2arr1852 - const yyr1852 bool = false - yyq1852[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1852[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1852 int - if yyr1852 || yy2arr1852 { - r.EncodeArrayStart(2) - } else { - yynn1852 = 0 - for _, b := range yyq1852 { - if b { - yynn1852++ - } - } - r.EncodeMapStart(yynn1852) - yynn1852 = 0 - } - if yyr1852 || yy2arr1852 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1852[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1854 := z.EncBinary() - _ = yym1854 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1852[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1855 := z.EncBinary() - _ = yym1855 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1852 || yy2arr1852 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1852[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1857 := z.EncBinary() - _ = yym1857 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1852[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1858 := z.EncBinary() - _ = yym1858 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1852 || yy2arr1852 { - 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 - yym1859 := z.DecBinary() - _ = yym1859 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1860 := r.ContainerType() - if yyct1860 == codecSelferValueTypeMap1234 { - yyl1860 := r.ReadMapStart() - if yyl1860 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1860, d) - } - } else if yyct1860 == codecSelferValueTypeArray1234 { - yyl1860 := r.ReadArrayStart() - if yyl1860 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1860, 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 yys1861Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1861Slc - var yyhl1861 bool = l >= 0 - for yyj1861 := 0; ; yyj1861++ { - if yyhl1861 { - if yyj1861 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1861Slc = r.DecodeBytes(yys1861Slc, true, true) - yys1861 := string(yys1861Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1861 { - case "requiredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1862 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1863 := z.DecBinary() - _ = yym1863 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1862), d) - } - } - case "preferredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1864 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1865 := z.DecBinary() - _ = yym1865 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1864), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1861) - } // end switch yys1861 - } // end for yyj1861 - 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 yyj1866 int - var yyb1866 bool - var yyhl1866 bool = l >= 0 - yyj1866++ - if yyhl1866 { - yyb1866 = yyj1866 > l - } else { - yyb1866 = r.CheckBreak() - } - if yyb1866 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1867 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1868 := z.DecBinary() - _ = yym1868 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1867), d) - } - } - yyj1866++ - if yyhl1866 { - yyb1866 = yyj1866 > l - } else { - yyb1866 = r.CheckBreak() - } - if yyb1866 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1869 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1870 := z.DecBinary() - _ = yym1870 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1869), d) - } - } - for { - yyj1866++ - if yyhl1866 { - yyb1866 = yyj1866 > l - } else { - yyb1866 = r.CheckBreak() - } - if yyb1866 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1866-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 { - yym1871 := z.EncBinary() - _ = yym1871 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1872 := !z.EncBinary() - yy2arr1872 := z.EncBasicHandle().StructToArray - var yyq1872 [2]bool - _, _, _ = yysep1872, yyq1872, yy2arr1872 - const yyr1872 bool = false - var yynn1872 int - if yyr1872 || yy2arr1872 { - r.EncodeArrayStart(2) - } else { - yynn1872 = 2 - for _, b := range yyq1872 { - if b { - yynn1872++ - } - } - r.EncodeMapStart(yynn1872) - yynn1872 = 0 - } - if yyr1872 || yy2arr1872 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1874 := z.EncBinary() - _ = yym1874 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("weight")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1875 := z.EncBinary() - _ = yym1875 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } - if yyr1872 || yy2arr1872 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1877 := &x.PodAffinityTerm - yy1877.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podAffinityTerm")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1878 := &x.PodAffinityTerm - yy1878.CodecEncodeSelf(e) - } - if yyr1872 || yy2arr1872 { - 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 - yym1879 := z.DecBinary() - _ = yym1879 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1880 := r.ContainerType() - if yyct1880 == codecSelferValueTypeMap1234 { - yyl1880 := r.ReadMapStart() - if yyl1880 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1880, d) - } - } else if yyct1880 == codecSelferValueTypeArray1234 { - yyl1880 := r.ReadArrayStart() - if yyl1880 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1880, 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 yys1881Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1881Slc - var yyhl1881 bool = l >= 0 - for yyj1881 := 0; ; yyj1881++ { - if yyhl1881 { - if yyj1881 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1881Slc = r.DecodeBytes(yys1881Slc, true, true) - yys1881 := string(yys1881Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1881 { - case "weight": - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - case "podAffinityTerm": - if r.TryDecodeAsNil() { - x.PodAffinityTerm = PodAffinityTerm{} - } else { - yyv1883 := &x.PodAffinityTerm - yyv1883.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1881) - } // end switch yys1881 - } // end for yyj1881 - 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 yyj1884 int - var yyb1884 bool - var yyhl1884 bool = l >= 0 - yyj1884++ - if yyhl1884 { - yyb1884 = yyj1884 > l - } else { - yyb1884 = r.CheckBreak() - } - if yyb1884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - yyj1884++ - if yyhl1884 { - yyb1884 = yyj1884 > l - } else { - yyb1884 = r.CheckBreak() - } - if yyb1884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodAffinityTerm = PodAffinityTerm{} - } else { - yyv1886 := &x.PodAffinityTerm - yyv1886.CodecDecodeSelf(d) - } - for { - yyj1884++ - if yyhl1884 { - yyb1884 = yyj1884 > l - } else { - yyb1884 = r.CheckBreak() - } - if yyb1884 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1884-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 { - yym1887 := z.EncBinary() - _ = yym1887 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1888 := !z.EncBinary() - yy2arr1888 := z.EncBasicHandle().StructToArray - var yyq1888 [3]bool - _, _, _ = yysep1888, yyq1888, yy2arr1888 - const yyr1888 bool = false - yyq1888[0] = x.LabelSelector != nil - yyq1888[2] = x.TopologyKey != "" - var yynn1888 int - if yyr1888 || yy2arr1888 { - r.EncodeArrayStart(3) - } else { - yynn1888 = 1 - for _, b := range yyq1888 { - if b { - yynn1888++ - } - } - r.EncodeMapStart(yynn1888) - yynn1888 = 0 - } - if yyr1888 || yy2arr1888 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1888[0] { - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym1890 := z.EncBinary() - _ = yym1890 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1888[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labelSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym1891 := z.EncBinary() - _ = yym1891 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } - } - if yyr1888 || yy2arr1888 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Namespaces == nil { - r.EncodeNil() - } else { - yym1893 := z.EncBinary() - _ = yym1893 - 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 { - yym1894 := z.EncBinary() - _ = yym1894 - if false { - } else { - z.F.EncSliceStringV(x.Namespaces, false, e) - } - } - } - if yyr1888 || yy2arr1888 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1888[2] { - yym1896 := z.EncBinary() - _ = yym1896 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1888[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("topologyKey")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1897 := z.EncBinary() - _ = yym1897 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) - } - } - } - if yyr1888 || yy2arr1888 { - 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 - yym1898 := z.DecBinary() - _ = yym1898 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1899 := r.ContainerType() - if yyct1899 == codecSelferValueTypeMap1234 { - yyl1899 := r.ReadMapStart() - if yyl1899 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1899, d) - } - } else if yyct1899 == codecSelferValueTypeArray1234 { - yyl1899 := r.ReadArrayStart() - if yyl1899 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1899, 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 yys1900Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1900Slc - var yyhl1900 bool = l >= 0 - for yyj1900 := 0; ; yyj1900++ { - if yyhl1900 { - if yyj1900 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1900Slc = r.DecodeBytes(yys1900Slc, true, true) - yys1900 := string(yys1900Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1900 { - case "labelSelector": - if r.TryDecodeAsNil() { - if x.LabelSelector != nil { - x.LabelSelector = nil - } - } else { - if x.LabelSelector == nil { - x.LabelSelector = new(pkg2_unversioned.LabelSelector) - } - yym1902 := z.DecBinary() - _ = yym1902 - 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 { - yyv1903 := &x.Namespaces - yym1904 := z.DecBinary() - _ = yym1904 - if false { - } else { - z.F.DecSliceStringX(yyv1903, false, d) - } - } - case "topologyKey": - if r.TryDecodeAsNil() { - x.TopologyKey = "" - } else { - x.TopologyKey = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1900) - } // end switch yys1900 - } // end for yyj1900 - 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 yyj1906 int - var yyb1906 bool - var yyhl1906 bool = l >= 0 - yyj1906++ - if yyhl1906 { - yyb1906 = yyj1906 > l - } else { - yyb1906 = r.CheckBreak() - } - if yyb1906 { - 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) - } - yym1908 := z.DecBinary() - _ = yym1908 - if false { - } else if z.HasExtensions() && z.DecExt(x.LabelSelector) { - } else { - z.DecFallback(x.LabelSelector, false) - } - } - yyj1906++ - if yyhl1906 { - yyb1906 = yyj1906 > l - } else { - yyb1906 = r.CheckBreak() - } - if yyb1906 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespaces = nil - } else { - yyv1909 := &x.Namespaces - yym1910 := z.DecBinary() - _ = yym1910 - if false { - } else { - z.F.DecSliceStringX(yyv1909, false, d) - } - } - yyj1906++ - if yyhl1906 { - yyb1906 = yyj1906 > l - } else { - yyb1906 = r.CheckBreak() - } - if yyb1906 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TopologyKey = "" - } else { - x.TopologyKey = string(r.DecodeString()) - } - for { - yyj1906++ - if yyhl1906 { - yyb1906 = yyj1906 > l - } else { - yyb1906 = r.CheckBreak() - } - if yyb1906 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1906-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 { - yym1912 := z.EncBinary() - _ = yym1912 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1913 := !z.EncBinary() - yy2arr1913 := z.EncBasicHandle().StructToArray - var yyq1913 [2]bool - _, _, _ = yysep1913, yyq1913, yy2arr1913 - const yyr1913 bool = false - yyq1913[0] = x.RequiredDuringSchedulingIgnoredDuringExecution != nil - yyq1913[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1913 int - if yyr1913 || yy2arr1913 { - r.EncodeArrayStart(2) - } else { - yynn1913 = 0 - for _, b := range yyq1913 { - if b { - yynn1913++ - } - } - r.EncodeMapStart(yynn1913) - yynn1913 = 0 - } - if yyr1913 || yy2arr1913 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1913[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - x.RequiredDuringSchedulingIgnoredDuringExecution.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1913[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 yyr1913 || yy2arr1913 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1913[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1916 := z.EncBinary() - _ = yym1916 - if false { - } else { - h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1913[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1917 := z.EncBinary() - _ = yym1917 - if false { - } else { - h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1913 || yy2arr1913 { - 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 - yym1918 := z.DecBinary() - _ = yym1918 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1919 := r.ContainerType() - if yyct1919 == codecSelferValueTypeMap1234 { - yyl1919 := r.ReadMapStart() - if yyl1919 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1919, d) - } - } else if yyct1919 == codecSelferValueTypeArray1234 { - yyl1919 := r.ReadArrayStart() - if yyl1919 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1919, 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 yys1920Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1920Slc - var yyhl1920 bool = l >= 0 - for yyj1920 := 0; ; yyj1920++ { - if yyhl1920 { - if yyj1920 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1920Slc = r.DecodeBytes(yys1920Slc, true, true) - yys1920 := string(yys1920Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1920 { - 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 { - yyv1922 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1923 := z.DecBinary() - _ = yym1923 - if false { - } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv1922), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1920) - } // end switch yys1920 - } // end for yyj1920 - 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 yyj1924 int - var yyb1924 bool - var yyhl1924 bool = l >= 0 - yyj1924++ - if yyhl1924 { - yyb1924 = yyj1924 > l - } else { - yyb1924 = r.CheckBreak() - } - if yyb1924 { - 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) - } - yyj1924++ - if yyhl1924 { - yyb1924 = yyj1924 > l - } else { - yyb1924 = r.CheckBreak() - } - if yyb1924 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1926 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1927 := z.DecBinary() - _ = yym1927 - if false { - } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv1926), d) - } - } - for { - yyj1924++ - if yyhl1924 { - yyb1924 = yyj1924 > l - } else { - yyb1924 = r.CheckBreak() - } - if yyb1924 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1924-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 { - yym1928 := z.EncBinary() - _ = yym1928 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1929 := !z.EncBinary() - yy2arr1929 := z.EncBasicHandle().StructToArray - var yyq1929 [2]bool - _, _, _ = yysep1929, yyq1929, yy2arr1929 - const yyr1929 bool = false - var yynn1929 int - if yyr1929 || yy2arr1929 { - r.EncodeArrayStart(2) - } else { - yynn1929 = 2 - for _, b := range yyq1929 { - if b { - yynn1929++ - } - } - r.EncodeMapStart(yynn1929) - yynn1929 = 0 - } - if yyr1929 || yy2arr1929 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1931 := z.EncBinary() - _ = yym1931 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("weight")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1932 := z.EncBinary() - _ = yym1932 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } - if yyr1929 || yy2arr1929 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1934 := &x.Preference - yy1934.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preference")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1935 := &x.Preference - yy1935.CodecEncodeSelf(e) - } - if yyr1929 || yy2arr1929 { - 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 - yym1936 := z.DecBinary() - _ = yym1936 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1937 := r.ContainerType() - if yyct1937 == codecSelferValueTypeMap1234 { - yyl1937 := r.ReadMapStart() - if yyl1937 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1937, d) - } - } else if yyct1937 == codecSelferValueTypeArray1234 { - yyl1937 := r.ReadArrayStart() - if yyl1937 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1937, 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 yys1938Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1938Slc - var yyhl1938 bool = l >= 0 - for yyj1938 := 0; ; yyj1938++ { - if yyhl1938 { - if yyj1938 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1938Slc = r.DecodeBytes(yys1938Slc, true, true) - yys1938 := string(yys1938Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1938 { - case "weight": - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - case "preference": - if r.TryDecodeAsNil() { - x.Preference = NodeSelectorTerm{} - } else { - yyv1940 := &x.Preference - yyv1940.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1938) - } // end switch yys1938 - } // end for yyj1938 - 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 yyj1941 int - var yyb1941 bool - var yyhl1941 bool = l >= 0 - yyj1941++ - if yyhl1941 { - yyb1941 = yyj1941 > l - } else { - yyb1941 = r.CheckBreak() - } - if yyb1941 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - yyj1941++ - if yyhl1941 { - yyb1941 = yyj1941 > l - } else { - yyb1941 = r.CheckBreak() - } - if yyb1941 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Preference = NodeSelectorTerm{} - } else { - yyv1943 := &x.Preference - yyv1943.CodecDecodeSelf(d) - } - for { - yyj1941++ - if yyhl1941 { - yyb1941 = yyj1941 > l - } else { - yyb1941 = r.CheckBreak() - } - if yyb1941 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1941-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 { - yym1944 := z.EncBinary() - _ = yym1944 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1945 := !z.EncBinary() - yy2arr1945 := z.EncBasicHandle().StructToArray - var yyq1945 [3]bool - _, _, _ = yysep1945, yyq1945, yy2arr1945 - const yyr1945 bool = false - yyq1945[1] = x.Value != "" - var yynn1945 int - if yyr1945 || yy2arr1945 { - r.EncodeArrayStart(3) - } else { - yynn1945 = 2 - for _, b := range yyq1945 { - if b { - yynn1945++ - } - } - r.EncodeMapStart(yynn1945) - yynn1945 = 0 - } - if yyr1945 || yy2arr1945 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1947 := z.EncBinary() - _ = yym1947 - 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) - yym1948 := z.EncBinary() - _ = yym1948 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1945 || yy2arr1945 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1945[1] { - yym1950 := z.EncBinary() - _ = yym1950 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1945[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1951 := z.EncBinary() - _ = yym1951 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr1945 || yy2arr1945 { - 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 yyr1945 || yy2arr1945 { - 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 - yym1953 := z.DecBinary() - _ = yym1953 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1954 := r.ContainerType() - if yyct1954 == codecSelferValueTypeMap1234 { - yyl1954 := r.ReadMapStart() - if yyl1954 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1954, d) - } - } else if yyct1954 == codecSelferValueTypeArray1234 { - yyl1954 := r.ReadArrayStart() - if yyl1954 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1954, 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 yys1955Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1955Slc - var yyhl1955 bool = l >= 0 - for yyj1955 := 0; ; yyj1955++ { - if yyhl1955 { - if yyj1955 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1955Slc = r.DecodeBytes(yys1955Slc, true, true) - yys1955 := string(yys1955Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1955 { - 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, yys1955) - } // end switch yys1955 - } // end for yyj1955 - 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 yyj1959 int - var yyb1959 bool - var yyhl1959 bool = l >= 0 - yyj1959++ - if yyhl1959 { - yyb1959 = yyj1959 > l - } else { - yyb1959 = r.CheckBreak() - } - if yyb1959 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1959++ - if yyhl1959 { - yyb1959 = yyj1959 > l - } else { - yyb1959 = r.CheckBreak() - } - if yyb1959 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj1959++ - if yyhl1959 { - yyb1959 = yyj1959 > l - } else { - yyb1959 = r.CheckBreak() - } - if yyb1959 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Effect = "" - } else { - x.Effect = TaintEffect(r.DecodeString()) - } - for { - yyj1959++ - if yyhl1959 { - yyb1959 = yyj1959 > l - } else { - yyb1959 = r.CheckBreak() - } - if yyb1959 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1959-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x TaintEffect) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1963 := z.EncBinary() - _ = yym1963 - 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 - yym1964 := z.DecBinary() - _ = yym1964 - 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 { - yym1965 := z.EncBinary() - _ = yym1965 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1966 := !z.EncBinary() - yy2arr1966 := z.EncBasicHandle().StructToArray - var yyq1966 [4]bool - _, _, _ = yysep1966, yyq1966, yy2arr1966 - const yyr1966 bool = false - yyq1966[0] = x.Key != "" - yyq1966[1] = x.Operator != "" - yyq1966[2] = x.Value != "" - yyq1966[3] = x.Effect != "" - var yynn1966 int - if yyr1966 || yy2arr1966 { - r.EncodeArrayStart(4) - } else { - yynn1966 = 0 - for _, b := range yyq1966 { - if b { - yynn1966++ - } - } - r.EncodeMapStart(yynn1966) - yynn1966 = 0 - } - if yyr1966 || yy2arr1966 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1966[0] { - yym1968 := z.EncBinary() - _ = yym1968 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1966[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("key")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1969 := z.EncBinary() - _ = yym1969 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - } - if yyr1966 || yy2arr1966 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1966[1] { - x.Operator.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1966[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("operator")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Operator.CodecEncodeSelf(e) - } - } - if yyr1966 || yy2arr1966 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1966[2] { - yym1972 := z.EncBinary() - _ = yym1972 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1966[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1973 := z.EncBinary() - _ = yym1973 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr1966 || yy2arr1966 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1966[3] { - x.Effect.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1966[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("effect")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Effect.CodecEncodeSelf(e) - } - } - if yyr1966 || yy2arr1966 { - 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 - yym1975 := z.DecBinary() - _ = yym1975 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1976 := r.ContainerType() - if yyct1976 == codecSelferValueTypeMap1234 { - yyl1976 := r.ReadMapStart() - if yyl1976 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1976, d) - } - } else if yyct1976 == codecSelferValueTypeArray1234 { - yyl1976 := r.ReadArrayStart() - if yyl1976 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1976, 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 yys1977Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1977Slc - var yyhl1977 bool = l >= 0 - for yyj1977 := 0; ; yyj1977++ { - if yyhl1977 { - if yyj1977 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1977Slc = r.DecodeBytes(yys1977Slc, true, true) - yys1977 := string(yys1977Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1977 { - 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, yys1977) - } // end switch yys1977 - } // end for yyj1977 - 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 yyj1982 int - var yyb1982 bool - var yyhl1982 bool = l >= 0 - yyj1982++ - if yyhl1982 { - yyb1982 = yyj1982 > l - } else { - yyb1982 = r.CheckBreak() - } - if yyb1982 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1982++ - if yyhl1982 { - yyb1982 = yyj1982 > l - } else { - yyb1982 = r.CheckBreak() - } - if yyb1982 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Operator = "" - } else { - x.Operator = TolerationOperator(r.DecodeString()) - } - yyj1982++ - if yyhl1982 { - yyb1982 = yyj1982 > l - } else { - yyb1982 = r.CheckBreak() - } - if yyb1982 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj1982++ - if yyhl1982 { - yyb1982 = yyj1982 > l - } else { - yyb1982 = r.CheckBreak() - } - if yyb1982 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Effect = "" - } else { - x.Effect = TaintEffect(r.DecodeString()) - } - for { - yyj1982++ - if yyhl1982 { - yyb1982 = yyj1982 > l - } else { - yyb1982 = r.CheckBreak() - } - if yyb1982 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1982-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x TolerationOperator) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1987 := z.EncBinary() - _ = yym1987 - 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 - yym1988 := z.DecBinary() - _ = yym1988 - 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 { - yym1989 := z.EncBinary() - _ = yym1989 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1990 := !z.EncBinary() - yy2arr1990 := z.EncBasicHandle().StructToArray - var yyq1990 [17]bool - _, _, _ = yysep1990, yyq1990, yy2arr1990 - const yyr1990 bool = false - yyq1990[0] = len(x.Volumes) != 0 - yyq1990[2] = x.RestartPolicy != "" - yyq1990[3] = x.TerminationGracePeriodSeconds != nil - yyq1990[4] = x.ActiveDeadlineSeconds != nil - yyq1990[5] = x.DNSPolicy != "" - yyq1990[6] = len(x.NodeSelector) != 0 - yyq1990[7] = x.ServiceAccountName != "" - yyq1990[8] = x.DeprecatedServiceAccount != "" - yyq1990[9] = x.NodeName != "" - yyq1990[10] = x.HostNetwork != false - yyq1990[11] = x.HostPID != false - yyq1990[12] = x.HostIPC != false - yyq1990[13] = x.SecurityContext != nil - yyq1990[14] = len(x.ImagePullSecrets) != 0 - yyq1990[15] = x.Hostname != "" - yyq1990[16] = x.Subdomain != "" - var yynn1990 int - if yyr1990 || yy2arr1990 { - r.EncodeArrayStart(17) - } else { - yynn1990 = 1 - for _, b := range yyq1990 { - if b { - yynn1990++ - } - } - r.EncodeMapStart(yynn1990) - yynn1990 = 0 - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[0] { - if x.Volumes == nil { - r.EncodeNil() - } else { - yym1992 := z.EncBinary() - _ = yym1992 - if false { - } else { - h.encSliceVolume(([]Volume)(x.Volumes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Volumes == nil { - r.EncodeNil() - } else { - yym1993 := z.EncBinary() - _ = yym1993 - if false { - } else { - h.encSliceVolume(([]Volume)(x.Volumes), e) - } - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Containers == nil { - r.EncodeNil() - } else { - yym1995 := z.EncBinary() - _ = yym1995 - 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 { - yym1996 := z.EncBinary() - _ = yym1996 - if false { - } else { - h.encSliceContainer(([]Container)(x.Containers), e) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[2] { - x.RestartPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("restartPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.RestartPolicy.CodecEncodeSelf(e) - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[3] { - if x.TerminationGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy1999 := *x.TerminationGracePeriodSeconds - yym2000 := z.EncBinary() - _ = yym2000 - if false { - } else { - r.EncodeInt(int64(yy1999)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("terminationGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TerminationGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy2001 := *x.TerminationGracePeriodSeconds - yym2002 := z.EncBinary() - _ = yym2002 - if false { - } else { - r.EncodeInt(int64(yy2001)) - } - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[4] { - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy2004 := *x.ActiveDeadlineSeconds - yym2005 := z.EncBinary() - _ = yym2005 - if false { - } else { - r.EncodeInt(int64(yy2004)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy2006 := *x.ActiveDeadlineSeconds - yym2007 := z.EncBinary() - _ = yym2007 - if false { - } else { - r.EncodeInt(int64(yy2006)) - } - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[5] { - x.DNSPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("dnsPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.DNSPolicy.CodecEncodeSelf(e) - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[6] { - if x.NodeSelector == nil { - r.EncodeNil() - } else { - yym2010 := z.EncBinary() - _ = yym2010 - if false { - } else { - z.F.EncMapStringStringV(x.NodeSelector, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NodeSelector == nil { - r.EncodeNil() - } else { - yym2011 := z.EncBinary() - _ = yym2011 - if false { - } else { - z.F.EncMapStringStringV(x.NodeSelector, false, e) - } - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[7] { - yym2013 := z.EncBinary() - _ = yym2013 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceAccountName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2014 := z.EncBinary() - _ = yym2014 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[8] { - yym2016 := z.EncBinary() - _ = yym2016 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceAccount")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2017 := z.EncBinary() - _ = yym2017 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[9] { - yym2019 := z.EncBinary() - _ = yym2019 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2020 := z.EncBinary() - _ = yym2020 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[10] { - yym2022 := z.EncBinary() - _ = yym2022 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1990[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostNetwork")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2023 := z.EncBinary() - _ = yym2023 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[11] { - yym2025 := z.EncBinary() - _ = yym2025 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1990[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2026 := z.EncBinary() - _ = yym2026 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[12] { - yym2028 := z.EncBinary() - _ = yym2028 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1990[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIPC")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2029 := z.EncBinary() - _ = yym2029 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[13] { - if x.SecurityContext == nil { - r.EncodeNil() - } else { - x.SecurityContext.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[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 yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[14] { - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2032 := z.EncBinary() - _ = yym2032 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1990[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2033 := z.EncBinary() - _ = yym2033 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[15] { - yym2035 := z.EncBinary() - _ = yym2035 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2036 := z.EncBinary() - _ = yym2036 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr1990 || yy2arr1990 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1990[16] { - yym2038 := z.EncBinary() - _ = yym2038 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1990[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subdomain")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2039 := z.EncBinary() - _ = yym2039 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) - } - } - } - if yyr1990 || yy2arr1990 { - 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 - yym2040 := z.DecBinary() - _ = yym2040 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2041 := r.ContainerType() - if yyct2041 == codecSelferValueTypeMap1234 { - yyl2041 := r.ReadMapStart() - if yyl2041 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2041, d) - } - } else if yyct2041 == codecSelferValueTypeArray1234 { - yyl2041 := r.ReadArrayStart() - if yyl2041 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2041, 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 yys2042Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2042Slc - var yyhl2042 bool = l >= 0 - for yyj2042 := 0; ; yyj2042++ { - if yyhl2042 { - if yyj2042 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2042Slc = r.DecodeBytes(yys2042Slc, true, true) - yys2042 := string(yys2042Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2042 { - case "volumes": - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv2043 := &x.Volumes - yym2044 := z.DecBinary() - _ = yym2044 - if false { - } else { - h.decSliceVolume((*[]Volume)(yyv2043), d) - } - } - case "containers": - if r.TryDecodeAsNil() { - x.Containers = nil - } else { - yyv2045 := &x.Containers - yym2046 := z.DecBinary() - _ = yym2046 - if false { - } else { - h.decSliceContainer((*[]Container)(yyv2045), 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) - } - yym2049 := z.DecBinary() - _ = yym2049 - 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) - } - yym2051 := z.DecBinary() - _ = yym2051 - 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 { - yyv2053 := &x.NodeSelector - yym2054 := z.DecBinary() - _ = yym2054 - if false { - } else { - z.F.DecMapStringStringX(yyv2053, 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 { - yyv2062 := &x.ImagePullSecrets - yym2063 := z.DecBinary() - _ = yym2063 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2062), 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, yys2042) - } // end switch yys2042 - } // end for yyj2042 - 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 yyj2066 int - var yyb2066 bool - var yyhl2066 bool = l >= 0 - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv2067 := &x.Volumes - yym2068 := z.DecBinary() - _ = yym2068 - if false { - } else { - h.decSliceVolume((*[]Volume)(yyv2067), d) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Containers = nil - } else { - yyv2069 := &x.Containers - yym2070 := z.DecBinary() - _ = yym2070 - if false { - } else { - h.decSliceContainer((*[]Container)(yyv2069), d) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RestartPolicy = "" - } else { - x.RestartPolicy = RestartPolicy(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - 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) - } - yym2073 := z.DecBinary() - _ = yym2073 - if false { - } else { - *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - 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) - } - yym2075 := z.DecBinary() - _ = yym2075 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DNSPolicy = "" - } else { - x.DNSPolicy = DNSPolicy(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeSelector = nil - } else { - yyv2077 := &x.NodeSelector - yym2078 := z.DecBinary() - _ = yym2078 - if false { - } else { - z.F.DecMapStringStringX(yyv2077, false, d) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ServiceAccountName = "" - } else { - x.ServiceAccountName = string(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DeprecatedServiceAccount = "" - } else { - x.DeprecatedServiceAccount = string(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeName = "" - } else { - x.NodeName = string(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostNetwork = false - } else { - x.HostNetwork = bool(r.DecodeBool()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPID = false - } else { - x.HostPID = bool(r.DecodeBool()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIPC = false - } else { - x.HostIPC = bool(r.DecodeBool()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - 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) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2086 := &x.ImagePullSecrets - yym2087 := z.DecBinary() - _ = yym2087 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2086), d) - } - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Subdomain = "" - } else { - x.Subdomain = string(r.DecodeString()) - } - for { - yyj2066++ - if yyhl2066 { - yyb2066 = yyj2066 > l - } else { - yyb2066 = r.CheckBreak() - } - if yyb2066 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2066-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 { - yym2090 := z.EncBinary() - _ = yym2090 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2091 := !z.EncBinary() - yy2arr2091 := z.EncBasicHandle().StructToArray - var yyq2091 [5]bool - _, _, _ = yysep2091, yyq2091, yy2arr2091 - const yyr2091 bool = false - yyq2091[0] = x.SELinuxOptions != nil - yyq2091[1] = x.RunAsUser != nil - yyq2091[2] = x.RunAsNonRoot != nil - yyq2091[3] = len(x.SupplementalGroups) != 0 - yyq2091[4] = x.FSGroup != nil - var yynn2091 int - if yyr2091 || yy2arr2091 { - r.EncodeArrayStart(5) - } else { - yynn2091 = 0 - for _, b := range yyq2091 { - if b { - yynn2091++ - } - } - r.EncodeMapStart(yynn2091) - yynn2091 = 0 - } - if yyr2091 || yy2arr2091 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2091[0] { - if x.SELinuxOptions == nil { - r.EncodeNil() - } else { - x.SELinuxOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2091[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 yyr2091 || yy2arr2091 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2091[1] { - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy2094 := *x.RunAsUser - yym2095 := z.EncBinary() - _ = yym2095 - if false { - } else { - r.EncodeInt(int64(yy2094)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2091[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy2096 := *x.RunAsUser - yym2097 := z.EncBinary() - _ = yym2097 - if false { - } else { - r.EncodeInt(int64(yy2096)) - } - } - } - } - if yyr2091 || yy2arr2091 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2091[2] { - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy2099 := *x.RunAsNonRoot - yym2100 := z.EncBinary() - _ = yym2100 - if false { - } else { - r.EncodeBool(bool(yy2099)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2091[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy2101 := *x.RunAsNonRoot - yym2102 := z.EncBinary() - _ = yym2102 - if false { - } else { - r.EncodeBool(bool(yy2101)) - } - } - } - } - if yyr2091 || yy2arr2091 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2091[3] { - if x.SupplementalGroups == nil { - r.EncodeNil() - } else { - yym2104 := z.EncBinary() - _ = yym2104 - if false { - } else { - z.F.EncSliceInt64V(x.SupplementalGroups, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2091[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SupplementalGroups == nil { - r.EncodeNil() - } else { - yym2105 := z.EncBinary() - _ = yym2105 - if false { - } else { - z.F.EncSliceInt64V(x.SupplementalGroups, false, e) - } - } - } - } - if yyr2091 || yy2arr2091 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2091[4] { - if x.FSGroup == nil { - r.EncodeNil() - } else { - yy2107 := *x.FSGroup - yym2108 := z.EncBinary() - _ = yym2108 - if false { - } else { - r.EncodeInt(int64(yy2107)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2091[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsGroup")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FSGroup == nil { - r.EncodeNil() - } else { - yy2109 := *x.FSGroup - yym2110 := z.EncBinary() - _ = yym2110 - if false { - } else { - r.EncodeInt(int64(yy2109)) - } - } - } - } - if yyr2091 || yy2arr2091 { - 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 - yym2111 := z.DecBinary() - _ = yym2111 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2112 := r.ContainerType() - if yyct2112 == codecSelferValueTypeMap1234 { - yyl2112 := r.ReadMapStart() - if yyl2112 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2112, d) - } - } else if yyct2112 == codecSelferValueTypeArray1234 { - yyl2112 := r.ReadArrayStart() - if yyl2112 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2112, 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 yys2113Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2113Slc - var yyhl2113 bool = l >= 0 - for yyj2113 := 0; ; yyj2113++ { - if yyhl2113 { - if yyj2113 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2113Slc = r.DecodeBytes(yys2113Slc, true, true) - yys2113 := string(yys2113Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2113 { - 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) - } - yym2116 := z.DecBinary() - _ = yym2116 - 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) - } - yym2118 := z.DecBinary() - _ = yym2118 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - case "supplementalGroups": - if r.TryDecodeAsNil() { - x.SupplementalGroups = nil - } else { - yyv2119 := &x.SupplementalGroups - yym2120 := z.DecBinary() - _ = yym2120 - if false { - } else { - z.F.DecSliceInt64X(yyv2119, false, d) - } - } - case "fsGroup": - if r.TryDecodeAsNil() { - if x.FSGroup != nil { - x.FSGroup = nil - } - } else { - if x.FSGroup == nil { - x.FSGroup = new(int64) - } - yym2122 := z.DecBinary() - _ = yym2122 - if false { - } else { - *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys2113) - } // end switch yys2113 - } // end for yyj2113 - 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 yyj2123 int - var yyb2123 bool - var yyhl2123 bool = l >= 0 - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - 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) - } - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - 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) - } - yym2126 := z.DecBinary() - _ = yym2126 - if false { - } else { - *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) - } - } - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - 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) - } - yym2128 := z.DecBinary() - _ = yym2128 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SupplementalGroups = nil - } else { - yyv2129 := &x.SupplementalGroups - yym2130 := z.DecBinary() - _ = yym2130 - if false { - } else { - z.F.DecSliceInt64X(yyv2129, false, d) - } - } - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - 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) - } - yym2132 := z.DecBinary() - _ = yym2132 - if false { - } else { - *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) - } - } - for { - yyj2123++ - if yyhl2123 { - yyb2123 = yyj2123 > l - } else { - yyb2123 = r.CheckBreak() - } - if yyb2123 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2123-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 { - yym2133 := z.EncBinary() - _ = yym2133 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2134 := !z.EncBinary() - yy2arr2134 := z.EncBasicHandle().StructToArray - var yyq2134 [8]bool - _, _, _ = yysep2134, yyq2134, yy2arr2134 - const yyr2134 bool = false - yyq2134[0] = x.Phase != "" - yyq2134[1] = len(x.Conditions) != 0 - yyq2134[2] = x.Message != "" - yyq2134[3] = x.Reason != "" - yyq2134[4] = x.HostIP != "" - yyq2134[5] = x.PodIP != "" - yyq2134[6] = x.StartTime != nil - yyq2134[7] = len(x.ContainerStatuses) != 0 - var yynn2134 int - if yyr2134 || yy2arr2134 { - r.EncodeArrayStart(8) - } else { - yynn2134 = 0 - for _, b := range yyq2134 { - if b { - yynn2134++ - } - } - r.EncodeMapStart(yynn2134) - yynn2134 = 0 - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2134[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[1] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2137 := z.EncBinary() - _ = yym2137 - if false { - } else { - h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2134[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2138 := z.EncBinary() - _ = yym2138 - if false { - } else { - h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) - } - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[2] { - yym2140 := z.EncBinary() - _ = yym2140 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2134[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2141 := z.EncBinary() - _ = yym2141 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[3] { - yym2143 := z.EncBinary() - _ = yym2143 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2134[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2144 := z.EncBinary() - _ = yym2144 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[4] { - yym2146 := z.EncBinary() - _ = yym2146 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2134[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2147 := z.EncBinary() - _ = yym2147 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[5] { - yym2149 := z.EncBinary() - _ = yym2149 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2134[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2150 := z.EncBinary() - _ = yym2150 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[6] { - if x.StartTime == nil { - r.EncodeNil() - } else { - yym2152 := z.EncBinary() - _ = yym2152 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2152 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym2152 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2134[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartTime == nil { - r.EncodeNil() - } else { - yym2153 := z.EncBinary() - _ = yym2153 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2153 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym2153 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } - } - if yyr2134 || yy2arr2134 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2134[7] { - if x.ContainerStatuses == nil { - r.EncodeNil() - } else { - yym2155 := z.EncBinary() - _ = yym2155 - if false { - } else { - h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2134[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerStatuses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ContainerStatuses == nil { - r.EncodeNil() - } else { - yym2156 := z.EncBinary() - _ = yym2156 - if false { - } else { - h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) - } - } - } - } - if yyr2134 || yy2arr2134 { - 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 - yym2157 := z.DecBinary() - _ = yym2157 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2158 := r.ContainerType() - if yyct2158 == codecSelferValueTypeMap1234 { - yyl2158 := r.ReadMapStart() - if yyl2158 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2158, d) - } - } else if yyct2158 == codecSelferValueTypeArray1234 { - yyl2158 := r.ReadArrayStart() - if yyl2158 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2158, 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 yys2159Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2159Slc - var yyhl2159 bool = l >= 0 - for yyj2159 := 0; ; yyj2159++ { - if yyhl2159 { - if yyj2159 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2159Slc = r.DecodeBytes(yys2159Slc, true, true) - yys2159 := string(yys2159Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2159 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PodPhase(r.DecodeString()) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2161 := &x.Conditions - yym2162 := z.DecBinary() - _ = yym2162 - if false { - } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2161), 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) - } - yym2168 := z.DecBinary() - _ = yym2168 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2168 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2168 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - case "containerStatuses": - if r.TryDecodeAsNil() { - x.ContainerStatuses = nil - } else { - yyv2169 := &x.ContainerStatuses - yym2170 := z.DecBinary() - _ = yym2170 - if false { - } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2169), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2159) - } // end switch yys2159 - } // end for yyj2159 - 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 yyj2171 int - var yyb2171 bool - var yyhl2171 bool = l >= 0 - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PodPhase(r.DecodeString()) - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2173 := &x.Conditions - yym2174 := z.DecBinary() - _ = yym2174 - if false { - } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2173), d) - } - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIP = "" - } else { - x.HostIP = string(r.DecodeString()) - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodIP = "" - } else { - x.PodIP = string(r.DecodeString()) - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - 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) - } - yym2180 := z.DecBinary() - _ = yym2180 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2180 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2180 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerStatuses = nil - } else { - yyv2181 := &x.ContainerStatuses - yym2182 := z.DecBinary() - _ = yym2182 - if false { - } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2181), d) - } - } - for { - yyj2171++ - if yyhl2171 { - yyb2171 = yyj2171 > l - } else { - yyb2171 = r.CheckBreak() - } - if yyb2171 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2171-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 { - yym2183 := z.EncBinary() - _ = yym2183 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2184 := !z.EncBinary() - yy2arr2184 := z.EncBasicHandle().StructToArray - var yyq2184 [4]bool - _, _, _ = yysep2184, yyq2184, yy2arr2184 - const yyr2184 bool = false - yyq2184[0] = x.Kind != "" - yyq2184[1] = x.APIVersion != "" - yyq2184[2] = true - yyq2184[3] = true - var yynn2184 int - if yyr2184 || yy2arr2184 { - r.EncodeArrayStart(4) - } else { - yynn2184 = 0 - for _, b := range yyq2184 { - if b { - yynn2184++ - } - } - r.EncodeMapStart(yynn2184) - yynn2184 = 0 - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2184[0] { - yym2186 := z.EncBinary() - _ = yym2186 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2184[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2187 := z.EncBinary() - _ = yym2187 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2184[1] { - yym2189 := z.EncBinary() - _ = yym2189 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2184[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2190 := z.EncBinary() - _ = yym2190 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2184[2] { - yy2192 := &x.ObjectMeta - yy2192.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2184[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2193 := &x.ObjectMeta - yy2193.CodecEncodeSelf(e) - } - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2184[3] { - yy2195 := &x.Status - yy2195.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2184[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2196 := &x.Status - yy2196.CodecEncodeSelf(e) - } - } - if yyr2184 || yy2arr2184 { - 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 - yym2197 := z.DecBinary() - _ = yym2197 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2198 := r.ContainerType() - if yyct2198 == codecSelferValueTypeMap1234 { - yyl2198 := r.ReadMapStart() - if yyl2198 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2198, d) - } - } else if yyct2198 == codecSelferValueTypeArray1234 { - yyl2198 := r.ReadArrayStart() - if yyl2198 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2198, 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 yys2199Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2199Slc - var yyhl2199 bool = l >= 0 - for yyj2199 := 0; ; yyj2199++ { - if yyhl2199 { - if yyj2199 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2199Slc = r.DecodeBytes(yys2199Slc, true, true) - yys2199 := string(yys2199Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2199 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2202 := &x.ObjectMeta - yyv2202.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2203 := &x.Status - yyv2203.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2199) - } // end switch yys2199 - } // end for yyj2199 - 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 yyj2204 int - var yyb2204 bool - var yyhl2204 bool = l >= 0 - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l - } else { - yyb2204 = r.CheckBreak() - } - if yyb2204 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l - } else { - yyb2204 = r.CheckBreak() - } - if yyb2204 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l - } else { - yyb2204 = r.CheckBreak() - } - if yyb2204 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2207 := &x.ObjectMeta - yyv2207.CodecDecodeSelf(d) - } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l - } else { - yyb2204 = r.CheckBreak() - } - if yyb2204 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2208 := &x.Status - yyv2208.CodecDecodeSelf(d) - } - for { - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l - } else { - yyb2204 = r.CheckBreak() - } - if yyb2204 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2204-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 { - yym2209 := z.EncBinary() - _ = yym2209 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2210 := !z.EncBinary() - yy2arr2210 := z.EncBasicHandle().StructToArray - var yyq2210 [5]bool - _, _, _ = yysep2210, yyq2210, yy2arr2210 - const yyr2210 bool = false - yyq2210[0] = x.Kind != "" - yyq2210[1] = x.APIVersion != "" - yyq2210[2] = true - yyq2210[3] = true - yyq2210[4] = true - var yynn2210 int - if yyr2210 || yy2arr2210 { - r.EncodeArrayStart(5) - } else { - yynn2210 = 0 - for _, b := range yyq2210 { - if b { - yynn2210++ - } - } - r.EncodeMapStart(yynn2210) - yynn2210 = 0 - } - if yyr2210 || yy2arr2210 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2210[0] { - yym2212 := z.EncBinary() - _ = yym2212 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2210[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2213 := z.EncBinary() - _ = yym2213 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2210 || yy2arr2210 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2210[1] { - yym2215 := z.EncBinary() - _ = yym2215 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2210[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2216 := z.EncBinary() - _ = yym2216 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2210 || yy2arr2210 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2210[2] { - yy2218 := &x.ObjectMeta - yy2218.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2210[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2219 := &x.ObjectMeta - yy2219.CodecEncodeSelf(e) - } - } - if yyr2210 || yy2arr2210 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2210[3] { - yy2221 := &x.Spec - yy2221.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2210[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2222 := &x.Spec - yy2222.CodecEncodeSelf(e) - } - } - if yyr2210 || yy2arr2210 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2210[4] { - yy2224 := &x.Status - yy2224.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2210[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2225 := &x.Status - yy2225.CodecEncodeSelf(e) - } - } - if yyr2210 || yy2arr2210 { - 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 - yym2226 := z.DecBinary() - _ = yym2226 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2227 := r.ContainerType() - if yyct2227 == codecSelferValueTypeMap1234 { - yyl2227 := r.ReadMapStart() - if yyl2227 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2227, d) - } - } else if yyct2227 == codecSelferValueTypeArray1234 { - yyl2227 := r.ReadArrayStart() - if yyl2227 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2227, 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 yys2228Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2228Slc - var yyhl2228 bool = l >= 0 - for yyj2228 := 0; ; yyj2228++ { - if yyhl2228 { - if yyj2228 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2228Slc = r.DecodeBytes(yys2228Slc, true, true) - yys2228 := string(yys2228Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2228 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2231 := &x.ObjectMeta - yyv2231.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2232 := &x.Spec - yyv2232.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2233 := &x.Status - yyv2233.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2228) - } // end switch yys2228 - } // end for yyj2228 - 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 yyj2234 int - var yyb2234 bool - var yyhl2234 bool = l >= 0 - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2237 := &x.ObjectMeta - yyv2237.CodecDecodeSelf(d) - } - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2238 := &x.Spec - yyv2238.CodecDecodeSelf(d) - } - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2239 := &x.Status - yyv2239.CodecDecodeSelf(d) - } - for { - yyj2234++ - if yyhl2234 { - yyb2234 = yyj2234 > l - } else { - yyb2234 = r.CheckBreak() - } - if yyb2234 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2234-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 { - yym2240 := z.EncBinary() - _ = yym2240 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2241 := !z.EncBinary() - yy2arr2241 := z.EncBasicHandle().StructToArray - var yyq2241 [4]bool - _, _, _ = yysep2241, yyq2241, yy2arr2241 - const yyr2241 bool = false - yyq2241[0] = x.Kind != "" - yyq2241[1] = x.APIVersion != "" - yyq2241[2] = true - var yynn2241 int - if yyr2241 || yy2arr2241 { - r.EncodeArrayStart(4) - } else { - yynn2241 = 1 - for _, b := range yyq2241 { - if b { - yynn2241++ - } - } - r.EncodeMapStart(yynn2241) - yynn2241 = 0 - } - if yyr2241 || yy2arr2241 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2241[0] { - yym2243 := z.EncBinary() - _ = yym2243 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2241[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2244 := z.EncBinary() - _ = yym2244 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2241 || yy2arr2241 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2241[1] { - yym2246 := z.EncBinary() - _ = yym2246 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2241[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2247 := z.EncBinary() - _ = yym2247 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2241 || yy2arr2241 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2241[2] { - yy2249 := &x.ListMeta - yym2250 := z.EncBinary() - _ = yym2250 - if false { - } else if z.HasExtensions() && z.EncExt(yy2249) { - } else { - z.EncFallback(yy2249) - } - } else { - r.EncodeNil() - } - } else { - if yyq2241[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2251 := &x.ListMeta - yym2252 := z.EncBinary() - _ = yym2252 - if false { - } else if z.HasExtensions() && z.EncExt(yy2251) { - } else { - z.EncFallback(yy2251) - } - } - } - if yyr2241 || yy2arr2241 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2254 := z.EncBinary() - _ = yym2254 - 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 { - yym2255 := z.EncBinary() - _ = yym2255 - if false { - } else { - h.encSlicePod(([]Pod)(x.Items), e) - } - } - } - if yyr2241 || yy2arr2241 { - 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 - yym2256 := z.DecBinary() - _ = yym2256 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2257 := r.ContainerType() - if yyct2257 == codecSelferValueTypeMap1234 { - yyl2257 := r.ReadMapStart() - if yyl2257 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2257, d) - } - } else if yyct2257 == codecSelferValueTypeArray1234 { - yyl2257 := r.ReadArrayStart() - if yyl2257 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2257, 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 yys2258Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2258Slc - var yyhl2258 bool = l >= 0 - for yyj2258 := 0; ; yyj2258++ { - if yyhl2258 { - if yyj2258 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2258Slc = r.DecodeBytes(yys2258Slc, true, true) - yys2258 := string(yys2258Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2258 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2261 := &x.ListMeta - yym2262 := z.DecBinary() - _ = yym2262 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2261) { - } else { - z.DecFallback(yyv2261, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2263 := &x.Items - yym2264 := z.DecBinary() - _ = yym2264 - if false { - } else { - h.decSlicePod((*[]Pod)(yyv2263), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2258) - } // end switch yys2258 - } // end for yyj2258 - 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 yyj2265 int - var yyb2265 bool - var yyhl2265 bool = l >= 0 - yyj2265++ - if yyhl2265 { - yyb2265 = yyj2265 > l - } else { - yyb2265 = r.CheckBreak() - } - if yyb2265 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2265++ - if yyhl2265 { - yyb2265 = yyj2265 > l - } else { - yyb2265 = r.CheckBreak() - } - if yyb2265 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2265++ - if yyhl2265 { - yyb2265 = yyj2265 > l - } else { - yyb2265 = r.CheckBreak() - } - if yyb2265 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2268 := &x.ListMeta - yym2269 := z.DecBinary() - _ = yym2269 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2268) { - } else { - z.DecFallback(yyv2268, false) - } - } - yyj2265++ - if yyhl2265 { - yyb2265 = yyj2265 > l - } else { - yyb2265 = r.CheckBreak() - } - if yyb2265 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2270 := &x.Items - yym2271 := z.DecBinary() - _ = yym2271 - if false { - } else { - h.decSlicePod((*[]Pod)(yyv2270), d) - } - } - for { - yyj2265++ - if yyhl2265 { - yyb2265 = yyj2265 > l - } else { - yyb2265 = r.CheckBreak() - } - if yyb2265 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2265-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 { - yym2272 := z.EncBinary() - _ = yym2272 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2273 := !z.EncBinary() - yy2arr2273 := z.EncBasicHandle().StructToArray - var yyq2273 [2]bool - _, _, _ = yysep2273, yyq2273, yy2arr2273 - const yyr2273 bool = false - yyq2273[0] = true - yyq2273[1] = true - var yynn2273 int - if yyr2273 || yy2arr2273 { - r.EncodeArrayStart(2) - } else { - yynn2273 = 0 - for _, b := range yyq2273 { - if b { - yynn2273++ - } - } - r.EncodeMapStart(yynn2273) - yynn2273 = 0 - } - if yyr2273 || yy2arr2273 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2273[0] { - yy2275 := &x.ObjectMeta - yy2275.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2273[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2276 := &x.ObjectMeta - yy2276.CodecEncodeSelf(e) - } - } - if yyr2273 || yy2arr2273 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2273[1] { - yy2278 := &x.Spec - yy2278.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2273[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2279 := &x.Spec - yy2279.CodecEncodeSelf(e) - } - } - if yyr2273 || yy2arr2273 { - 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 - yym2280 := z.DecBinary() - _ = yym2280 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2281 := r.ContainerType() - if yyct2281 == codecSelferValueTypeMap1234 { - yyl2281 := r.ReadMapStart() - if yyl2281 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2281, d) - } - } else if yyct2281 == codecSelferValueTypeArray1234 { - yyl2281 := r.ReadArrayStart() - if yyl2281 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2281, 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 yys2282Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2282Slc - var yyhl2282 bool = l >= 0 - for yyj2282 := 0; ; yyj2282++ { - if yyhl2282 { - if yyj2282 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2282Slc = r.DecodeBytes(yys2282Slc, true, true) - yys2282 := string(yys2282Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2282 { - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2283 := &x.ObjectMeta - yyv2283.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2284 := &x.Spec - yyv2284.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2282) - } // end switch yys2282 - } // end for yyj2282 - 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 yyj2285 int - var yyb2285 bool - var yyhl2285 bool = l >= 0 - yyj2285++ - if yyhl2285 { - yyb2285 = yyj2285 > l - } else { - yyb2285 = r.CheckBreak() - } - if yyb2285 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2286 := &x.ObjectMeta - yyv2286.CodecDecodeSelf(d) - } - yyj2285++ - if yyhl2285 { - yyb2285 = yyj2285 > l - } else { - yyb2285 = r.CheckBreak() - } - if yyb2285 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2287 := &x.Spec - yyv2287.CodecDecodeSelf(d) - } - for { - yyj2285++ - if yyhl2285 { - yyb2285 = yyj2285 > l - } else { - yyb2285 = r.CheckBreak() - } - if yyb2285 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2285-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 { - yym2288 := z.EncBinary() - _ = yym2288 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2289 := !z.EncBinary() - yy2arr2289 := z.EncBasicHandle().StructToArray - var yyq2289 [4]bool - _, _, _ = yysep2289, yyq2289, yy2arr2289 - const yyr2289 bool = false - yyq2289[0] = x.Kind != "" - yyq2289[1] = x.APIVersion != "" - yyq2289[2] = true - yyq2289[3] = true - var yynn2289 int - if yyr2289 || yy2arr2289 { - r.EncodeArrayStart(4) - } else { - yynn2289 = 0 - for _, b := range yyq2289 { - if b { - yynn2289++ - } - } - r.EncodeMapStart(yynn2289) - yynn2289 = 0 - } - if yyr2289 || yy2arr2289 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2289[0] { - yym2291 := z.EncBinary() - _ = yym2291 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2289[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2292 := z.EncBinary() - _ = yym2292 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2289 || yy2arr2289 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2289[1] { - yym2294 := z.EncBinary() - _ = yym2294 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2289[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2295 := z.EncBinary() - _ = yym2295 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2289 || yy2arr2289 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2289[2] { - yy2297 := &x.ObjectMeta - yy2297.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2289[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2298 := &x.ObjectMeta - yy2298.CodecEncodeSelf(e) - } - } - if yyr2289 || yy2arr2289 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2289[3] { - yy2300 := &x.Template - yy2300.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2289[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2301 := &x.Template - yy2301.CodecEncodeSelf(e) - } - } - if yyr2289 || yy2arr2289 { - 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 - yym2302 := z.DecBinary() - _ = yym2302 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2303 := r.ContainerType() - if yyct2303 == codecSelferValueTypeMap1234 { - yyl2303 := r.ReadMapStart() - if yyl2303 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2303, d) - } - } else if yyct2303 == codecSelferValueTypeArray1234 { - yyl2303 := r.ReadArrayStart() - if yyl2303 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2303, 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 yys2304Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2304Slc - var yyhl2304 bool = l >= 0 - for yyj2304 := 0; ; yyj2304++ { - if yyhl2304 { - if yyj2304 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2304Slc = r.DecodeBytes(yys2304Slc, true, true) - yys2304 := string(yys2304Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2304 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2307 := &x.ObjectMeta - yyv2307.CodecDecodeSelf(d) - } - case "template": - if r.TryDecodeAsNil() { - x.Template = PodTemplateSpec{} - } else { - yyv2308 := &x.Template - yyv2308.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2304) - } // end switch yys2304 - } // end for yyj2304 - 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 yyj2309 int - var yyb2309 bool - var yyhl2309 bool = l >= 0 - yyj2309++ - if yyhl2309 { - yyb2309 = yyj2309 > l - } else { - yyb2309 = r.CheckBreak() - } - if yyb2309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2309++ - if yyhl2309 { - yyb2309 = yyj2309 > l - } else { - yyb2309 = r.CheckBreak() - } - if yyb2309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2309++ - if yyhl2309 { - yyb2309 = yyj2309 > l - } else { - yyb2309 = r.CheckBreak() - } - if yyb2309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2312 := &x.ObjectMeta - yyv2312.CodecDecodeSelf(d) - } - yyj2309++ - if yyhl2309 { - yyb2309 = yyj2309 > l - } else { - yyb2309 = r.CheckBreak() - } - if yyb2309 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = PodTemplateSpec{} - } else { - yyv2313 := &x.Template - yyv2313.CodecDecodeSelf(d) - } - for { - yyj2309++ - if yyhl2309 { - yyb2309 = yyj2309 > l - } else { - yyb2309 = r.CheckBreak() - } - if yyb2309 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2309-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 { - yym2314 := z.EncBinary() - _ = yym2314 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2315 := !z.EncBinary() - yy2arr2315 := z.EncBasicHandle().StructToArray - var yyq2315 [4]bool - _, _, _ = yysep2315, yyq2315, yy2arr2315 - const yyr2315 bool = false - yyq2315[0] = x.Kind != "" - yyq2315[1] = x.APIVersion != "" - yyq2315[2] = true - var yynn2315 int - if yyr2315 || yy2arr2315 { - r.EncodeArrayStart(4) - } else { - yynn2315 = 1 - for _, b := range yyq2315 { - if b { - yynn2315++ - } - } - r.EncodeMapStart(yynn2315) - yynn2315 = 0 - } - if yyr2315 || yy2arr2315 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2315[0] { - yym2317 := z.EncBinary() - _ = yym2317 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2315[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2318 := z.EncBinary() - _ = yym2318 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2315 || yy2arr2315 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2315[1] { - yym2320 := z.EncBinary() - _ = yym2320 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2315[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2321 := z.EncBinary() - _ = yym2321 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2315 || yy2arr2315 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2315[2] { - yy2323 := &x.ListMeta - yym2324 := z.EncBinary() - _ = yym2324 - if false { - } else if z.HasExtensions() && z.EncExt(yy2323) { - } else { - z.EncFallback(yy2323) - } - } else { - r.EncodeNil() - } - } else { - if yyq2315[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2325 := &x.ListMeta - yym2326 := z.EncBinary() - _ = yym2326 - if false { - } else if z.HasExtensions() && z.EncExt(yy2325) { - } else { - z.EncFallback(yy2325) - } - } - } - if yyr2315 || yy2arr2315 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2328 := z.EncBinary() - _ = yym2328 - 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 { - yym2329 := z.EncBinary() - _ = yym2329 - if false { - } else { - h.encSlicePodTemplate(([]PodTemplate)(x.Items), e) - } - } - } - if yyr2315 || yy2arr2315 { - 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 - yym2330 := z.DecBinary() - _ = yym2330 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2331 := r.ContainerType() - if yyct2331 == codecSelferValueTypeMap1234 { - yyl2331 := r.ReadMapStart() - if yyl2331 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2331, d) - } - } else if yyct2331 == codecSelferValueTypeArray1234 { - yyl2331 := r.ReadArrayStart() - if yyl2331 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2331, 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 yys2332Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2332Slc - var yyhl2332 bool = l >= 0 - for yyj2332 := 0; ; yyj2332++ { - if yyhl2332 { - if yyj2332 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2332Slc = r.DecodeBytes(yys2332Slc, true, true) - yys2332 := string(yys2332Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2332 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2335 := &x.ListMeta - yym2336 := z.DecBinary() - _ = yym2336 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2335) { - } else { - z.DecFallback(yyv2335, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2337 := &x.Items - yym2338 := z.DecBinary() - _ = yym2338 - if false { - } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2337), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2332) - } // end switch yys2332 - } // end for yyj2332 - 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 yyj2339 int - var yyb2339 bool - var yyhl2339 bool = l >= 0 - yyj2339++ - if yyhl2339 { - yyb2339 = yyj2339 > l - } else { - yyb2339 = r.CheckBreak() - } - if yyb2339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2339++ - if yyhl2339 { - yyb2339 = yyj2339 > l - } else { - yyb2339 = r.CheckBreak() - } - if yyb2339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2339++ - if yyhl2339 { - yyb2339 = yyj2339 > l - } else { - yyb2339 = r.CheckBreak() - } - if yyb2339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2342 := &x.ListMeta - yym2343 := z.DecBinary() - _ = yym2343 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2342) { - } else { - z.DecFallback(yyv2342, false) - } - } - yyj2339++ - if yyhl2339 { - yyb2339 = yyj2339 > l - } else { - yyb2339 = r.CheckBreak() - } - if yyb2339 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2344 := &x.Items - yym2345 := z.DecBinary() - _ = yym2345 - if false { - } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2344), d) - } - } - for { - yyj2339++ - if yyhl2339 { - yyb2339 = yyj2339 > l - } else { - yyb2339 = r.CheckBreak() - } - if yyb2339 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2339-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 { - yym2346 := z.EncBinary() - _ = yym2346 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2347 := !z.EncBinary() - yy2arr2347 := z.EncBasicHandle().StructToArray - var yyq2347 [3]bool - _, _, _ = yysep2347, yyq2347, yy2arr2347 - const yyr2347 bool = false - yyq2347[0] = x.Replicas != nil - yyq2347[1] = len(x.Selector) != 0 - yyq2347[2] = x.Template != nil - var yynn2347 int - if yyr2347 || yy2arr2347 { - r.EncodeArrayStart(3) - } else { - yynn2347 = 0 - for _, b := range yyq2347 { - if b { - yynn2347++ - } - } - r.EncodeMapStart(yynn2347) - yynn2347 = 0 - } - if yyr2347 || yy2arr2347 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2347[0] { - if x.Replicas == nil { - r.EncodeNil() - } else { - yy2349 := *x.Replicas - yym2350 := z.EncBinary() - _ = yym2350 - if false { - } else { - r.EncodeInt(int64(yy2349)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2347[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Replicas == nil { - r.EncodeNil() - } else { - yy2351 := *x.Replicas - yym2352 := z.EncBinary() - _ = yym2352 - if false { - } else { - r.EncodeInt(int64(yy2351)) - } - } - } - } - if yyr2347 || yy2arr2347 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2347[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym2354 := z.EncBinary() - _ = yym2354 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2347[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2355 := z.EncBinary() - _ = yym2355 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } - } - if yyr2347 || yy2arr2347 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2347[2] { - if x.Template == nil { - r.EncodeNil() - } else { - x.Template.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2347[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 yyr2347 || yy2arr2347 { - 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 - yym2357 := z.DecBinary() - _ = yym2357 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2358 := r.ContainerType() - if yyct2358 == codecSelferValueTypeMap1234 { - yyl2358 := r.ReadMapStart() - if yyl2358 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2358, d) - } - } else if yyct2358 == codecSelferValueTypeArray1234 { - yyl2358 := r.ReadArrayStart() - if yyl2358 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2358, 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 yys2359Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2359Slc - var yyhl2359 bool = l >= 0 - for yyj2359 := 0; ; yyj2359++ { - if yyhl2359 { - if yyj2359 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2359Slc = r.DecodeBytes(yys2359Slc, true, true) - yys2359 := string(yys2359Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2359 { - case "replicas": - if r.TryDecodeAsNil() { - if x.Replicas != nil { - x.Replicas = nil - } - } else { - if x.Replicas == nil { - x.Replicas = new(int32) - } - yym2361 := z.DecBinary() - _ = yym2361 - if false { - } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) - } - } - case "selector": - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2362 := &x.Selector - yym2363 := z.DecBinary() - _ = yym2363 - if false { - } else { - z.F.DecMapStringStringX(yyv2362, 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, yys2359) - } // end switch yys2359 - } // end for yyj2359 - 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 yyj2365 int - var yyb2365 bool - var yyhl2365 bool = l >= 0 - yyj2365++ - if yyhl2365 { - yyb2365 = yyj2365 > l - } else { - yyb2365 = r.CheckBreak() - } - if yyb2365 { - 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) - } - yym2367 := z.DecBinary() - _ = yym2367 - if false { - } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) - } - } - yyj2365++ - if yyhl2365 { - yyb2365 = yyj2365 > l - } else { - yyb2365 = r.CheckBreak() - } - if yyb2365 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2368 := &x.Selector - yym2369 := z.DecBinary() - _ = yym2369 - if false { - } else { - z.F.DecMapStringStringX(yyv2368, false, d) - } - } - yyj2365++ - if yyhl2365 { - yyb2365 = yyj2365 > l - } else { - yyb2365 = r.CheckBreak() - } - if yyb2365 { - 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 { - yyj2365++ - if yyhl2365 { - yyb2365 = yyj2365 > l - } else { - yyb2365 = r.CheckBreak() - } - if yyb2365 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2365-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 { - yym2371 := z.EncBinary() - _ = yym2371 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2372 := !z.EncBinary() - yy2arr2372 := z.EncBasicHandle().StructToArray - var yyq2372 [4]bool - _, _, _ = yysep2372, yyq2372, yy2arr2372 - const yyr2372 bool = false - yyq2372[1] = x.FullyLabeledReplicas != 0 - yyq2372[2] = x.ReadyReplicas != 0 - yyq2372[3] = x.ObservedGeneration != 0 - var yynn2372 int - if yyr2372 || yy2arr2372 { - r.EncodeArrayStart(4) - } else { - yynn2372 = 1 - for _, b := range yyq2372 { - if b { - yynn2372++ - } - } - r.EncodeMapStart(yynn2372) - yynn2372 = 0 - } - if yyr2372 || yy2arr2372 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2374 := z.EncBinary() - _ = yym2374 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2375 := z.EncBinary() - _ = yym2375 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr2372 || yy2arr2372 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2372[1] { - yym2377 := z.EncBinary() - _ = yym2377 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2372[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2378 := z.EncBinary() - _ = yym2378 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } - } - if yyr2372 || yy2arr2372 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2372[2] { - yym2380 := z.EncBinary() - _ = yym2380 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2372[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2381 := z.EncBinary() - _ = yym2381 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } - } - if yyr2372 || yy2arr2372 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2372[3] { - yym2383 := z.EncBinary() - _ = yym2383 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2372[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2384 := z.EncBinary() - _ = yym2384 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr2372 || yy2arr2372 { - 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 - yym2385 := z.DecBinary() - _ = yym2385 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2386 := r.ContainerType() - if yyct2386 == codecSelferValueTypeMap1234 { - yyl2386 := r.ReadMapStart() - if yyl2386 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2386, d) - } - } else if yyct2386 == codecSelferValueTypeArray1234 { - yyl2386 := r.ReadArrayStart() - if yyl2386 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2386, 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 yys2387Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2387Slc - var yyhl2387 bool = l >= 0 - for yyj2387 := 0; ; yyj2387++ { - if yyhl2387 { - if yyj2387 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2387Slc = r.DecodeBytes(yys2387Slc, true, true) - yys2387 := string(yys2387Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2387 { - 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 "readyReplicas": - if r.TryDecodeAsNil() { - x.ReadyReplicas = 0 - } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) - } - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys2387) - } // end switch yys2387 - } // end for yyj2387 - 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 yyj2392 int - var yyb2392 bool - var yyhl2392 bool = l >= 0 - yyj2392++ - if yyhl2392 { - yyb2392 = yyj2392 > l - } else { - yyb2392 = r.CheckBreak() - } - if yyb2392 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj2392++ - if yyhl2392 { - yyb2392 = yyj2392 > l - } else { - yyb2392 = r.CheckBreak() - } - if yyb2392 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FullyLabeledReplicas = 0 - } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) - } - yyj2392++ - if yyhl2392 { - yyb2392 = yyj2392 > l - } else { - yyb2392 = r.CheckBreak() - } - if yyb2392 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadyReplicas = 0 - } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) - } - yyj2392++ - if yyhl2392 { - yyb2392 = yyj2392 > l - } else { - yyb2392 = r.CheckBreak() - } - if yyb2392 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - for { - yyj2392++ - if yyhl2392 { - yyb2392 = yyj2392 > l - } else { - yyb2392 = r.CheckBreak() - } - if yyb2392 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2392-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 { - yym2397 := z.EncBinary() - _ = yym2397 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2398 := !z.EncBinary() - yy2arr2398 := z.EncBasicHandle().StructToArray - var yyq2398 [5]bool - _, _, _ = yysep2398, yyq2398, yy2arr2398 - const yyr2398 bool = false - yyq2398[0] = x.Kind != "" - yyq2398[1] = x.APIVersion != "" - yyq2398[2] = true - yyq2398[3] = true - yyq2398[4] = true - var yynn2398 int - if yyr2398 || yy2arr2398 { - r.EncodeArrayStart(5) - } else { - yynn2398 = 0 - for _, b := range yyq2398 { - if b { - yynn2398++ - } - } - r.EncodeMapStart(yynn2398) - yynn2398 = 0 - } - if yyr2398 || yy2arr2398 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2398[0] { - yym2400 := z.EncBinary() - _ = yym2400 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2398[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2401 := z.EncBinary() - _ = yym2401 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2398 || yy2arr2398 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2398[1] { - yym2403 := z.EncBinary() - _ = yym2403 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2398[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2404 := z.EncBinary() - _ = yym2404 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2398 || yy2arr2398 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2398[2] { - yy2406 := &x.ObjectMeta - yy2406.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2398[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2407 := &x.ObjectMeta - yy2407.CodecEncodeSelf(e) - } - } - if yyr2398 || yy2arr2398 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2398[3] { - yy2409 := &x.Spec - yy2409.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2398[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2410 := &x.Spec - yy2410.CodecEncodeSelf(e) - } - } - if yyr2398 || yy2arr2398 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2398[4] { - yy2412 := &x.Status - yy2412.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2398[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2413 := &x.Status - yy2413.CodecEncodeSelf(e) - } - } - if yyr2398 || yy2arr2398 { - 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 - yym2414 := z.DecBinary() - _ = yym2414 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2415 := r.ContainerType() - if yyct2415 == codecSelferValueTypeMap1234 { - yyl2415 := r.ReadMapStart() - if yyl2415 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2415, d) - } - } else if yyct2415 == codecSelferValueTypeArray1234 { - yyl2415 := r.ReadArrayStart() - if yyl2415 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2415, 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 yys2416Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2416Slc - var yyhl2416 bool = l >= 0 - for yyj2416 := 0; ; yyj2416++ { - if yyhl2416 { - if yyj2416 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2416Slc = r.DecodeBytes(yys2416Slc, true, true) - yys2416 := string(yys2416Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2416 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2419 := &x.ObjectMeta - yyv2419.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ReplicationControllerSpec{} - } else { - yyv2420 := &x.Spec - yyv2420.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ReplicationControllerStatus{} - } else { - yyv2421 := &x.Status - yyv2421.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2416) - } // end switch yys2416 - } // end for yyj2416 - 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 yyj2422 int - var yyb2422 bool - var yyhl2422 bool = l >= 0 - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2425 := &x.ObjectMeta - yyv2425.CodecDecodeSelf(d) - } - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ReplicationControllerSpec{} - } else { - yyv2426 := &x.Spec - yyv2426.CodecDecodeSelf(d) - } - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ReplicationControllerStatus{} - } else { - yyv2427 := &x.Status - yyv2427.CodecDecodeSelf(d) - } - for { - yyj2422++ - if yyhl2422 { - yyb2422 = yyj2422 > l - } else { - yyb2422 = r.CheckBreak() - } - if yyb2422 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2422-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 { - yym2428 := z.EncBinary() - _ = yym2428 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2429 := !z.EncBinary() - yy2arr2429 := z.EncBasicHandle().StructToArray - var yyq2429 [4]bool - _, _, _ = yysep2429, yyq2429, yy2arr2429 - const yyr2429 bool = false - yyq2429[0] = x.Kind != "" - yyq2429[1] = x.APIVersion != "" - yyq2429[2] = true - var yynn2429 int - if yyr2429 || yy2arr2429 { - r.EncodeArrayStart(4) - } else { - yynn2429 = 1 - for _, b := range yyq2429 { - if b { - yynn2429++ - } - } - r.EncodeMapStart(yynn2429) - yynn2429 = 0 - } - if yyr2429 || yy2arr2429 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2429[0] { - yym2431 := z.EncBinary() - _ = yym2431 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2429[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2432 := z.EncBinary() - _ = yym2432 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2429 || yy2arr2429 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2429[1] { - yym2434 := z.EncBinary() - _ = yym2434 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2429[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2435 := z.EncBinary() - _ = yym2435 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2429 || yy2arr2429 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2429[2] { - yy2437 := &x.ListMeta - yym2438 := z.EncBinary() - _ = yym2438 - if false { - } else if z.HasExtensions() && z.EncExt(yy2437) { - } else { - z.EncFallback(yy2437) - } - } else { - r.EncodeNil() - } - } else { - if yyq2429[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2439 := &x.ListMeta - yym2440 := z.EncBinary() - _ = yym2440 - if false { - } else if z.HasExtensions() && z.EncExt(yy2439) { - } else { - z.EncFallback(yy2439) - } - } - } - if yyr2429 || yy2arr2429 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2442 := z.EncBinary() - _ = yym2442 - 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 { - yym2443 := z.EncBinary() - _ = yym2443 - if false { - } else { - h.encSliceReplicationController(([]ReplicationController)(x.Items), e) - } - } - } - if yyr2429 || yy2arr2429 { - 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 - yym2444 := z.DecBinary() - _ = yym2444 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2445 := r.ContainerType() - if yyct2445 == codecSelferValueTypeMap1234 { - yyl2445 := r.ReadMapStart() - if yyl2445 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2445, d) - } - } else if yyct2445 == codecSelferValueTypeArray1234 { - yyl2445 := r.ReadArrayStart() - if yyl2445 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2445, 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 yys2446Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2446Slc - var yyhl2446 bool = l >= 0 - for yyj2446 := 0; ; yyj2446++ { - if yyhl2446 { - if yyj2446 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2446Slc = r.DecodeBytes(yys2446Slc, true, true) - yys2446 := string(yys2446Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2446 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2449 := &x.ListMeta - yym2450 := z.DecBinary() - _ = yym2450 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2449) { - } else { - z.DecFallback(yyv2449, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2451 := &x.Items - yym2452 := z.DecBinary() - _ = yym2452 - if false { - } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2451), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2446) - } // end switch yys2446 - } // end for yyj2446 - 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 yyj2453 int - var yyb2453 bool - var yyhl2453 bool = l >= 0 - yyj2453++ - if yyhl2453 { - yyb2453 = yyj2453 > l - } else { - yyb2453 = r.CheckBreak() - } - if yyb2453 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2453++ - if yyhl2453 { - yyb2453 = yyj2453 > l - } else { - yyb2453 = r.CheckBreak() - } - if yyb2453 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2453++ - if yyhl2453 { - yyb2453 = yyj2453 > l - } else { - yyb2453 = r.CheckBreak() - } - if yyb2453 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2456 := &x.ListMeta - yym2457 := z.DecBinary() - _ = yym2457 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2456) { - } else { - z.DecFallback(yyv2456, false) - } - } - yyj2453++ - if yyhl2453 { - yyb2453 = yyj2453 > l - } else { - yyb2453 = r.CheckBreak() - } - if yyb2453 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2458 := &x.Items - yym2459 := z.DecBinary() - _ = yym2459 - if false { - } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2458), d) - } - } - for { - yyj2453++ - if yyhl2453 { - yyb2453 = yyj2453 > l - } else { - yyb2453 = r.CheckBreak() - } - if yyb2453 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2453-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ServiceAffinity) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym2460 := z.EncBinary() - _ = yym2460 - 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 - yym2461 := z.DecBinary() - _ = yym2461 - 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 - yym2462 := z.EncBinary() - _ = yym2462 - 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 - yym2463 := z.DecBinary() - _ = yym2463 - 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 { - yym2464 := z.EncBinary() - _ = yym2464 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2465 := !z.EncBinary() - yy2arr2465 := z.EncBasicHandle().StructToArray - var yyq2465 [1]bool - _, _, _ = yysep2465, yyq2465, yy2arr2465 - const yyr2465 bool = false - yyq2465[0] = true - var yynn2465 int - if yyr2465 || yy2arr2465 { - r.EncodeArrayStart(1) - } else { - yynn2465 = 0 - for _, b := range yyq2465 { - if b { - yynn2465++ - } - } - r.EncodeMapStart(yynn2465) - yynn2465 = 0 - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[0] { - yy2467 := &x.LoadBalancer - yy2467.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2465[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancer")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2468 := &x.LoadBalancer - yy2468.CodecEncodeSelf(e) - } - } - if yyr2465 || yy2arr2465 { - 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 - yym2469 := z.DecBinary() - _ = yym2469 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2470 := r.ContainerType() - if yyct2470 == codecSelferValueTypeMap1234 { - yyl2470 := r.ReadMapStart() - if yyl2470 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2470, d) - } - } else if yyct2470 == codecSelferValueTypeArray1234 { - yyl2470 := r.ReadArrayStart() - if yyl2470 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2470, 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 yys2471Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2471Slc - var yyhl2471 bool = l >= 0 - for yyj2471 := 0; ; yyj2471++ { - if yyhl2471 { - if yyj2471 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2471Slc = r.DecodeBytes(yys2471Slc, true, true) - yys2471 := string(yys2471Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2471 { - case "loadBalancer": - if r.TryDecodeAsNil() { - x.LoadBalancer = LoadBalancerStatus{} - } else { - yyv2472 := &x.LoadBalancer - yyv2472.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2471) - } // end switch yys2471 - } // end for yyj2471 - 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 yyj2473 int - var yyb2473 bool - var yyhl2473 bool = l >= 0 - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l - } else { - yyb2473 = r.CheckBreak() - } - if yyb2473 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancer = LoadBalancerStatus{} - } else { - yyv2474 := &x.LoadBalancer - yyv2474.CodecDecodeSelf(d) - } - for { - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l - } else { - yyb2473 = r.CheckBreak() - } - if yyb2473 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2473-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 { - yym2475 := z.EncBinary() - _ = yym2475 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2476 := !z.EncBinary() - yy2arr2476 := z.EncBasicHandle().StructToArray - var yyq2476 [1]bool - _, _, _ = yysep2476, yyq2476, yy2arr2476 - const yyr2476 bool = false - yyq2476[0] = len(x.Ingress) != 0 - var yynn2476 int - if yyr2476 || yy2arr2476 { - r.EncodeArrayStart(1) - } else { - yynn2476 = 0 - for _, b := range yyq2476 { - if b { - yynn2476++ - } - } - r.EncodeMapStart(yynn2476) - yynn2476 = 0 - } - if yyr2476 || yy2arr2476 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2476[0] { - if x.Ingress == nil { - r.EncodeNil() - } else { - yym2478 := z.EncBinary() - _ = yym2478 - if false { - } else { - h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2476[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ingress")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ingress == nil { - r.EncodeNil() - } else { - yym2479 := z.EncBinary() - _ = yym2479 - if false { - } else { - h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) - } - } - } - } - if yyr2476 || yy2arr2476 { - 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 - yym2480 := z.DecBinary() - _ = yym2480 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2481 := r.ContainerType() - if yyct2481 == codecSelferValueTypeMap1234 { - yyl2481 := r.ReadMapStart() - if yyl2481 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2481, d) - } - } else if yyct2481 == codecSelferValueTypeArray1234 { - yyl2481 := r.ReadArrayStart() - if yyl2481 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2481, 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 yys2482Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2482Slc - var yyhl2482 bool = l >= 0 - for yyj2482 := 0; ; yyj2482++ { - if yyhl2482 { - if yyj2482 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2482Slc = r.DecodeBytes(yys2482Slc, true, true) - yys2482 := string(yys2482Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2482 { - case "ingress": - if r.TryDecodeAsNil() { - x.Ingress = nil - } else { - yyv2483 := &x.Ingress - yym2484 := z.DecBinary() - _ = yym2484 - if false { - } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2483), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2482) - } // end switch yys2482 - } // end for yyj2482 - 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 yyj2485 int - var yyb2485 bool - var yyhl2485 bool = l >= 0 - yyj2485++ - if yyhl2485 { - yyb2485 = yyj2485 > l - } else { - yyb2485 = r.CheckBreak() - } - if yyb2485 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ingress = nil - } else { - yyv2486 := &x.Ingress - yym2487 := z.DecBinary() - _ = yym2487 - if false { - } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2486), d) - } - } - for { - yyj2485++ - if yyhl2485 { - yyb2485 = yyj2485 > l - } else { - yyb2485 = r.CheckBreak() - } - if yyb2485 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2485-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 { - yym2488 := z.EncBinary() - _ = yym2488 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2489 := !z.EncBinary() - yy2arr2489 := z.EncBasicHandle().StructToArray - var yyq2489 [2]bool - _, _, _ = yysep2489, yyq2489, yy2arr2489 - const yyr2489 bool = false - yyq2489[0] = x.IP != "" - yyq2489[1] = x.Hostname != "" - var yynn2489 int - if yyr2489 || yy2arr2489 { - r.EncodeArrayStart(2) - } else { - yynn2489 = 0 - for _, b := range yyq2489 { - if b { - yynn2489++ - } - } - r.EncodeMapStart(yynn2489) - yynn2489 = 0 - } - if yyr2489 || yy2arr2489 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2489[0] { - yym2491 := z.EncBinary() - _ = yym2491 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2489[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ip")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2492 := z.EncBinary() - _ = yym2492 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } - } - if yyr2489 || yy2arr2489 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2489[1] { - yym2494 := z.EncBinary() - _ = yym2494 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2489[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2495 := z.EncBinary() - _ = yym2495 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr2489 || yy2arr2489 { - 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 - yym2496 := z.DecBinary() - _ = yym2496 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2497 := r.ContainerType() - if yyct2497 == codecSelferValueTypeMap1234 { - yyl2497 := r.ReadMapStart() - if yyl2497 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2497, d) - } - } else if yyct2497 == codecSelferValueTypeArray1234 { - yyl2497 := r.ReadArrayStart() - if yyl2497 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2497, 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 yys2498Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2498Slc - var yyhl2498 bool = l >= 0 - for yyj2498 := 0; ; yyj2498++ { - if yyhl2498 { - if yyj2498 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2498Slc = r.DecodeBytes(yys2498Slc, true, true) - yys2498 := string(yys2498Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2498 { - 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, yys2498) - } // end switch yys2498 - } // end for yyj2498 - 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 yyj2501 int - var yyb2501 bool - var yyhl2501 bool = l >= 0 - yyj2501++ - if yyhl2501 { - yyb2501 = yyj2501 > l - } else { - yyb2501 = r.CheckBreak() - } - if yyb2501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IP = "" - } else { - x.IP = string(r.DecodeString()) - } - yyj2501++ - if yyhl2501 { - yyb2501 = yyj2501 > l - } else { - yyb2501 = r.CheckBreak() - } - if yyb2501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - for { - yyj2501++ - if yyhl2501 { - yyb2501 = yyj2501 > l - } else { - yyb2501 = r.CheckBreak() - } - if yyb2501 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2501-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 { - yym2504 := z.EncBinary() - _ = yym2504 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2505 := !z.EncBinary() - yy2arr2505 := z.EncBasicHandle().StructToArray - var yyq2505 [10]bool - _, _, _ = yysep2505, yyq2505, yy2arr2505 - const yyr2505 bool = false - yyq2505[1] = len(x.Selector) != 0 - yyq2505[2] = x.ClusterIP != "" - yyq2505[3] = x.Type != "" - yyq2505[4] = len(x.ExternalIPs) != 0 - yyq2505[5] = len(x.DeprecatedPublicIPs) != 0 - yyq2505[6] = x.SessionAffinity != "" - yyq2505[7] = x.LoadBalancerIP != "" - yyq2505[8] = len(x.LoadBalancerSourceRanges) != 0 - yyq2505[9] = x.ExternalName != "" - var yynn2505 int - if yyr2505 || yy2arr2505 { - r.EncodeArrayStart(10) - } else { - yynn2505 = 1 - for _, b := range yyq2505 { - if b { - yynn2505++ - } - } - r.EncodeMapStart(yynn2505) - yynn2505 = 0 - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2507 := z.EncBinary() - _ = yym2507 - 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 { - yym2508 := z.EncBinary() - _ = yym2508 - if false { - } else { - h.encSliceServicePort(([]ServicePort)(x.Ports), e) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym2510 := z.EncBinary() - _ = yym2510 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2505[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2511 := z.EncBinary() - _ = yym2511 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[2] { - yym2513 := z.EncBinary() - _ = yym2513 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2514 := z.EncBinary() - _ = yym2514 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[3] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[4] { - if x.ExternalIPs == nil { - r.EncodeNil() - } else { - yym2517 := z.EncBinary() - _ = yym2517 - if false { - } else { - z.F.EncSliceStringV(x.ExternalIPs, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2505[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("externalIPs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ExternalIPs == nil { - r.EncodeNil() - } else { - yym2518 := z.EncBinary() - _ = yym2518 - if false { - } else { - z.F.EncSliceStringV(x.ExternalIPs, false, e) - } - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[5] { - if x.DeprecatedPublicIPs == nil { - r.EncodeNil() - } else { - yym2520 := z.EncBinary() - _ = yym2520 - if false { - } else { - z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2505[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deprecatedPublicIPs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DeprecatedPublicIPs == nil { - r.EncodeNil() - } else { - yym2521 := z.EncBinary() - _ = yym2521 - if false { - } else { - z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e) - } - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[6] { - x.SessionAffinity.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sessionAffinity")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.SessionAffinity.CodecEncodeSelf(e) - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[7] { - yym2524 := z.EncBinary() - _ = yym2524 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancerIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2525 := z.EncBinary() - _ = yym2525 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[8] { - if x.LoadBalancerSourceRanges == nil { - r.EncodeNil() - } else { - yym2527 := z.EncBinary() - _ = yym2527 - if false { - } else { - z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2505[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancerSourceRanges")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LoadBalancerSourceRanges == nil { - r.EncodeNil() - } else { - yym2528 := z.EncBinary() - _ = yym2528 - if false { - } else { - z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) - } - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[9] { - yym2530 := z.EncBinary() - _ = yym2530 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("externalName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2531 := z.EncBinary() - _ = yym2531 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) - } - } - } - if yyr2505 || yy2arr2505 { - 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 - yym2532 := z.DecBinary() - _ = yym2532 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2533 := r.ContainerType() - if yyct2533 == codecSelferValueTypeMap1234 { - yyl2533 := r.ReadMapStart() - if yyl2533 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2533, d) - } - } else if yyct2533 == codecSelferValueTypeArray1234 { - yyl2533 := r.ReadArrayStart() - if yyl2533 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2533, 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 yys2534Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2534Slc - var yyhl2534 bool = l >= 0 - for yyj2534 := 0; ; yyj2534++ { - if yyhl2534 { - if yyj2534 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2534Slc = r.DecodeBytes(yys2534Slc, true, true) - yys2534 := string(yys2534Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2534 { - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2535 := &x.Ports - yym2536 := z.DecBinary() - _ = yym2536 - if false { - } else { - h.decSliceServicePort((*[]ServicePort)(yyv2535), d) - } - } - case "selector": - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2537 := &x.Selector - yym2538 := z.DecBinary() - _ = yym2538 - if false { - } else { - z.F.DecMapStringStringX(yyv2537, 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 { - yyv2541 := &x.ExternalIPs - yym2542 := z.DecBinary() - _ = yym2542 - if false { - } else { - z.F.DecSliceStringX(yyv2541, false, d) - } - } - case "deprecatedPublicIPs": - if r.TryDecodeAsNil() { - x.DeprecatedPublicIPs = nil - } else { - yyv2543 := &x.DeprecatedPublicIPs - yym2544 := z.DecBinary() - _ = yym2544 - if false { - } else { - z.F.DecSliceStringX(yyv2543, 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 { - yyv2547 := &x.LoadBalancerSourceRanges - yym2548 := z.DecBinary() - _ = yym2548 - if false { - } else { - z.F.DecSliceStringX(yyv2547, false, d) - } - } - case "externalName": - if r.TryDecodeAsNil() { - x.ExternalName = "" - } else { - x.ExternalName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys2534) - } // end switch yys2534 - } // end for yyj2534 - 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 yyj2550 int - var yyb2550 bool - var yyhl2550 bool = l >= 0 - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2551 := &x.Ports - yym2552 := z.DecBinary() - _ = yym2552 - if false { - } else { - h.decSliceServicePort((*[]ServicePort)(yyv2551), d) - } - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2553 := &x.Selector - yym2554 := z.DecBinary() - _ = yym2554 - if false { - } else { - z.F.DecMapStringStringX(yyv2553, false, d) - } - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterIP = "" - } else { - x.ClusterIP = string(r.DecodeString()) - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ServiceType(r.DecodeString()) - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalIPs = nil - } else { - yyv2557 := &x.ExternalIPs - yym2558 := z.DecBinary() - _ = yym2558 - if false { - } else { - z.F.DecSliceStringX(yyv2557, false, d) - } - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DeprecatedPublicIPs = nil - } else { - yyv2559 := &x.DeprecatedPublicIPs - yym2560 := z.DecBinary() - _ = yym2560 - if false { - } else { - z.F.DecSliceStringX(yyv2559, false, d) - } - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SessionAffinity = "" - } else { - x.SessionAffinity = ServiceAffinity(r.DecodeString()) - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancerIP = "" - } else { - x.LoadBalancerIP = string(r.DecodeString()) - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancerSourceRanges = nil - } else { - yyv2563 := &x.LoadBalancerSourceRanges - yym2564 := z.DecBinary() - _ = yym2564 - if false { - } else { - z.F.DecSliceStringX(yyv2563, false, d) - } - } - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalName = "" - } else { - x.ExternalName = string(r.DecodeString()) - } - for { - yyj2550++ - if yyhl2550 { - yyb2550 = yyj2550 > l - } else { - yyb2550 = r.CheckBreak() - } - if yyb2550 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2550-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 { - yym2566 := z.EncBinary() - _ = yym2566 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2567 := !z.EncBinary() - yy2arr2567 := z.EncBasicHandle().StructToArray - var yyq2567 [5]bool - _, _, _ = yysep2567, yyq2567, yy2arr2567 - const yyr2567 bool = false - yyq2567[0] = x.Name != "" - yyq2567[1] = x.Protocol != "" - yyq2567[3] = true - yyq2567[4] = x.NodePort != 0 - var yynn2567 int - if yyr2567 || yy2arr2567 { - r.EncodeArrayStart(5) - } else { - yynn2567 = 1 - for _, b := range yyq2567 { - if b { - yynn2567++ - } - } - r.EncodeMapStart(yynn2567) - yynn2567 = 0 - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[0] { - yym2569 := z.EncBinary() - _ = yym2569 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2567[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2570 := z.EncBinary() - _ = yym2570 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[1] { - x.Protocol.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2567[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2573 := z.EncBinary() - _ = yym2573 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2574 := z.EncBinary() - _ = yym2574 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[3] { - yy2576 := &x.TargetPort - yym2577 := z.EncBinary() - _ = yym2577 - if false { - } else if z.HasExtensions() && z.EncExt(yy2576) { - } else if !yym2577 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2576) - } else { - z.EncFallback(yy2576) - } - } else { - r.EncodeNil() - } - } else { - if yyq2567[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("targetPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2578 := &x.TargetPort - yym2579 := z.EncBinary() - _ = yym2579 - if false { - } else if z.HasExtensions() && z.EncExt(yy2578) { - } else if !yym2579 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2578) - } else { - z.EncFallback(yy2578) - } - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[4] { - yym2581 := z.EncBinary() - _ = yym2581 - if false { - } else { - r.EncodeInt(int64(x.NodePort)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2567[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodePort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2582 := z.EncBinary() - _ = yym2582 - if false { - } else { - r.EncodeInt(int64(x.NodePort)) - } - } - } - if yyr2567 || yy2arr2567 { - 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 - yym2583 := z.DecBinary() - _ = yym2583 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2584 := r.ContainerType() - if yyct2584 == codecSelferValueTypeMap1234 { - yyl2584 := r.ReadMapStart() - if yyl2584 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2584, d) - } - } else if yyct2584 == codecSelferValueTypeArray1234 { - yyl2584 := r.ReadArrayStart() - if yyl2584 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2584, 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 yys2585Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2585Slc - var yyhl2585 bool = l >= 0 - for yyj2585 := 0; ; yyj2585++ { - if yyhl2585 { - if yyj2585 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2585Slc = r.DecodeBytes(yys2585Slc, true, true) - yys2585 := string(yys2585Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2585 { - 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 { - yyv2589 := &x.TargetPort - yym2590 := z.DecBinary() - _ = yym2590 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2589) { - } else if !yym2590 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2589) - } else { - z.DecFallback(yyv2589, false) - } - } - case "nodePort": - if r.TryDecodeAsNil() { - x.NodePort = 0 - } else { - x.NodePort = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys2585) - } // end switch yys2585 - } // end for yyj2585 - 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 yyj2592 int - var yyb2592 bool - var yyhl2592 bool = l >= 0 - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetPort = pkg4_intstr.IntOrString{} - } else { - yyv2596 := &x.TargetPort - yym2597 := z.DecBinary() - _ = yym2597 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2596) { - } else if !yym2597 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2596) - } else { - z.DecFallback(yyv2596, false) - } - } - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodePort = 0 - } else { - x.NodePort = int32(r.DecodeInt(32)) - } - for { - yyj2592++ - if yyhl2592 { - yyb2592 = yyj2592 > l - } else { - yyb2592 = r.CheckBreak() - } - if yyb2592 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2592-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 { - yym2599 := z.EncBinary() - _ = yym2599 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2600 := !z.EncBinary() - yy2arr2600 := z.EncBasicHandle().StructToArray - var yyq2600 [5]bool - _, _, _ = yysep2600, yyq2600, yy2arr2600 - const yyr2600 bool = false - yyq2600[0] = x.Kind != "" - yyq2600[1] = x.APIVersion != "" - yyq2600[2] = true - yyq2600[3] = true - yyq2600[4] = true - var yynn2600 int - if yyr2600 || yy2arr2600 { - r.EncodeArrayStart(5) - } else { - yynn2600 = 0 - for _, b := range yyq2600 { - if b { - yynn2600++ - } - } - r.EncodeMapStart(yynn2600) - yynn2600 = 0 - } - if yyr2600 || yy2arr2600 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2600[0] { - yym2602 := z.EncBinary() - _ = yym2602 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2600[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2603 := z.EncBinary() - _ = yym2603 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2600 || yy2arr2600 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2600[1] { - yym2605 := z.EncBinary() - _ = yym2605 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2600[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2606 := z.EncBinary() - _ = yym2606 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2600 || yy2arr2600 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2600[2] { - yy2608 := &x.ObjectMeta - yy2608.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2600[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2609 := &x.ObjectMeta - yy2609.CodecEncodeSelf(e) - } - } - if yyr2600 || yy2arr2600 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2600[3] { - yy2611 := &x.Spec - yy2611.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2600[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2612 := &x.Spec - yy2612.CodecEncodeSelf(e) - } - } - if yyr2600 || yy2arr2600 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2600[4] { - yy2614 := &x.Status - yy2614.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2600[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2615 := &x.Status - yy2615.CodecEncodeSelf(e) - } - } - if yyr2600 || yy2arr2600 { - 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 - yym2616 := z.DecBinary() - _ = yym2616 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2617 := r.ContainerType() - if yyct2617 == codecSelferValueTypeMap1234 { - yyl2617 := r.ReadMapStart() - if yyl2617 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2617, d) - } - } else if yyct2617 == codecSelferValueTypeArray1234 { - yyl2617 := r.ReadArrayStart() - if yyl2617 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2617, 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 yys2618Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2618Slc - var yyhl2618 bool = l >= 0 - for yyj2618 := 0; ; yyj2618++ { - if yyhl2618 { - if yyj2618 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2618Slc = r.DecodeBytes(yys2618Slc, true, true) - yys2618 := string(yys2618Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2618 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2621 := &x.ObjectMeta - yyv2621.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ServiceSpec{} - } else { - yyv2622 := &x.Spec - yyv2622.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ServiceStatus{} - } else { - yyv2623 := &x.Status - yyv2623.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2618) - } // end switch yys2618 - } // end for yyj2618 - 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 yyj2624 int - var yyb2624 bool - var yyhl2624 bool = l >= 0 - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2627 := &x.ObjectMeta - yyv2627.CodecDecodeSelf(d) - } - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ServiceSpec{} - } else { - yyv2628 := &x.Spec - yyv2628.CodecDecodeSelf(d) - } - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ServiceStatus{} - } else { - yyv2629 := &x.Status - yyv2629.CodecDecodeSelf(d) - } - for { - yyj2624++ - if yyhl2624 { - yyb2624 = yyj2624 > l - } else { - yyb2624 = r.CheckBreak() - } - if yyb2624 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2624-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 { - yym2630 := z.EncBinary() - _ = yym2630 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2631 := !z.EncBinary() - yy2arr2631 := z.EncBasicHandle().StructToArray - var yyq2631 [4]bool - _, _, _ = yysep2631, yyq2631, yy2arr2631 - const yyr2631 bool = false - yyq2631[0] = x.Kind != "" - yyq2631[1] = x.APIVersion != "" - yyq2631[2] = true - var yynn2631 int - if yyr2631 || yy2arr2631 { - r.EncodeArrayStart(4) - } else { - yynn2631 = 1 - for _, b := range yyq2631 { - if b { - yynn2631++ - } - } - r.EncodeMapStart(yynn2631) - yynn2631 = 0 - } - if yyr2631 || yy2arr2631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2631[0] { - yym2633 := z.EncBinary() - _ = yym2633 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2631[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2634 := z.EncBinary() - _ = yym2634 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2631 || yy2arr2631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2631[1] { - yym2636 := z.EncBinary() - _ = yym2636 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2631[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2637 := z.EncBinary() - _ = yym2637 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2631 || yy2arr2631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2631[2] { - yy2639 := &x.ListMeta - yym2640 := z.EncBinary() - _ = yym2640 - if false { - } else if z.HasExtensions() && z.EncExt(yy2639) { - } else { - z.EncFallback(yy2639) - } - } else { - r.EncodeNil() - } - } else { - if yyq2631[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2641 := &x.ListMeta - yym2642 := z.EncBinary() - _ = yym2642 - if false { - } else if z.HasExtensions() && z.EncExt(yy2641) { - } else { - z.EncFallback(yy2641) - } - } - } - if yyr2631 || yy2arr2631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2644 := z.EncBinary() - _ = yym2644 - 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 { - yym2645 := z.EncBinary() - _ = yym2645 - if false { - } else { - h.encSliceService(([]Service)(x.Items), e) - } - } - } - if yyr2631 || yy2arr2631 { - 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 - yym2646 := z.DecBinary() - _ = yym2646 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2647 := r.ContainerType() - if yyct2647 == codecSelferValueTypeMap1234 { - yyl2647 := r.ReadMapStart() - if yyl2647 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2647, d) - } - } else if yyct2647 == codecSelferValueTypeArray1234 { - yyl2647 := r.ReadArrayStart() - if yyl2647 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2647, 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 yys2648Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2648Slc - var yyhl2648 bool = l >= 0 - for yyj2648 := 0; ; yyj2648++ { - if yyhl2648 { - if yyj2648 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2648Slc = r.DecodeBytes(yys2648Slc, true, true) - yys2648 := string(yys2648Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2648 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2651 := &x.ListMeta - yym2652 := z.DecBinary() - _ = yym2652 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2651) { - } else { - z.DecFallback(yyv2651, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2653 := &x.Items - yym2654 := z.DecBinary() - _ = yym2654 - if false { - } else { - h.decSliceService((*[]Service)(yyv2653), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2648) - } // end switch yys2648 - } // end for yyj2648 - 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 yyj2655 int - var yyb2655 bool - var yyhl2655 bool = l >= 0 - yyj2655++ - if yyhl2655 { - yyb2655 = yyj2655 > l - } else { - yyb2655 = r.CheckBreak() - } - if yyb2655 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2655++ - if yyhl2655 { - yyb2655 = yyj2655 > l - } else { - yyb2655 = r.CheckBreak() - } - if yyb2655 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2655++ - if yyhl2655 { - yyb2655 = yyj2655 > l - } else { - yyb2655 = r.CheckBreak() - } - if yyb2655 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2658 := &x.ListMeta - yym2659 := z.DecBinary() - _ = yym2659 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2658) { - } else { - z.DecFallback(yyv2658, false) - } - } - yyj2655++ - if yyhl2655 { - yyb2655 = yyj2655 > l - } else { - yyb2655 = r.CheckBreak() - } - if yyb2655 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2660 := &x.Items - yym2661 := z.DecBinary() - _ = yym2661 - if false { - } else { - h.decSliceService((*[]Service)(yyv2660), d) - } - } - for { - yyj2655++ - if yyhl2655 { - yyb2655 = yyj2655 > l - } else { - yyb2655 = r.CheckBreak() - } - if yyb2655 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2655-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 { - yym2662 := z.EncBinary() - _ = yym2662 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2663 := !z.EncBinary() - yy2arr2663 := z.EncBasicHandle().StructToArray - var yyq2663 [5]bool - _, _, _ = yysep2663, yyq2663, yy2arr2663 - const yyr2663 bool = false - yyq2663[0] = x.Kind != "" - yyq2663[1] = x.APIVersion != "" - yyq2663[2] = true - yyq2663[3] = len(x.Secrets) != 0 - yyq2663[4] = len(x.ImagePullSecrets) != 0 - var yynn2663 int - if yyr2663 || yy2arr2663 { - r.EncodeArrayStart(5) - } else { - yynn2663 = 0 - for _, b := range yyq2663 { - if b { - yynn2663++ - } - } - r.EncodeMapStart(yynn2663) - yynn2663 = 0 - } - if yyr2663 || yy2arr2663 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2663[0] { - yym2665 := z.EncBinary() - _ = yym2665 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2663[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2666 := z.EncBinary() - _ = yym2666 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2663 || yy2arr2663 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2663[1] { - yym2668 := z.EncBinary() - _ = yym2668 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2663[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2669 := z.EncBinary() - _ = yym2669 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2663 || yy2arr2663 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2663[2] { - yy2671 := &x.ObjectMeta - yy2671.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2663[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2672 := &x.ObjectMeta - yy2672.CodecEncodeSelf(e) - } - } - if yyr2663 || yy2arr2663 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2663[3] { - if x.Secrets == nil { - r.EncodeNil() - } else { - yym2674 := z.EncBinary() - _ = yym2674 - if false { - } else { - h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2663[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Secrets == nil { - r.EncodeNil() - } else { - yym2675 := z.EncBinary() - _ = yym2675 - if false { - } else { - h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) - } - } - } - } - if yyr2663 || yy2arr2663 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2663[4] { - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2677 := z.EncBinary() - _ = yym2677 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2663[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2678 := z.EncBinary() - _ = yym2678 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } - } - if yyr2663 || yy2arr2663 { - 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 - yym2679 := z.DecBinary() - _ = yym2679 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2680 := r.ContainerType() - if yyct2680 == codecSelferValueTypeMap1234 { - yyl2680 := r.ReadMapStart() - if yyl2680 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2680, d) - } - } else if yyct2680 == codecSelferValueTypeArray1234 { - yyl2680 := r.ReadArrayStart() - if yyl2680 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2680, 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 yys2681Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2681Slc - var yyhl2681 bool = l >= 0 - for yyj2681 := 0; ; yyj2681++ { - if yyhl2681 { - if yyj2681 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2681Slc = r.DecodeBytes(yys2681Slc, true, true) - yys2681 := string(yys2681Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2681 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2684 := &x.ObjectMeta - yyv2684.CodecDecodeSelf(d) - } - case "secrets": - if r.TryDecodeAsNil() { - x.Secrets = nil - } else { - yyv2685 := &x.Secrets - yym2686 := z.DecBinary() - _ = yym2686 - if false { - } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2685), d) - } - } - case "imagePullSecrets": - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2687 := &x.ImagePullSecrets - yym2688 := z.DecBinary() - _ = yym2688 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2687), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2681) - } // end switch yys2681 - } // end for yyj2681 - 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 yyj2689 int - var yyb2689 bool - var yyhl2689 bool = l >= 0 - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2692 := &x.ObjectMeta - yyv2692.CodecDecodeSelf(d) - } - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Secrets = nil - } else { - yyv2693 := &x.Secrets - yym2694 := z.DecBinary() - _ = yym2694 - if false { - } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2693), d) - } - } - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2695 := &x.ImagePullSecrets - yym2696 := z.DecBinary() - _ = yym2696 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2695), d) - } - } - for { - yyj2689++ - if yyhl2689 { - yyb2689 = yyj2689 > l - } else { - yyb2689 = r.CheckBreak() - } - if yyb2689 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2689-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 { - yym2697 := z.EncBinary() - _ = yym2697 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2698 := !z.EncBinary() - yy2arr2698 := z.EncBasicHandle().StructToArray - var yyq2698 [4]bool - _, _, _ = yysep2698, yyq2698, yy2arr2698 - const yyr2698 bool = false - yyq2698[0] = x.Kind != "" - yyq2698[1] = x.APIVersion != "" - yyq2698[2] = true - var yynn2698 int - if yyr2698 || yy2arr2698 { - r.EncodeArrayStart(4) - } else { - yynn2698 = 1 - for _, b := range yyq2698 { - if b { - yynn2698++ - } - } - r.EncodeMapStart(yynn2698) - yynn2698 = 0 - } - if yyr2698 || yy2arr2698 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2698[0] { - yym2700 := z.EncBinary() - _ = yym2700 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2698[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2701 := z.EncBinary() - _ = yym2701 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2698 || yy2arr2698 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2698[1] { - yym2703 := z.EncBinary() - _ = yym2703 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2698[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2704 := z.EncBinary() - _ = yym2704 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2698 || yy2arr2698 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2698[2] { - yy2706 := &x.ListMeta - yym2707 := z.EncBinary() - _ = yym2707 - if false { - } else if z.HasExtensions() && z.EncExt(yy2706) { - } else { - z.EncFallback(yy2706) - } - } else { - r.EncodeNil() - } - } else { - if yyq2698[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2708 := &x.ListMeta - yym2709 := z.EncBinary() - _ = yym2709 - if false { - } else if z.HasExtensions() && z.EncExt(yy2708) { - } else { - z.EncFallback(yy2708) - } - } - } - if yyr2698 || yy2arr2698 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2711 := z.EncBinary() - _ = yym2711 - 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 { - yym2712 := z.EncBinary() - _ = yym2712 - if false { - } else { - h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e) - } - } - } - if yyr2698 || yy2arr2698 { - 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 - yym2713 := z.DecBinary() - _ = yym2713 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2714 := r.ContainerType() - if yyct2714 == codecSelferValueTypeMap1234 { - yyl2714 := r.ReadMapStart() - if yyl2714 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2714, d) - } - } else if yyct2714 == codecSelferValueTypeArray1234 { - yyl2714 := r.ReadArrayStart() - if yyl2714 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2714, 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 yys2715Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2715Slc - var yyhl2715 bool = l >= 0 - for yyj2715 := 0; ; yyj2715++ { - if yyhl2715 { - if yyj2715 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2715Slc = r.DecodeBytes(yys2715Slc, true, true) - yys2715 := string(yys2715Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2715 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2718 := &x.ListMeta - yym2719 := z.DecBinary() - _ = yym2719 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2718) { - } else { - z.DecFallback(yyv2718, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2720 := &x.Items - yym2721 := z.DecBinary() - _ = yym2721 - if false { - } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2720), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2715) - } // end switch yys2715 - } // end for yyj2715 - 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 yyj2722 int - var yyb2722 bool - var yyhl2722 bool = l >= 0 - yyj2722++ - if yyhl2722 { - yyb2722 = yyj2722 > l - } else { - yyb2722 = r.CheckBreak() - } - if yyb2722 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2722++ - if yyhl2722 { - yyb2722 = yyj2722 > l - } else { - yyb2722 = r.CheckBreak() - } - if yyb2722 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2722++ - if yyhl2722 { - yyb2722 = yyj2722 > l - } else { - yyb2722 = r.CheckBreak() - } - if yyb2722 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2725 := &x.ListMeta - yym2726 := z.DecBinary() - _ = yym2726 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2725) { - } else { - z.DecFallback(yyv2725, false) - } - } - yyj2722++ - if yyhl2722 { - yyb2722 = yyj2722 > l - } else { - yyb2722 = r.CheckBreak() - } - if yyb2722 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2727 := &x.Items - yym2728 := z.DecBinary() - _ = yym2728 - if false { - } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2727), d) - } - } - for { - yyj2722++ - if yyhl2722 { - yyb2722 = yyj2722 > l - } else { - yyb2722 = r.CheckBreak() - } - if yyb2722 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2722-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 { - yym2729 := z.EncBinary() - _ = yym2729 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2730 := !z.EncBinary() - yy2arr2730 := z.EncBasicHandle().StructToArray - var yyq2730 [4]bool - _, _, _ = yysep2730, yyq2730, yy2arr2730 - const yyr2730 bool = false - yyq2730[0] = x.Kind != "" - yyq2730[1] = x.APIVersion != "" - yyq2730[2] = true - var yynn2730 int - if yyr2730 || yy2arr2730 { - r.EncodeArrayStart(4) - } else { - yynn2730 = 1 - for _, b := range yyq2730 { - if b { - yynn2730++ - } - } - r.EncodeMapStart(yynn2730) - yynn2730 = 0 - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2730[0] { - yym2732 := z.EncBinary() - _ = yym2732 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2730[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2733 := z.EncBinary() - _ = yym2733 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2730[1] { - yym2735 := z.EncBinary() - _ = yym2735 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2730[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2736 := z.EncBinary() - _ = yym2736 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2730[2] { - yy2738 := &x.ObjectMeta - yy2738.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2730[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2739 := &x.ObjectMeta - yy2739.CodecEncodeSelf(e) - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Subsets == nil { - r.EncodeNil() - } else { - yym2741 := z.EncBinary() - _ = yym2741 - 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 { - yym2742 := z.EncBinary() - _ = yym2742 - if false { - } else { - h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e) - } - } - } - if yyr2730 || yy2arr2730 { - 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 - yym2743 := z.DecBinary() - _ = yym2743 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2744 := r.ContainerType() - if yyct2744 == codecSelferValueTypeMap1234 { - yyl2744 := r.ReadMapStart() - if yyl2744 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2744, d) - } - } else if yyct2744 == codecSelferValueTypeArray1234 { - yyl2744 := r.ReadArrayStart() - if yyl2744 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2744, 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 yys2745Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2745Slc - var yyhl2745 bool = l >= 0 - for yyj2745 := 0; ; yyj2745++ { - if yyhl2745 { - if yyj2745 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2745Slc = r.DecodeBytes(yys2745Slc, true, true) - yys2745 := string(yys2745Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2745 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2748 := &x.ObjectMeta - yyv2748.CodecDecodeSelf(d) - } - case "subsets": - if r.TryDecodeAsNil() { - x.Subsets = nil - } else { - yyv2749 := &x.Subsets - yym2750 := z.DecBinary() - _ = yym2750 - if false { - } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2749), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2745) - } // end switch yys2745 - } // end for yyj2745 - 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 yyj2751 int - var yyb2751 bool - var yyhl2751 bool = l >= 0 - yyj2751++ - if yyhl2751 { - yyb2751 = yyj2751 > l - } else { - yyb2751 = r.CheckBreak() - } - if yyb2751 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2751++ - if yyhl2751 { - yyb2751 = yyj2751 > l - } else { - yyb2751 = r.CheckBreak() - } - if yyb2751 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2751++ - if yyhl2751 { - yyb2751 = yyj2751 > l - } else { - yyb2751 = r.CheckBreak() - } - if yyb2751 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2754 := &x.ObjectMeta - yyv2754.CodecDecodeSelf(d) - } - yyj2751++ - if yyhl2751 { - yyb2751 = yyj2751 > l - } else { - yyb2751 = r.CheckBreak() - } - if yyb2751 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Subsets = nil - } else { - yyv2755 := &x.Subsets - yym2756 := z.DecBinary() - _ = yym2756 - if false { - } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2755), d) - } - } - for { - yyj2751++ - if yyhl2751 { - yyb2751 = yyj2751 > l - } else { - yyb2751 = r.CheckBreak() - } - if yyb2751 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2751-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 { - yym2757 := z.EncBinary() - _ = yym2757 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2758 := !z.EncBinary() - yy2arr2758 := z.EncBasicHandle().StructToArray - var yyq2758 [3]bool - _, _, _ = yysep2758, yyq2758, yy2arr2758 - const yyr2758 bool = false - yyq2758[0] = len(x.Addresses) != 0 - yyq2758[1] = len(x.NotReadyAddresses) != 0 - yyq2758[2] = len(x.Ports) != 0 - var yynn2758 int - if yyr2758 || yy2arr2758 { - r.EncodeArrayStart(3) - } else { - yynn2758 = 0 - for _, b := range yyq2758 { - if b { - yynn2758++ - } - } - r.EncodeMapStart(yynn2758) - yynn2758 = 0 - } - if yyr2758 || yy2arr2758 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2758[0] { - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2760 := z.EncBinary() - _ = yym2760 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2758[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("addresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2761 := z.EncBinary() - _ = yym2761 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) - } - } - } - } - if yyr2758 || yy2arr2758 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2758[1] { - if x.NotReadyAddresses == nil { - r.EncodeNil() - } else { - yym2763 := z.EncBinary() - _ = yym2763 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2758[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("notReadyAddresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NotReadyAddresses == nil { - r.EncodeNil() - } else { - yym2764 := z.EncBinary() - _ = yym2764 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) - } - } - } - } - if yyr2758 || yy2arr2758 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2758[2] { - if x.Ports == nil { - r.EncodeNil() - } else { - yym2766 := z.EncBinary() - _ = yym2766 - if false { - } else { - h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2758[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ports")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2767 := z.EncBinary() - _ = yym2767 - if false { - } else { - h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e) - } - } - } - } - if yyr2758 || yy2arr2758 { - 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 - yym2768 := z.DecBinary() - _ = yym2768 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2769 := r.ContainerType() - if yyct2769 == codecSelferValueTypeMap1234 { - yyl2769 := r.ReadMapStart() - if yyl2769 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2769, d) - } - } else if yyct2769 == codecSelferValueTypeArray1234 { - yyl2769 := r.ReadArrayStart() - if yyl2769 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2769, 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 yys2770Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2770Slc - var yyhl2770 bool = l >= 0 - for yyj2770 := 0; ; yyj2770++ { - if yyhl2770 { - if yyj2770 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2770Slc = r.DecodeBytes(yys2770Slc, true, true) - yys2770 := string(yys2770Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2770 { - case "addresses": - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv2771 := &x.Addresses - yym2772 := z.DecBinary() - _ = yym2772 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2771), d) - } - } - case "notReadyAddresses": - if r.TryDecodeAsNil() { - x.NotReadyAddresses = nil - } else { - yyv2773 := &x.NotReadyAddresses - yym2774 := z.DecBinary() - _ = yym2774 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2773), d) - } - } - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2775 := &x.Ports - yym2776 := z.DecBinary() - _ = yym2776 - if false { - } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2775), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2770) - } // end switch yys2770 - } // end for yyj2770 - 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 yyj2777 int - var yyb2777 bool - var yyhl2777 bool = l >= 0 - yyj2777++ - if yyhl2777 { - yyb2777 = yyj2777 > l - } else { - yyb2777 = r.CheckBreak() - } - if yyb2777 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv2778 := &x.Addresses - yym2779 := z.DecBinary() - _ = yym2779 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2778), d) - } - } - yyj2777++ - if yyhl2777 { - yyb2777 = yyj2777 > l - } else { - yyb2777 = r.CheckBreak() - } - if yyb2777 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NotReadyAddresses = nil - } else { - yyv2780 := &x.NotReadyAddresses - yym2781 := z.DecBinary() - _ = yym2781 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2780), d) - } - } - yyj2777++ - if yyhl2777 { - yyb2777 = yyj2777 > l - } else { - yyb2777 = r.CheckBreak() - } - if yyb2777 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2782 := &x.Ports - yym2783 := z.DecBinary() - _ = yym2783 - if false { - } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2782), d) - } - } - for { - yyj2777++ - if yyhl2777 { - yyb2777 = yyj2777 > l - } else { - yyb2777 = r.CheckBreak() - } - if yyb2777 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2777-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 { - yym2784 := z.EncBinary() - _ = yym2784 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2785 := !z.EncBinary() - yy2arr2785 := z.EncBasicHandle().StructToArray - var yyq2785 [4]bool - _, _, _ = yysep2785, yyq2785, yy2arr2785 - const yyr2785 bool = false - yyq2785[1] = x.Hostname != "" - yyq2785[2] = x.NodeName != nil - yyq2785[3] = x.TargetRef != nil - var yynn2785 int - if yyr2785 || yy2arr2785 { - r.EncodeArrayStart(4) - } else { - yynn2785 = 1 - for _, b := range yyq2785 { - if b { - yynn2785++ - } - } - r.EncodeMapStart(yynn2785) - yynn2785 = 0 - } - if yyr2785 || yy2arr2785 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2787 := z.EncBinary() - _ = yym2787 - 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) - yym2788 := z.EncBinary() - _ = yym2788 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } - if yyr2785 || yy2arr2785 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2785[1] { - yym2790 := z.EncBinary() - _ = yym2790 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2785[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2791 := z.EncBinary() - _ = yym2791 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr2785 || yy2arr2785 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2785[2] { - if x.NodeName == nil { - r.EncodeNil() - } else { - yy2793 := *x.NodeName - yym2794 := z.EncBinary() - _ = yym2794 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2793)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2785[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NodeName == nil { - r.EncodeNil() - } else { - yy2795 := *x.NodeName - yym2796 := z.EncBinary() - _ = yym2796 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2795)) - } - } - } - } - if yyr2785 || yy2arr2785 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2785[3] { - if x.TargetRef == nil { - r.EncodeNil() - } else { - x.TargetRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2785[3] { - 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 yyr2785 || yy2arr2785 { - 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 - yym2798 := z.DecBinary() - _ = yym2798 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2799 := r.ContainerType() - if yyct2799 == codecSelferValueTypeMap1234 { - yyl2799 := r.ReadMapStart() - if yyl2799 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2799, d) - } - } else if yyct2799 == codecSelferValueTypeArray1234 { - yyl2799 := r.ReadArrayStart() - if yyl2799 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2799, 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 yys2800Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2800Slc - var yyhl2800 bool = l >= 0 - for yyj2800 := 0; ; yyj2800++ { - if yyhl2800 { - if yyj2800 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2800Slc = r.DecodeBytes(yys2800Slc, true, true) - yys2800 := string(yys2800Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2800 { - 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 "nodeName": - if r.TryDecodeAsNil() { - if x.NodeName != nil { - x.NodeName = nil - } - } else { - if x.NodeName == nil { - x.NodeName = new(string) - } - yym2804 := z.DecBinary() - _ = yym2804 - if false { - } else { - *((*string)(x.NodeName)) = 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, yys2800) - } // end switch yys2800 - } // end for yyj2800 - 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 yyj2806 int - var yyb2806 bool - var yyhl2806 bool = l >= 0 - yyj2806++ - if yyhl2806 { - yyb2806 = yyj2806 > l - } else { - yyb2806 = r.CheckBreak() - } - if yyb2806 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IP = "" - } else { - x.IP = string(r.DecodeString()) - } - yyj2806++ - if yyhl2806 { - yyb2806 = yyj2806 > l - } else { - yyb2806 = r.CheckBreak() - } - if yyb2806 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - yyj2806++ - if yyhl2806 { - yyb2806 = yyj2806 > l - } else { - yyb2806 = r.CheckBreak() - } - if yyb2806 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.NodeName != nil { - x.NodeName = nil - } - } else { - if x.NodeName == nil { - x.NodeName = new(string) - } - yym2810 := z.DecBinary() - _ = yym2810 - if false { - } else { - *((*string)(x.NodeName)) = r.DecodeString() - } - } - yyj2806++ - if yyhl2806 { - yyb2806 = yyj2806 > l - } else { - yyb2806 = r.CheckBreak() - } - if yyb2806 { - 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 { - yyj2806++ - if yyhl2806 { - yyb2806 = yyj2806 > l - } else { - yyb2806 = r.CheckBreak() - } - if yyb2806 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2806-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 { - yym2812 := z.EncBinary() - _ = yym2812 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2813 := !z.EncBinary() - yy2arr2813 := z.EncBasicHandle().StructToArray - var yyq2813 [3]bool - _, _, _ = yysep2813, yyq2813, yy2arr2813 - const yyr2813 bool = false - yyq2813[0] = x.Name != "" - yyq2813[2] = x.Protocol != "" - var yynn2813 int - if yyr2813 || yy2arr2813 { - r.EncodeArrayStart(3) - } else { - yynn2813 = 1 - for _, b := range yyq2813 { - if b { - yynn2813++ - } - } - r.EncodeMapStart(yynn2813) - yynn2813 = 0 - } - if yyr2813 || yy2arr2813 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2813[0] { - yym2815 := z.EncBinary() - _ = yym2815 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2813[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2816 := z.EncBinary() - _ = yym2816 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr2813 || yy2arr2813 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2818 := z.EncBinary() - _ = yym2818 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2819 := z.EncBinary() - _ = yym2819 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr2813 || yy2arr2813 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2813[2] { - x.Protocol.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2813[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - } - if yyr2813 || yy2arr2813 { - 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 - yym2821 := z.DecBinary() - _ = yym2821 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2822 := r.ContainerType() - if yyct2822 == codecSelferValueTypeMap1234 { - yyl2822 := r.ReadMapStart() - if yyl2822 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2822, d) - } - } else if yyct2822 == codecSelferValueTypeArray1234 { - yyl2822 := r.ReadArrayStart() - if yyl2822 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2822, 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 yys2823Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2823Slc - var yyhl2823 bool = l >= 0 - for yyj2823 := 0; ; yyj2823++ { - if yyhl2823 { - if yyj2823 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2823Slc = r.DecodeBytes(yys2823Slc, true, true) - yys2823 := string(yys2823Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2823 { - 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, yys2823) - } // end switch yys2823 - } // end for yyj2823 - 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 yyj2827 int - var yyb2827 bool - var yyhl2827 bool = l >= 0 - yyj2827++ - if yyhl2827 { - yyb2827 = yyj2827 > l - } else { - yyb2827 = r.CheckBreak() - } - if yyb2827 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj2827++ - if yyhl2827 { - yyb2827 = yyj2827 > l - } else { - yyb2827 = r.CheckBreak() - } - if yyb2827 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - yyj2827++ - if yyhl2827 { - yyb2827 = yyj2827 > l - } else { - yyb2827 = r.CheckBreak() - } - if yyb2827 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - for { - yyj2827++ - if yyhl2827 { - yyb2827 = yyj2827 > l - } else { - yyb2827 = r.CheckBreak() - } - if yyb2827 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2827-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 { - yym2831 := z.EncBinary() - _ = yym2831 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2832 := !z.EncBinary() - yy2arr2832 := z.EncBasicHandle().StructToArray - var yyq2832 [4]bool - _, _, _ = yysep2832, yyq2832, yy2arr2832 - const yyr2832 bool = false - yyq2832[0] = x.Kind != "" - yyq2832[1] = x.APIVersion != "" - yyq2832[2] = true - var yynn2832 int - if yyr2832 || yy2arr2832 { - r.EncodeArrayStart(4) - } else { - yynn2832 = 1 - for _, b := range yyq2832 { - if b { - yynn2832++ - } - } - r.EncodeMapStart(yynn2832) - yynn2832 = 0 - } - if yyr2832 || yy2arr2832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2832[0] { - yym2834 := z.EncBinary() - _ = yym2834 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2832[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2835 := z.EncBinary() - _ = yym2835 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2832 || yy2arr2832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2832[1] { - yym2837 := z.EncBinary() - _ = yym2837 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2832[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2838 := z.EncBinary() - _ = yym2838 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2832 || yy2arr2832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2832[2] { - yy2840 := &x.ListMeta - yym2841 := z.EncBinary() - _ = yym2841 - if false { - } else if z.HasExtensions() && z.EncExt(yy2840) { - } else { - z.EncFallback(yy2840) - } - } else { - r.EncodeNil() - } - } else { - if yyq2832[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2842 := &x.ListMeta - yym2843 := z.EncBinary() - _ = yym2843 - if false { - } else if z.HasExtensions() && z.EncExt(yy2842) { - } else { - z.EncFallback(yy2842) - } - } - } - if yyr2832 || yy2arr2832 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2845 := z.EncBinary() - _ = yym2845 - 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 { - yym2846 := z.EncBinary() - _ = yym2846 - if false { - } else { - h.encSliceEndpoints(([]Endpoints)(x.Items), e) - } - } - } - if yyr2832 || yy2arr2832 { - 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 - yym2847 := z.DecBinary() - _ = yym2847 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2848 := r.ContainerType() - if yyct2848 == codecSelferValueTypeMap1234 { - yyl2848 := r.ReadMapStart() - if yyl2848 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2848, d) - } - } else if yyct2848 == codecSelferValueTypeArray1234 { - yyl2848 := r.ReadArrayStart() - if yyl2848 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2848, 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 yys2849Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2849Slc - var yyhl2849 bool = l >= 0 - for yyj2849 := 0; ; yyj2849++ { - if yyhl2849 { - if yyj2849 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2849Slc = r.DecodeBytes(yys2849Slc, true, true) - yys2849 := string(yys2849Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2849 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2852 := &x.ListMeta - yym2853 := z.DecBinary() - _ = yym2853 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2852) { - } else { - z.DecFallback(yyv2852, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2854 := &x.Items - yym2855 := z.DecBinary() - _ = yym2855 - if false { - } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2854), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2849) - } // end switch yys2849 - } // end for yyj2849 - 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 yyj2856 int - var yyb2856 bool - var yyhl2856 bool = l >= 0 - yyj2856++ - if yyhl2856 { - yyb2856 = yyj2856 > l - } else { - yyb2856 = r.CheckBreak() - } - if yyb2856 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2856++ - if yyhl2856 { - yyb2856 = yyj2856 > l - } else { - yyb2856 = r.CheckBreak() - } - if yyb2856 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2856++ - if yyhl2856 { - yyb2856 = yyj2856 > l - } else { - yyb2856 = r.CheckBreak() - } - if yyb2856 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2859 := &x.ListMeta - yym2860 := z.DecBinary() - _ = yym2860 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2859) { - } else { - z.DecFallback(yyv2859, false) - } - } - yyj2856++ - if yyhl2856 { - yyb2856 = yyj2856 > l - } else { - yyb2856 = r.CheckBreak() - } - if yyb2856 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2861 := &x.Items - yym2862 := z.DecBinary() - _ = yym2862 - if false { - } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2861), d) - } - } - for { - yyj2856++ - if yyhl2856 { - yyb2856 = yyj2856 > l - } else { - yyb2856 = r.CheckBreak() - } - if yyb2856 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2856-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 { - yym2863 := z.EncBinary() - _ = yym2863 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2864 := !z.EncBinary() - yy2arr2864 := z.EncBasicHandle().StructToArray - var yyq2864 [4]bool - _, _, _ = yysep2864, yyq2864, yy2arr2864 - const yyr2864 bool = false - yyq2864[0] = x.PodCIDR != "" - yyq2864[1] = x.ExternalID != "" - yyq2864[2] = x.ProviderID != "" - yyq2864[3] = x.Unschedulable != false - var yynn2864 int - if yyr2864 || yy2arr2864 { - r.EncodeArrayStart(4) - } else { - yynn2864 = 0 - for _, b := range yyq2864 { - if b { - yynn2864++ - } - } - r.EncodeMapStart(yynn2864) - yynn2864 = 0 - } - if yyr2864 || yy2arr2864 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2864[0] { - yym2866 := z.EncBinary() - _ = yym2866 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2864[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podCIDR")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2867 := z.EncBinary() - _ = yym2867 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) - } - } - } - if yyr2864 || yy2arr2864 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2864[1] { - yym2869 := z.EncBinary() - _ = yym2869 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2864[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("externalID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2870 := z.EncBinary() - _ = yym2870 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) - } - } - } - if yyr2864 || yy2arr2864 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2864[2] { - yym2872 := z.EncBinary() - _ = yym2872 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2864[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("providerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2873 := z.EncBinary() - _ = yym2873 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) - } - } - } - if yyr2864 || yy2arr2864 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2864[3] { - yym2875 := z.EncBinary() - _ = yym2875 - if false { - } else { - r.EncodeBool(bool(x.Unschedulable)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq2864[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("unschedulable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2876 := z.EncBinary() - _ = yym2876 - if false { - } else { - r.EncodeBool(bool(x.Unschedulable)) - } - } - } - if yyr2864 || yy2arr2864 { - 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 - yym2877 := z.DecBinary() - _ = yym2877 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2878 := r.ContainerType() - if yyct2878 == codecSelferValueTypeMap1234 { - yyl2878 := r.ReadMapStart() - if yyl2878 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2878, d) - } - } else if yyct2878 == codecSelferValueTypeArray1234 { - yyl2878 := r.ReadArrayStart() - if yyl2878 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2878, 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 yys2879Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2879Slc - var yyhl2879 bool = l >= 0 - for yyj2879 := 0; ; yyj2879++ { - if yyhl2879 { - if yyj2879 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2879Slc = r.DecodeBytes(yys2879Slc, true, true) - yys2879 := string(yys2879Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2879 { - 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, yys2879) - } // end switch yys2879 - } // end for yyj2879 - 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 yyj2884 int - var yyb2884 bool - var yyhl2884 bool = l >= 0 - yyj2884++ - if yyhl2884 { - yyb2884 = yyj2884 > l - } else { - yyb2884 = r.CheckBreak() - } - if yyb2884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodCIDR = "" - } else { - x.PodCIDR = string(r.DecodeString()) - } - yyj2884++ - if yyhl2884 { - yyb2884 = yyj2884 > l - } else { - yyb2884 = r.CheckBreak() - } - if yyb2884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalID = "" - } else { - x.ExternalID = string(r.DecodeString()) - } - yyj2884++ - if yyhl2884 { - yyb2884 = yyj2884 > l - } else { - yyb2884 = r.CheckBreak() - } - if yyb2884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ProviderID = "" - } else { - x.ProviderID = string(r.DecodeString()) - } - yyj2884++ - if yyhl2884 { - yyb2884 = yyj2884 > l - } else { - yyb2884 = r.CheckBreak() - } - if yyb2884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Unschedulable = false - } else { - x.Unschedulable = bool(r.DecodeBool()) - } - for { - yyj2884++ - if yyhl2884 { - yyb2884 = yyj2884 > l - } else { - yyb2884 = r.CheckBreak() - } - if yyb2884 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2884-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 { - yym2889 := z.EncBinary() - _ = yym2889 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2890 := !z.EncBinary() - yy2arr2890 := z.EncBasicHandle().StructToArray - var yyq2890 [1]bool - _, _, _ = yysep2890, yyq2890, yy2arr2890 - const yyr2890 bool = false - var yynn2890 int - if yyr2890 || yy2arr2890 { - r.EncodeArrayStart(1) - } else { - yynn2890 = 1 - for _, b := range yyq2890 { - if b { - yynn2890++ - } - } - r.EncodeMapStart(yynn2890) - yynn2890 = 0 - } - if yyr2890 || yy2arr2890 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2892 := z.EncBinary() - _ = yym2892 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2893 := z.EncBinary() - _ = yym2893 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr2890 || yy2arr2890 { - 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 - yym2894 := z.DecBinary() - _ = yym2894 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2895 := r.ContainerType() - if yyct2895 == codecSelferValueTypeMap1234 { - yyl2895 := r.ReadMapStart() - if yyl2895 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2895, d) - } - } else if yyct2895 == codecSelferValueTypeArray1234 { - yyl2895 := r.ReadArrayStart() - if yyl2895 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2895, 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 yys2896Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2896Slc - var yyhl2896 bool = l >= 0 - for yyj2896 := 0; ; yyj2896++ { - if yyhl2896 { - if yyj2896 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2896Slc = r.DecodeBytes(yys2896Slc, true, true) - yys2896 := string(yys2896Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2896 { - case "Port": - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys2896) - } // end switch yys2896 - } // end for yyj2896 - 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 yyj2898 int - var yyb2898 bool - var yyhl2898 bool = l >= 0 - yyj2898++ - if yyhl2898 { - yyb2898 = yyj2898 > l - } else { - yyb2898 = r.CheckBreak() - } - if yyb2898 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - for { - yyj2898++ - if yyhl2898 { - yyb2898 = yyj2898 > l - } else { - yyb2898 = r.CheckBreak() - } - if yyb2898 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2898-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 { - yym2900 := z.EncBinary() - _ = yym2900 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2901 := !z.EncBinary() - yy2arr2901 := z.EncBasicHandle().StructToArray - var yyq2901 [1]bool - _, _, _ = yysep2901, yyq2901, yy2arr2901 - const yyr2901 bool = false - yyq2901[0] = true - var yynn2901 int - if yyr2901 || yy2arr2901 { - r.EncodeArrayStart(1) - } else { - yynn2901 = 0 - for _, b := range yyq2901 { - if b { - yynn2901++ - } - } - r.EncodeMapStart(yynn2901) - yynn2901 = 0 - } - if yyr2901 || yy2arr2901 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2901[0] { - yy2903 := &x.KubeletEndpoint - yy2903.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2901[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kubeletEndpoint")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2904 := &x.KubeletEndpoint - yy2904.CodecEncodeSelf(e) - } - } - if yyr2901 || yy2arr2901 { - 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 - yym2905 := z.DecBinary() - _ = yym2905 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2906 := r.ContainerType() - if yyct2906 == codecSelferValueTypeMap1234 { - yyl2906 := r.ReadMapStart() - if yyl2906 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2906, d) - } - } else if yyct2906 == codecSelferValueTypeArray1234 { - yyl2906 := r.ReadArrayStart() - if yyl2906 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2906, 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 yys2907Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2907Slc - var yyhl2907 bool = l >= 0 - for yyj2907 := 0; ; yyj2907++ { - if yyhl2907 { - if yyj2907 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2907Slc = r.DecodeBytes(yys2907Slc, true, true) - yys2907 := string(yys2907Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2907 { - case "kubeletEndpoint": - if r.TryDecodeAsNil() { - x.KubeletEndpoint = DaemonEndpoint{} - } else { - yyv2908 := &x.KubeletEndpoint - yyv2908.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2907) - } // end switch yys2907 - } // end for yyj2907 - 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 yyj2909 int - var yyb2909 bool - var yyhl2909 bool = l >= 0 - yyj2909++ - if yyhl2909 { - yyb2909 = yyj2909 > l - } else { - yyb2909 = r.CheckBreak() - } - if yyb2909 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KubeletEndpoint = DaemonEndpoint{} - } else { - yyv2910 := &x.KubeletEndpoint - yyv2910.CodecDecodeSelf(d) - } - for { - yyj2909++ - if yyhl2909 { - yyb2909 = yyj2909 > l - } else { - yyb2909 = r.CheckBreak() - } - if yyb2909 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2909-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 { - yym2911 := z.EncBinary() - _ = yym2911 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2912 := !z.EncBinary() - yy2arr2912 := z.EncBasicHandle().StructToArray - var yyq2912 [10]bool - _, _, _ = yysep2912, yyq2912, yy2arr2912 - const yyr2912 bool = false - var yynn2912 int - if yyr2912 || yy2arr2912 { - r.EncodeArrayStart(10) - } else { - yynn2912 = 10 - for _, b := range yyq2912 { - if b { - yynn2912++ - } - } - r.EncodeMapStart(yynn2912) - yynn2912 = 0 - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2914 := z.EncBinary() - _ = yym2914 - 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) - yym2915 := z.EncBinary() - _ = yym2915 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MachineID)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2917 := z.EncBinary() - _ = yym2917 - 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) - yym2918 := z.EncBinary() - _ = yym2918 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2920 := z.EncBinary() - _ = yym2920 - 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) - yym2921 := z.EncBinary() - _ = yym2921 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.BootID)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2923 := z.EncBinary() - _ = yym2923 - 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) - yym2924 := z.EncBinary() - _ = yym2924 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2926 := z.EncBinary() - _ = yym2926 - 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) - yym2927 := z.EncBinary() - _ = yym2927 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.OSImage)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2929 := z.EncBinary() - _ = yym2929 - 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) - yym2930 := z.EncBinary() - _ = yym2930 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2932 := z.EncBinary() - _ = yym2932 - 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) - yym2933 := z.EncBinary() - _ = yym2933 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2935 := z.EncBinary() - _ = yym2935 - 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) - yym2936 := z.EncBinary() - _ = yym2936 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2938 := z.EncBinary() - _ = yym2938 - 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) - yym2939 := z.EncBinary() - _ = yym2939 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem)) - } - } - if yyr2912 || yy2arr2912 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2941 := z.EncBinary() - _ = yym2941 - 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) - yym2942 := z.EncBinary() - _ = yym2942 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Architecture)) - } - } - if yyr2912 || yy2arr2912 { - 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 - yym2943 := z.DecBinary() - _ = yym2943 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2944 := r.ContainerType() - if yyct2944 == codecSelferValueTypeMap1234 { - yyl2944 := r.ReadMapStart() - if yyl2944 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2944, d) - } - } else if yyct2944 == codecSelferValueTypeArray1234 { - yyl2944 := r.ReadArrayStart() - if yyl2944 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2944, 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 yys2945Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2945Slc - var yyhl2945 bool = l >= 0 - for yyj2945 := 0; ; yyj2945++ { - if yyhl2945 { - if yyj2945 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2945Slc = r.DecodeBytes(yys2945Slc, true, true) - yys2945 := string(yys2945Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2945 { - 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, yys2945) - } // end switch yys2945 - } // end for yyj2945 - 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 yyj2956 int - var yyb2956 bool - var yyhl2956 bool = l >= 0 - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MachineID = "" - } else { - x.MachineID = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SystemUUID = "" - } else { - x.SystemUUID = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.BootID = "" - } else { - x.BootID = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KernelVersion = "" - } else { - x.KernelVersion = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OSImage = "" - } else { - x.OSImage = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerRuntimeVersion = "" - } else { - x.ContainerRuntimeVersion = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KubeletVersion = "" - } else { - x.KubeletVersion = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KubeProxyVersion = "" - } else { - x.KubeProxyVersion = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OperatingSystem = "" - } else { - x.OperatingSystem = string(r.DecodeString()) - } - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Architecture = "" - } else { - x.Architecture = string(r.DecodeString()) - } - for { - yyj2956++ - if yyhl2956 { - yyb2956 = yyj2956 > l - } else { - yyb2956 = r.CheckBreak() - } - if yyb2956 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2956-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 { - yym2967 := z.EncBinary() - _ = yym2967 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2968 := !z.EncBinary() - yy2arr2968 := z.EncBasicHandle().StructToArray - var yyq2968 [10]bool - _, _, _ = yysep2968, yyq2968, yy2arr2968 - const yyr2968 bool = false - yyq2968[0] = len(x.Capacity) != 0 - yyq2968[1] = len(x.Allocatable) != 0 - yyq2968[2] = x.Phase != "" - yyq2968[3] = len(x.Conditions) != 0 - yyq2968[4] = len(x.Addresses) != 0 - yyq2968[5] = true - yyq2968[6] = true - yyq2968[7] = len(x.Images) != 0 - yyq2968[8] = len(x.VolumesInUse) != 0 - yyq2968[9] = len(x.VolumesAttached) != 0 - var yynn2968 int - if yyr2968 || yy2arr2968 { - r.EncodeArrayStart(10) - } else { - yynn2968 = 0 - for _, b := range yyq2968 { - if b { - yynn2968++ - } - } - r.EncodeMapStart(yynn2968) - yynn2968 = 0 - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[0] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[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 yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[1] { - if x.Allocatable == nil { - r.EncodeNil() - } else { - x.Allocatable.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[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 yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[2] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2968[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[3] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2973 := z.EncBinary() - _ = yym2973 - if false { - } else { - h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2974 := z.EncBinary() - _ = yym2974 - if false { - } else { - h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) - } - } - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[4] { - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2976 := z.EncBinary() - _ = yym2976 - if false { - } else { - h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("addresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2977 := z.EncBinary() - _ = yym2977 - if false { - } else { - h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) - } - } - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[5] { - yy2979 := &x.DaemonEndpoints - yy2979.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2968[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("daemonEndpoints")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2980 := &x.DaemonEndpoints - yy2980.CodecEncodeSelf(e) - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[6] { - yy2982 := &x.NodeInfo - yy2982.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2968[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeInfo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2983 := &x.NodeInfo - yy2983.CodecEncodeSelf(e) - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[7] { - if x.Images == nil { - r.EncodeNil() - } else { - yym2985 := z.EncBinary() - _ = yym2985 - if false { - } else { - h.encSliceContainerImage(([]ContainerImage)(x.Images), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("images")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Images == nil { - r.EncodeNil() - } else { - yym2986 := z.EncBinary() - _ = yym2986 - if false { - } else { - h.encSliceContainerImage(([]ContainerImage)(x.Images), e) - } - } - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[8] { - if x.VolumesInUse == nil { - r.EncodeNil() - } else { - yym2988 := z.EncBinary() - _ = yym2988 - if false { - } else { - h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumesInUse")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumesInUse == nil { - r.EncodeNil() - } else { - yym2989 := z.EncBinary() - _ = yym2989 - if false { - } else { - h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) - } - } - } - } - if yyr2968 || yy2arr2968 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2968[9] { - if x.VolumesAttached == nil { - r.EncodeNil() - } else { - yym2991 := z.EncBinary() - _ = yym2991 - if false { - } else { - h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2968[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumesAttached")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumesAttached == nil { - r.EncodeNil() - } else { - yym2992 := z.EncBinary() - _ = yym2992 - if false { - } else { - h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) - } - } - } - } - if yyr2968 || yy2arr2968 { - 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 - yym2993 := z.DecBinary() - _ = yym2993 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2994 := r.ContainerType() - if yyct2994 == codecSelferValueTypeMap1234 { - yyl2994 := r.ReadMapStart() - if yyl2994 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2994, d) - } - } else if yyct2994 == codecSelferValueTypeArray1234 { - yyl2994 := r.ReadArrayStart() - if yyl2994 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2994, 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 yys2995Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2995Slc - var yyhl2995 bool = l >= 0 - for yyj2995 := 0; ; yyj2995++ { - if yyhl2995 { - if yyj2995 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2995Slc = r.DecodeBytes(yys2995Slc, true, true) - yys2995 := string(yys2995Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2995 { - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv2996 := &x.Capacity - yyv2996.CodecDecodeSelf(d) - } - case "allocatable": - if r.TryDecodeAsNil() { - x.Allocatable = nil - } else { - yyv2997 := &x.Allocatable - yyv2997.CodecDecodeSelf(d) - } - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NodePhase(r.DecodeString()) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2999 := &x.Conditions - yym3000 := z.DecBinary() - _ = yym3000 - if false { - } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv2999), d) - } - } - case "addresses": - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv3001 := &x.Addresses - yym3002 := z.DecBinary() - _ = yym3002 - if false { - } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3001), d) - } - } - case "daemonEndpoints": - if r.TryDecodeAsNil() { - x.DaemonEndpoints = NodeDaemonEndpoints{} - } else { - yyv3003 := &x.DaemonEndpoints - yyv3003.CodecDecodeSelf(d) - } - case "nodeInfo": - if r.TryDecodeAsNil() { - x.NodeInfo = NodeSystemInfo{} - } else { - yyv3004 := &x.NodeInfo - yyv3004.CodecDecodeSelf(d) - } - case "images": - if r.TryDecodeAsNil() { - x.Images = nil - } else { - yyv3005 := &x.Images - yym3006 := z.DecBinary() - _ = yym3006 - if false { - } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3005), d) - } - } - case "volumesInUse": - if r.TryDecodeAsNil() { - x.VolumesInUse = nil - } else { - yyv3007 := &x.VolumesInUse - yym3008 := z.DecBinary() - _ = yym3008 - if false { - } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3007), d) - } - } - case "volumesAttached": - if r.TryDecodeAsNil() { - x.VolumesAttached = nil - } else { - yyv3009 := &x.VolumesAttached - yym3010 := z.DecBinary() - _ = yym3010 - if false { - } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3009), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2995) - } // end switch yys2995 - } // end for yyj2995 - 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 yyj3011 int - var yyb3011 bool - var yyhl3011 bool = l >= 0 - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv3012 := &x.Capacity - yyv3012.CodecDecodeSelf(d) - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Allocatable = nil - } else { - yyv3013 := &x.Allocatable - yyv3013.CodecDecodeSelf(d) - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NodePhase(r.DecodeString()) - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv3015 := &x.Conditions - yym3016 := z.DecBinary() - _ = yym3016 - if false { - } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv3015), d) - } - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv3017 := &x.Addresses - yym3018 := z.DecBinary() - _ = yym3018 - if false { - } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3017), d) - } - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DaemonEndpoints = NodeDaemonEndpoints{} - } else { - yyv3019 := &x.DaemonEndpoints - yyv3019.CodecDecodeSelf(d) - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeInfo = NodeSystemInfo{} - } else { - yyv3020 := &x.NodeInfo - yyv3020.CodecDecodeSelf(d) - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Images = nil - } else { - yyv3021 := &x.Images - yym3022 := z.DecBinary() - _ = yym3022 - if false { - } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3021), d) - } - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumesInUse = nil - } else { - yyv3023 := &x.VolumesInUse - yym3024 := z.DecBinary() - _ = yym3024 - if false { - } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3023), d) - } - } - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumesAttached = nil - } else { - yyv3025 := &x.VolumesAttached - yym3026 := z.DecBinary() - _ = yym3026 - if false { - } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3025), d) - } - } - for { - yyj3011++ - if yyhl3011 { - yyb3011 = yyj3011 > l - } else { - yyb3011 = r.CheckBreak() - } - if yyb3011 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3011-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x UniqueVolumeName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3027 := z.EncBinary() - _ = yym3027 - 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 - yym3028 := z.DecBinary() - _ = yym3028 - 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 { - yym3029 := z.EncBinary() - _ = yym3029 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3030 := !z.EncBinary() - yy2arr3030 := z.EncBasicHandle().StructToArray - var yyq3030 [2]bool - _, _, _ = yysep3030, yyq3030, yy2arr3030 - const yyr3030 bool = false - var yynn3030 int - if yyr3030 || yy2arr3030 { - r.EncodeArrayStart(2) - } else { - yynn3030 = 2 - for _, b := range yyq3030 { - if b { - yynn3030++ - } - } - r.EncodeMapStart(yynn3030) - yynn3030 = 0 - } - if yyr3030 || yy2arr3030 { - 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 yyr3030 || yy2arr3030 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3033 := z.EncBinary() - _ = yym3033 - 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) - yym3034 := z.EncBinary() - _ = yym3034 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath)) - } - } - if yyr3030 || yy2arr3030 { - 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 - yym3035 := z.DecBinary() - _ = yym3035 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3036 := r.ContainerType() - if yyct3036 == codecSelferValueTypeMap1234 { - yyl3036 := r.ReadMapStart() - if yyl3036 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3036, d) - } - } else if yyct3036 == codecSelferValueTypeArray1234 { - yyl3036 := r.ReadArrayStart() - if yyl3036 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3036, 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 yys3037Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3037Slc - var yyhl3037 bool = l >= 0 - for yyj3037 := 0; ; yyj3037++ { - if yyhl3037 { - if yyj3037 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3037Slc = r.DecodeBytes(yys3037Slc, true, true) - yys3037 := string(yys3037Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3037 { - 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, yys3037) - } // end switch yys3037 - } // end for yyj3037 - 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 yyj3040 int - var yyb3040 bool - var yyhl3040 bool = l >= 0 - yyj3040++ - if yyhl3040 { - yyb3040 = yyj3040 > l - } else { - yyb3040 = r.CheckBreak() - } - if yyb3040 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = UniqueVolumeName(r.DecodeString()) - } - yyj3040++ - if yyhl3040 { - yyb3040 = yyj3040 > l - } else { - yyb3040 = r.CheckBreak() - } - if yyb3040 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DevicePath = "" - } else { - x.DevicePath = string(r.DecodeString()) - } - for { - yyj3040++ - if yyhl3040 { - yyb3040 = yyj3040 > l - } else { - yyb3040 = r.CheckBreak() - } - if yyb3040 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3040-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *AvoidPods) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3043 := z.EncBinary() - _ = yym3043 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3044 := !z.EncBinary() - yy2arr3044 := z.EncBasicHandle().StructToArray - var yyq3044 [1]bool - _, _, _ = yysep3044, yyq3044, yy2arr3044 - const yyr3044 bool = false - yyq3044[0] = len(x.PreferAvoidPods) != 0 - var yynn3044 int - if yyr3044 || yy2arr3044 { - r.EncodeArrayStart(1) - } else { - yynn3044 = 0 - for _, b := range yyq3044 { - if b { - yynn3044++ - } - } - r.EncodeMapStart(yynn3044) - yynn3044 = 0 - } - if yyr3044 || yy2arr3044 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3044[0] { - if x.PreferAvoidPods == nil { - r.EncodeNil() - } else { - yym3046 := z.EncBinary() - _ = yym3046 - if false { - } else { - h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3044[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferAvoidPods")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferAvoidPods == nil { - r.EncodeNil() - } else { - yym3047 := z.EncBinary() - _ = yym3047 - if false { - } else { - h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) - } - } - } - } - if yyr3044 || yy2arr3044 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *AvoidPods) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym3048 := z.DecBinary() - _ = yym3048 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3049 := r.ContainerType() - if yyct3049 == codecSelferValueTypeMap1234 { - yyl3049 := r.ReadMapStart() - if yyl3049 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3049, d) - } - } else if yyct3049 == codecSelferValueTypeArray1234 { - yyl3049 := r.ReadArrayStart() - if yyl3049 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3049, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *AvoidPods) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3050Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3050Slc - var yyhl3050 bool = l >= 0 - for yyj3050 := 0; ; yyj3050++ { - if yyhl3050 { - if yyj3050 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3050Slc = r.DecodeBytes(yys3050Slc, true, true) - yys3050 := string(yys3050Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3050 { - case "preferAvoidPods": - if r.TryDecodeAsNil() { - x.PreferAvoidPods = nil - } else { - yyv3051 := &x.PreferAvoidPods - yym3052 := z.DecBinary() - _ = yym3052 - if false { - } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3051), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3050) - } // end switch yys3050 - } // end for yyj3050 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *AvoidPods) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj3053 int - var yyb3053 bool - var yyhl3053 bool = l >= 0 - yyj3053++ - if yyhl3053 { - yyb3053 = yyj3053 > l - } else { - yyb3053 = r.CheckBreak() - } - if yyb3053 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferAvoidPods = nil - } else { - yyv3054 := &x.PreferAvoidPods - yym3055 := z.DecBinary() - _ = yym3055 - if false { - } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3054), d) - } - } - for { - yyj3053++ - if yyhl3053 { - yyb3053 = yyj3053 > l - } else { - yyb3053 = r.CheckBreak() - } - if yyb3053 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3053-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PreferAvoidPodsEntry) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3056 := z.EncBinary() - _ = yym3056 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3057 := !z.EncBinary() - yy2arr3057 := z.EncBasicHandle().StructToArray - var yyq3057 [4]bool - _, _, _ = yysep3057, yyq3057, yy2arr3057 - const yyr3057 bool = false - yyq3057[1] = true - yyq3057[2] = x.Reason != "" - yyq3057[3] = x.Message != "" - var yynn3057 int - if yyr3057 || yy2arr3057 { - r.EncodeArrayStart(4) - } else { - yynn3057 = 1 - for _, b := range yyq3057 { - if b { - yynn3057++ - } - } - r.EncodeMapStart(yynn3057) - yynn3057 = 0 - } - if yyr3057 || yy2arr3057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3059 := &x.PodSignature - yy3059.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podSignature")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3060 := &x.PodSignature - yy3060.CodecEncodeSelf(e) - } - if yyr3057 || yy2arr3057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3057[1] { - yy3062 := &x.EvictionTime - yym3063 := z.EncBinary() - _ = yym3063 - if false { - } else if z.HasExtensions() && z.EncExt(yy3062) { - } else if yym3063 { - z.EncBinaryMarshal(yy3062) - } else if !yym3063 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3062) - } else { - z.EncFallback(yy3062) - } - } else { - r.EncodeNil() - } - } else { - if yyq3057[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("evictionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3064 := &x.EvictionTime - yym3065 := z.EncBinary() - _ = yym3065 - if false { - } else if z.HasExtensions() && z.EncExt(yy3064) { - } else if yym3065 { - z.EncBinaryMarshal(yy3064) - } else if !yym3065 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3064) - } else { - z.EncFallback(yy3064) - } - } - } - if yyr3057 || yy2arr3057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3057[2] { - yym3067 := z.EncBinary() - _ = yym3067 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3057[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3068 := z.EncBinary() - _ = yym3068 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3057 || yy2arr3057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3057[3] { - yym3070 := z.EncBinary() - _ = yym3070 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3057[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3071 := z.EncBinary() - _ = yym3071 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3057 || yy2arr3057 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PreferAvoidPodsEntry) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym3072 := z.DecBinary() - _ = yym3072 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3073 := r.ContainerType() - if yyct3073 == codecSelferValueTypeMap1234 { - yyl3073 := r.ReadMapStart() - if yyl3073 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3073, d) - } - } else if yyct3073 == codecSelferValueTypeArray1234 { - yyl3073 := r.ReadArrayStart() - if yyl3073 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3073, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PreferAvoidPodsEntry) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3074Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3074Slc - var yyhl3074 bool = l >= 0 - for yyj3074 := 0; ; yyj3074++ { - if yyhl3074 { - if yyj3074 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3074Slc = r.DecodeBytes(yys3074Slc, true, true) - yys3074 := string(yys3074Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3074 { - case "podSignature": - if r.TryDecodeAsNil() { - x.PodSignature = PodSignature{} - } else { - yyv3075 := &x.PodSignature - yyv3075.CodecDecodeSelf(d) - } - case "evictionTime": - if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} - } else { - yyv3076 := &x.EvictionTime - yym3077 := z.DecBinary() - _ = yym3077 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3076) { - } else if yym3077 { - z.DecBinaryUnmarshal(yyv3076) - } else if !yym3077 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3076) - } else { - z.DecFallback(yyv3076, 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, yys3074) - } // end switch yys3074 - } // end for yyj3074 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PreferAvoidPodsEntry) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj3080 int - var yyb3080 bool - var yyhl3080 bool = l >= 0 - yyj3080++ - if yyhl3080 { - yyb3080 = yyj3080 > l - } else { - yyb3080 = r.CheckBreak() - } - if yyb3080 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodSignature = PodSignature{} - } else { - yyv3081 := &x.PodSignature - yyv3081.CodecDecodeSelf(d) - } - yyj3080++ - if yyhl3080 { - yyb3080 = yyj3080 > l - } else { - yyb3080 = r.CheckBreak() - } - if yyb3080 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} - } else { - yyv3082 := &x.EvictionTime - yym3083 := z.DecBinary() - _ = yym3083 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3082) { - } else if yym3083 { - z.DecBinaryUnmarshal(yyv3082) - } else if !yym3083 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3082) - } else { - z.DecFallback(yyv3082, false) - } - } - yyj3080++ - if yyhl3080 { - yyb3080 = yyj3080 > l - } else { - yyb3080 = r.CheckBreak() - } - if yyb3080 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj3080++ - if yyhl3080 { - yyb3080 = yyj3080 > l - } else { - yyb3080 = r.CheckBreak() - } - if yyb3080 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj3080++ - if yyhl3080 { - yyb3080 = yyj3080 > l - } else { - yyb3080 = r.CheckBreak() - } - if yyb3080 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3080-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodSignature) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3086 := z.EncBinary() - _ = yym3086 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3087 := !z.EncBinary() - yy2arr3087 := z.EncBasicHandle().StructToArray - var yyq3087 [1]bool - _, _, _ = yysep3087, yyq3087, yy2arr3087 - const yyr3087 bool = false - yyq3087[0] = x.PodController != nil - var yynn3087 int - if yyr3087 || yy2arr3087 { - r.EncodeArrayStart(1) - } else { - yynn3087 = 0 - for _, b := range yyq3087 { - if b { - yynn3087++ - } - } - r.EncodeMapStart(yynn3087) - yynn3087 = 0 - } - if yyr3087 || yy2arr3087 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3087[0] { - if x.PodController == nil { - r.EncodeNil() - } else { - x.PodController.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3087[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podController")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PodController == nil { - r.EncodeNil() - } else { - x.PodController.CodecEncodeSelf(e) - } - } - } - if yyr3087 || yy2arr3087 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodSignature) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym3089 := z.DecBinary() - _ = yym3089 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3090 := r.ContainerType() - if yyct3090 == codecSelferValueTypeMap1234 { - yyl3090 := r.ReadMapStart() - if yyl3090 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3090, d) - } - } else if yyct3090 == codecSelferValueTypeArray1234 { - yyl3090 := r.ReadArrayStart() - if yyl3090 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3090, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodSignature) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3091Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3091Slc - var yyhl3091 bool = l >= 0 - for yyj3091 := 0; ; yyj3091++ { - if yyhl3091 { - if yyj3091 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3091Slc = r.DecodeBytes(yys3091Slc, true, true) - yys3091 := string(yys3091Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3091 { - case "podController": - if r.TryDecodeAsNil() { - if x.PodController != nil { - x.PodController = nil - } - } else { - if x.PodController == nil { - x.PodController = new(OwnerReference) - } - x.PodController.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3091) - } // end switch yys3091 - } // end for yyj3091 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodSignature) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj3093 int - var yyb3093 bool - var yyhl3093 bool = l >= 0 - yyj3093++ - if yyhl3093 { - yyb3093 = yyj3093 > l - } else { - yyb3093 = r.CheckBreak() - } - if yyb3093 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PodController != nil { - x.PodController = nil - } - } else { - if x.PodController == nil { - x.PodController = new(OwnerReference) - } - x.PodController.CodecDecodeSelf(d) - } - for { - yyj3093++ - if yyhl3093 { - yyb3093 = yyj3093 > l - } else { - yyb3093 = r.CheckBreak() - } - if yyb3093 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3093-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 { - yym3095 := z.EncBinary() - _ = yym3095 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3096 := !z.EncBinary() - yy2arr3096 := z.EncBasicHandle().StructToArray - var yyq3096 [2]bool - _, _, _ = yysep3096, yyq3096, yy2arr3096 - const yyr3096 bool = false - yyq3096[1] = x.SizeBytes != 0 - var yynn3096 int - if yyr3096 || yy2arr3096 { - r.EncodeArrayStart(2) - } else { - yynn3096 = 1 - for _, b := range yyq3096 { - if b { - yynn3096++ - } - } - r.EncodeMapStart(yynn3096) - yynn3096 = 0 - } - if yyr3096 || yy2arr3096 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Names == nil { - r.EncodeNil() - } else { - yym3098 := z.EncBinary() - _ = yym3098 - 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 { - yym3099 := z.EncBinary() - _ = yym3099 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } - if yyr3096 || yy2arr3096 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3096[1] { - yym3101 := z.EncBinary() - _ = yym3101 - if false { - } else { - r.EncodeInt(int64(x.SizeBytes)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq3096[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sizeBytes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3102 := z.EncBinary() - _ = yym3102 - if false { - } else { - r.EncodeInt(int64(x.SizeBytes)) - } - } - } - if yyr3096 || yy2arr3096 { - 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 - yym3103 := z.DecBinary() - _ = yym3103 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3104 := r.ContainerType() - if yyct3104 == codecSelferValueTypeMap1234 { - yyl3104 := r.ReadMapStart() - if yyl3104 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3104, d) - } - } else if yyct3104 == codecSelferValueTypeArray1234 { - yyl3104 := r.ReadArrayStart() - if yyl3104 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3104, 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 yys3105Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3105Slc - var yyhl3105 bool = l >= 0 - for yyj3105 := 0; ; yyj3105++ { - if yyhl3105 { - if yyj3105 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3105Slc = r.DecodeBytes(yys3105Slc, true, true) - yys3105 := string(yys3105Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3105 { - case "names": - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv3106 := &x.Names - yym3107 := z.DecBinary() - _ = yym3107 - if false { - } else { - z.F.DecSliceStringX(yyv3106, false, d) - } - } - case "sizeBytes": - if r.TryDecodeAsNil() { - x.SizeBytes = 0 - } else { - x.SizeBytes = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys3105) - } // end switch yys3105 - } // end for yyj3105 - 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 yyj3109 int - var yyb3109 bool - var yyhl3109 bool = l >= 0 - yyj3109++ - if yyhl3109 { - yyb3109 = yyj3109 > l - } else { - yyb3109 = r.CheckBreak() - } - if yyb3109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv3110 := &x.Names - yym3111 := z.DecBinary() - _ = yym3111 - if false { - } else { - z.F.DecSliceStringX(yyv3110, false, d) - } - } - yyj3109++ - if yyhl3109 { - yyb3109 = yyj3109 > l - } else { - yyb3109 = r.CheckBreak() - } - if yyb3109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SizeBytes = 0 - } else { - x.SizeBytes = int64(r.DecodeInt(64)) - } - for { - yyj3109++ - if yyhl3109 { - yyb3109 = yyj3109 > l - } else { - yyb3109 = r.CheckBreak() - } - if yyb3109 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3109-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodePhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3113 := z.EncBinary() - _ = yym3113 - 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 - yym3114 := z.DecBinary() - _ = yym3114 - 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 - yym3115 := z.EncBinary() - _ = yym3115 - 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 - yym3116 := z.DecBinary() - _ = yym3116 - 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 { - yym3117 := z.EncBinary() - _ = yym3117 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3118 := !z.EncBinary() - yy2arr3118 := z.EncBasicHandle().StructToArray - var yyq3118 [6]bool - _, _, _ = yysep3118, yyq3118, yy2arr3118 - const yyr3118 bool = false - yyq3118[2] = true - yyq3118[3] = true - yyq3118[4] = x.Reason != "" - yyq3118[5] = x.Message != "" - var yynn3118 int - if yyr3118 || yy2arr3118 { - r.EncodeArrayStart(6) - } else { - yynn3118 = 2 - for _, b := range yyq3118 { - if b { - yynn3118++ - } - } - r.EncodeMapStart(yynn3118) - yynn3118 = 0 - } - if yyr3118 || yy2arr3118 { - 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 yyr3118 || yy2arr3118 { - 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 yyr3118 || yy2arr3118 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3118[2] { - yy3122 := &x.LastHeartbeatTime - yym3123 := z.EncBinary() - _ = yym3123 - if false { - } else if z.HasExtensions() && z.EncExt(yy3122) { - } else if yym3123 { - z.EncBinaryMarshal(yy3122) - } else if !yym3123 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3122) - } else { - z.EncFallback(yy3122) - } - } else { - r.EncodeNil() - } - } else { - if yyq3118[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastHeartbeatTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3124 := &x.LastHeartbeatTime - yym3125 := z.EncBinary() - _ = yym3125 - if false { - } else if z.HasExtensions() && z.EncExt(yy3124) { - } else if yym3125 { - z.EncBinaryMarshal(yy3124) - } else if !yym3125 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3124) - } else { - z.EncFallback(yy3124) - } - } - } - if yyr3118 || yy2arr3118 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3118[3] { - yy3127 := &x.LastTransitionTime - yym3128 := z.EncBinary() - _ = yym3128 - if false { - } else if z.HasExtensions() && z.EncExt(yy3127) { - } else if yym3128 { - z.EncBinaryMarshal(yy3127) - } else if !yym3128 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3127) - } else { - z.EncFallback(yy3127) - } - } else { - r.EncodeNil() - } - } else { - if yyq3118[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3129 := &x.LastTransitionTime - yym3130 := z.EncBinary() - _ = yym3130 - if false { - } else if z.HasExtensions() && z.EncExt(yy3129) { - } else if yym3130 { - z.EncBinaryMarshal(yy3129) - } else if !yym3130 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3129) - } else { - z.EncFallback(yy3129) - } - } - } - if yyr3118 || yy2arr3118 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3118[4] { - yym3132 := z.EncBinary() - _ = yym3132 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3118[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3133 := z.EncBinary() - _ = yym3133 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3118 || yy2arr3118 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3118[5] { - yym3135 := z.EncBinary() - _ = yym3135 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3118[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3136 := z.EncBinary() - _ = yym3136 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3118 || yy2arr3118 { - 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 - yym3137 := z.DecBinary() - _ = yym3137 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3138 := r.ContainerType() - if yyct3138 == codecSelferValueTypeMap1234 { - yyl3138 := r.ReadMapStart() - if yyl3138 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3138, d) - } - } else if yyct3138 == codecSelferValueTypeArray1234 { - yyl3138 := r.ReadArrayStart() - if yyl3138 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3138, 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 yys3139Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3139Slc - var yyhl3139 bool = l >= 0 - for yyj3139 := 0; ; yyj3139++ { - if yyhl3139 { - if yyj3139 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3139Slc = r.DecodeBytes(yys3139Slc, true, true) - yys3139 := string(yys3139Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3139 { - 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 { - yyv3142 := &x.LastHeartbeatTime - yym3143 := z.DecBinary() - _ = yym3143 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3142) { - } else if yym3143 { - z.DecBinaryUnmarshal(yyv3142) - } else if !yym3143 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3142) - } else { - z.DecFallback(yyv3142, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv3144 := &x.LastTransitionTime - yym3145 := z.DecBinary() - _ = yym3145 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3144) { - } else if yym3145 { - z.DecBinaryUnmarshal(yyv3144) - } else if !yym3145 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3144) - } else { - z.DecFallback(yyv3144, 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, yys3139) - } // end switch yys3139 - } // end for yyj3139 - 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 yyj3148 int - var yyb3148 bool - var yyhl3148 bool = l >= 0 - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = NodeConditionType(r.DecodeString()) - } - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastHeartbeatTime = pkg2_unversioned.Time{} - } else { - yyv3151 := &x.LastHeartbeatTime - yym3152 := z.DecBinary() - _ = yym3152 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3151) { - } else if yym3152 { - z.DecBinaryUnmarshal(yyv3151) - } else if !yym3152 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3151) - } else { - z.DecFallback(yyv3151, false) - } - } - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv3153 := &x.LastTransitionTime - yym3154 := z.DecBinary() - _ = yym3154 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3153) { - } else if yym3154 { - z.DecBinaryUnmarshal(yyv3153) - } else if !yym3154 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3153) - } else { - z.DecFallback(yyv3153, false) - } - } - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj3148++ - if yyhl3148 { - yyb3148 = yyj3148 > l - } else { - yyb3148 = r.CheckBreak() - } - if yyb3148 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3148-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodeAddressType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3157 := z.EncBinary() - _ = yym3157 - 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 - yym3158 := z.DecBinary() - _ = yym3158 - 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 { - yym3159 := z.EncBinary() - _ = yym3159 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3160 := !z.EncBinary() - yy2arr3160 := z.EncBasicHandle().StructToArray - var yyq3160 [2]bool - _, _, _ = yysep3160, yyq3160, yy2arr3160 - const yyr3160 bool = false - var yynn3160 int - if yyr3160 || yy2arr3160 { - r.EncodeArrayStart(2) - } else { - yynn3160 = 2 - for _, b := range yyq3160 { - if b { - yynn3160++ - } - } - r.EncodeMapStart(yynn3160) - yynn3160 = 0 - } - if yyr3160 || yy2arr3160 { - 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 yyr3160 || yy2arr3160 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3163 := z.EncBinary() - _ = yym3163 - 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) - yym3164 := z.EncBinary() - _ = yym3164 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Address)) - } - } - if yyr3160 || yy2arr3160 { - 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 - yym3165 := z.DecBinary() - _ = yym3165 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3166 := r.ContainerType() - if yyct3166 == codecSelferValueTypeMap1234 { - yyl3166 := r.ReadMapStart() - if yyl3166 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3166, d) - } - } else if yyct3166 == codecSelferValueTypeArray1234 { - yyl3166 := r.ReadArrayStart() - if yyl3166 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3166, 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 yys3167Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3167Slc - var yyhl3167 bool = l >= 0 - for yyj3167 := 0; ; yyj3167++ { - if yyhl3167 { - if yyj3167 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3167Slc = r.DecodeBytes(yys3167Slc, true, true) - yys3167 := string(yys3167Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3167 { - 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, yys3167) - } // end switch yys3167 - } // end for yyj3167 - 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 yyj3170 int - var yyb3170 bool - var yyhl3170 bool = l >= 0 - yyj3170++ - if yyhl3170 { - yyb3170 = yyj3170 > l - } else { - yyb3170 = r.CheckBreak() - } - if yyb3170 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = NodeAddressType(r.DecodeString()) - } - yyj3170++ - if yyhl3170 { - yyb3170 = yyj3170 > l - } else { - yyb3170 = r.CheckBreak() - } - if yyb3170 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Address = "" - } else { - x.Address = string(r.DecodeString()) - } - for { - yyj3170++ - if yyhl3170 { - yyb3170 = yyj3170 > l - } else { - yyb3170 = r.CheckBreak() - } - if yyb3170 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3170-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ResourceName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3173 := z.EncBinary() - _ = yym3173 - 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 - yym3174 := z.DecBinary() - _ = yym3174 - 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 { - yym3175 := z.EncBinary() - _ = yym3175 - 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 - yym3176 := z.DecBinary() - _ = yym3176 - 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 { - yym3177 := z.EncBinary() - _ = yym3177 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3178 := !z.EncBinary() - yy2arr3178 := z.EncBasicHandle().StructToArray - var yyq3178 [5]bool - _, _, _ = yysep3178, yyq3178, yy2arr3178 - const yyr3178 bool = false - yyq3178[0] = x.Kind != "" - yyq3178[1] = x.APIVersion != "" - yyq3178[2] = true - yyq3178[3] = true - yyq3178[4] = true - var yynn3178 int - if yyr3178 || yy2arr3178 { - r.EncodeArrayStart(5) - } else { - yynn3178 = 0 - for _, b := range yyq3178 { - if b { - yynn3178++ - } - } - r.EncodeMapStart(yynn3178) - yynn3178 = 0 - } - if yyr3178 || yy2arr3178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3178[0] { - yym3180 := z.EncBinary() - _ = yym3180 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3178[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3181 := z.EncBinary() - _ = yym3181 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3178 || yy2arr3178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3178[1] { - yym3183 := z.EncBinary() - _ = yym3183 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3178[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3184 := z.EncBinary() - _ = yym3184 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3178 || yy2arr3178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3178[2] { - yy3186 := &x.ObjectMeta - yy3186.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3178[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3187 := &x.ObjectMeta - yy3187.CodecEncodeSelf(e) - } - } - if yyr3178 || yy2arr3178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3178[3] { - yy3189 := &x.Spec - yy3189.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3178[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3190 := &x.Spec - yy3190.CodecEncodeSelf(e) - } - } - if yyr3178 || yy2arr3178 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3178[4] { - yy3192 := &x.Status - yy3192.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3178[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3193 := &x.Status - yy3193.CodecEncodeSelf(e) - } - } - if yyr3178 || yy2arr3178 { - 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 - yym3194 := z.DecBinary() - _ = yym3194 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3195 := r.ContainerType() - if yyct3195 == codecSelferValueTypeMap1234 { - yyl3195 := r.ReadMapStart() - if yyl3195 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3195, d) - } - } else if yyct3195 == codecSelferValueTypeArray1234 { - yyl3195 := r.ReadArrayStart() - if yyl3195 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3195, 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 yys3196Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3196Slc - var yyhl3196 bool = l >= 0 - for yyj3196 := 0; ; yyj3196++ { - if yyhl3196 { - if yyj3196 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3196Slc = r.DecodeBytes(yys3196Slc, true, true) - yys3196 := string(yys3196Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3196 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3199 := &x.ObjectMeta - yyv3199.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = NodeSpec{} - } else { - yyv3200 := &x.Spec - yyv3200.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = NodeStatus{} - } else { - yyv3201 := &x.Status - yyv3201.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3196) - } // end switch yys3196 - } // end for yyj3196 - 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 yyj3202 int - var yyb3202 bool - var yyhl3202 bool = l >= 0 - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3205 := &x.ObjectMeta - yyv3205.CodecDecodeSelf(d) - } - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = NodeSpec{} - } else { - yyv3206 := &x.Spec - yyv3206.CodecDecodeSelf(d) - } - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = NodeStatus{} - } else { - yyv3207 := &x.Status - yyv3207.CodecDecodeSelf(d) - } - for { - yyj3202++ - if yyhl3202 { - yyb3202 = yyj3202 > l - } else { - yyb3202 = r.CheckBreak() - } - if yyb3202 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3202-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 { - yym3208 := z.EncBinary() - _ = yym3208 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3209 := !z.EncBinary() - yy2arr3209 := z.EncBasicHandle().StructToArray - var yyq3209 [4]bool - _, _, _ = yysep3209, yyq3209, yy2arr3209 - const yyr3209 bool = false - yyq3209[0] = x.Kind != "" - yyq3209[1] = x.APIVersion != "" - yyq3209[2] = true - var yynn3209 int - if yyr3209 || yy2arr3209 { - r.EncodeArrayStart(4) - } else { - yynn3209 = 1 - for _, b := range yyq3209 { - if b { - yynn3209++ - } - } - r.EncodeMapStart(yynn3209) - yynn3209 = 0 - } - if yyr3209 || yy2arr3209 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3209[0] { - yym3211 := z.EncBinary() - _ = yym3211 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3209[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3212 := z.EncBinary() - _ = yym3212 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3209 || yy2arr3209 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3209[1] { - yym3214 := z.EncBinary() - _ = yym3214 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3209[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3215 := z.EncBinary() - _ = yym3215 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3209 || yy2arr3209 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3209[2] { - yy3217 := &x.ListMeta - yym3218 := z.EncBinary() - _ = yym3218 - if false { - } else if z.HasExtensions() && z.EncExt(yy3217) { - } else { - z.EncFallback(yy3217) - } - } else { - r.EncodeNil() - } - } else { - if yyq3209[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3219 := &x.ListMeta - yym3220 := z.EncBinary() - _ = yym3220 - if false { - } else if z.HasExtensions() && z.EncExt(yy3219) { - } else { - z.EncFallback(yy3219) - } - } - } - if yyr3209 || yy2arr3209 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3222 := z.EncBinary() - _ = yym3222 - 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 { - yym3223 := z.EncBinary() - _ = yym3223 - if false { - } else { - h.encSliceNode(([]Node)(x.Items), e) - } - } - } - if yyr3209 || yy2arr3209 { - 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 - yym3224 := z.DecBinary() - _ = yym3224 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3225 := r.ContainerType() - if yyct3225 == codecSelferValueTypeMap1234 { - yyl3225 := r.ReadMapStart() - if yyl3225 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3225, d) - } - } else if yyct3225 == codecSelferValueTypeArray1234 { - yyl3225 := r.ReadArrayStart() - if yyl3225 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3225, 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 yys3226Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3226Slc - var yyhl3226 bool = l >= 0 - for yyj3226 := 0; ; yyj3226++ { - if yyhl3226 { - if yyj3226 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3226Slc = r.DecodeBytes(yys3226Slc, true, true) - yys3226 := string(yys3226Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3226 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3229 := &x.ListMeta - yym3230 := z.DecBinary() - _ = yym3230 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3229) { - } else { - z.DecFallback(yyv3229, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3231 := &x.Items - yym3232 := z.DecBinary() - _ = yym3232 - if false { - } else { - h.decSliceNode((*[]Node)(yyv3231), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3226) - } // end switch yys3226 - } // end for yyj3226 - 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 yyj3233 int - var yyb3233 bool - var yyhl3233 bool = l >= 0 - yyj3233++ - if yyhl3233 { - yyb3233 = yyj3233 > l - } else { - yyb3233 = r.CheckBreak() - } - if yyb3233 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3233++ - if yyhl3233 { - yyb3233 = yyj3233 > l - } else { - yyb3233 = r.CheckBreak() - } - if yyb3233 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3233++ - if yyhl3233 { - yyb3233 = yyj3233 > l - } else { - yyb3233 = r.CheckBreak() - } - if yyb3233 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3236 := &x.ListMeta - yym3237 := z.DecBinary() - _ = yym3237 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3236) { - } else { - z.DecFallback(yyv3236, false) - } - } - yyj3233++ - if yyhl3233 { - yyb3233 = yyj3233 > l - } else { - yyb3233 = r.CheckBreak() - } - if yyb3233 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3238 := &x.Items - yym3239 := z.DecBinary() - _ = yym3239 - if false { - } else { - h.decSliceNode((*[]Node)(yyv3238), d) - } - } - for { - yyj3233++ - if yyhl3233 { - yyb3233 = yyj3233 > l - } else { - yyb3233 = r.CheckBreak() - } - if yyb3233 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3233-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x FinalizerName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3240 := z.EncBinary() - _ = yym3240 - 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 - yym3241 := z.DecBinary() - _ = yym3241 - 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 { - yym3242 := z.EncBinary() - _ = yym3242 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3243 := !z.EncBinary() - yy2arr3243 := z.EncBasicHandle().StructToArray - var yyq3243 [1]bool - _, _, _ = yysep3243, yyq3243, yy2arr3243 - const yyr3243 bool = false - yyq3243[0] = len(x.Finalizers) != 0 - var yynn3243 int - if yyr3243 || yy2arr3243 { - r.EncodeArrayStart(1) - } else { - yynn3243 = 0 - for _, b := range yyq3243 { - if b { - yynn3243++ - } - } - r.EncodeMapStart(yynn3243) - yynn3243 = 0 - } - if yyr3243 || yy2arr3243 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3243[0] { - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym3245 := z.EncBinary() - _ = yym3245 - if false { - } else { - h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3243[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym3246 := z.EncBinary() - _ = yym3246 - if false { - } else { - h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) - } - } - } - } - if yyr3243 || yy2arr3243 { - 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 - yym3247 := z.DecBinary() - _ = yym3247 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3248 := r.ContainerType() - if yyct3248 == codecSelferValueTypeMap1234 { - yyl3248 := r.ReadMapStart() - if yyl3248 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3248, d) - } - } else if yyct3248 == codecSelferValueTypeArray1234 { - yyl3248 := r.ReadArrayStart() - if yyl3248 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3248, 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 yys3249Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3249Slc - var yyhl3249 bool = l >= 0 - for yyj3249 := 0; ; yyj3249++ { - if yyhl3249 { - if yyj3249 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3249Slc = r.DecodeBytes(yys3249Slc, true, true) - yys3249 := string(yys3249Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3249 { - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv3250 := &x.Finalizers - yym3251 := z.DecBinary() - _ = yym3251 - if false { - } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3250), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3249) - } // end switch yys3249 - } // end for yyj3249 - 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 yyj3252 int - var yyb3252 bool - var yyhl3252 bool = l >= 0 - yyj3252++ - if yyhl3252 { - yyb3252 = yyj3252 > l - } else { - yyb3252 = r.CheckBreak() - } - if yyb3252 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv3253 := &x.Finalizers - yym3254 := z.DecBinary() - _ = yym3254 - if false { - } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3253), d) - } - } - for { - yyj3252++ - if yyhl3252 { - yyb3252 = yyj3252 > l - } else { - yyb3252 = r.CheckBreak() - } - if yyb3252 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3252-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 { - yym3255 := z.EncBinary() - _ = yym3255 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3256 := !z.EncBinary() - yy2arr3256 := z.EncBasicHandle().StructToArray - var yyq3256 [1]bool - _, _, _ = yysep3256, yyq3256, yy2arr3256 - const yyr3256 bool = false - yyq3256[0] = x.Phase != "" - var yynn3256 int - if yyr3256 || yy2arr3256 { - r.EncodeArrayStart(1) - } else { - yynn3256 = 0 - for _, b := range yyq3256 { - if b { - yynn3256++ - } - } - r.EncodeMapStart(yynn3256) - yynn3256 = 0 - } - if yyr3256 || yy2arr3256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3256[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3256[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr3256 || yy2arr3256 { - 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 - yym3258 := z.DecBinary() - _ = yym3258 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3259 := r.ContainerType() - if yyct3259 == codecSelferValueTypeMap1234 { - yyl3259 := r.ReadMapStart() - if yyl3259 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3259, d) - } - } else if yyct3259 == codecSelferValueTypeArray1234 { - yyl3259 := r.ReadArrayStart() - if yyl3259 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3259, 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 yys3260Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3260Slc - var yyhl3260 bool = l >= 0 - for yyj3260 := 0; ; yyj3260++ { - if yyhl3260 { - if yyj3260 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3260Slc = r.DecodeBytes(yys3260Slc, true, true) - yys3260 := string(yys3260Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3260 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NamespacePhase(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3260) - } // end switch yys3260 - } // end for yyj3260 - 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 yyj3262 int - var yyb3262 bool - var yyhl3262 bool = l >= 0 - yyj3262++ - if yyhl3262 { - yyb3262 = yyj3262 > l - } else { - yyb3262 = r.CheckBreak() - } - if yyb3262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NamespacePhase(r.DecodeString()) - } - for { - yyj3262++ - if yyhl3262 { - yyb3262 = yyj3262 > l - } else { - yyb3262 = r.CheckBreak() - } - if yyb3262 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3262-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NamespacePhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3264 := z.EncBinary() - _ = yym3264 - 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 - yym3265 := z.DecBinary() - _ = yym3265 - 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 { - yym3266 := z.EncBinary() - _ = yym3266 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3267 := !z.EncBinary() - yy2arr3267 := z.EncBasicHandle().StructToArray - var yyq3267 [5]bool - _, _, _ = yysep3267, yyq3267, yy2arr3267 - const yyr3267 bool = false - yyq3267[0] = x.Kind != "" - yyq3267[1] = x.APIVersion != "" - yyq3267[2] = true - yyq3267[3] = true - yyq3267[4] = true - var yynn3267 int - if yyr3267 || yy2arr3267 { - r.EncodeArrayStart(5) - } else { - yynn3267 = 0 - for _, b := range yyq3267 { - if b { - yynn3267++ - } - } - r.EncodeMapStart(yynn3267) - yynn3267 = 0 - } - if yyr3267 || yy2arr3267 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3267[0] { - yym3269 := z.EncBinary() - _ = yym3269 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3267[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3270 := z.EncBinary() - _ = yym3270 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3267 || yy2arr3267 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3267[1] { - yym3272 := z.EncBinary() - _ = yym3272 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3267[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3273 := z.EncBinary() - _ = yym3273 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3267 || yy2arr3267 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3267[2] { - yy3275 := &x.ObjectMeta - yy3275.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3267[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3276 := &x.ObjectMeta - yy3276.CodecEncodeSelf(e) - } - } - if yyr3267 || yy2arr3267 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3267[3] { - yy3278 := &x.Spec - yy3278.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3267[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3279 := &x.Spec - yy3279.CodecEncodeSelf(e) - } - } - if yyr3267 || yy2arr3267 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3267[4] { - yy3281 := &x.Status - yy3281.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3267[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3282 := &x.Status - yy3282.CodecEncodeSelf(e) - } - } - if yyr3267 || yy2arr3267 { - 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 - yym3283 := z.DecBinary() - _ = yym3283 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3284 := r.ContainerType() - if yyct3284 == codecSelferValueTypeMap1234 { - yyl3284 := r.ReadMapStart() - if yyl3284 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3284, d) - } - } else if yyct3284 == codecSelferValueTypeArray1234 { - yyl3284 := r.ReadArrayStart() - if yyl3284 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3284, 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 yys3285Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3285Slc - var yyhl3285 bool = l >= 0 - for yyj3285 := 0; ; yyj3285++ { - if yyhl3285 { - if yyj3285 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3285Slc = r.DecodeBytes(yys3285Slc, true, true) - yys3285 := string(yys3285Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3285 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3288 := &x.ObjectMeta - yyv3288.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = NamespaceSpec{} - } else { - yyv3289 := &x.Spec - yyv3289.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = NamespaceStatus{} - } else { - yyv3290 := &x.Status - yyv3290.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3285) - } // end switch yys3285 - } // end for yyj3285 - 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 yyj3291 int - var yyb3291 bool - var yyhl3291 bool = l >= 0 - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3294 := &x.ObjectMeta - yyv3294.CodecDecodeSelf(d) - } - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = NamespaceSpec{} - } else { - yyv3295 := &x.Spec - yyv3295.CodecDecodeSelf(d) - } - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = NamespaceStatus{} - } else { - yyv3296 := &x.Status - yyv3296.CodecDecodeSelf(d) - } - for { - yyj3291++ - if yyhl3291 { - yyb3291 = yyj3291 > l - } else { - yyb3291 = r.CheckBreak() - } - if yyb3291 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3291-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 { - yym3297 := z.EncBinary() - _ = yym3297 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3298 := !z.EncBinary() - yy2arr3298 := z.EncBasicHandle().StructToArray - var yyq3298 [4]bool - _, _, _ = yysep3298, yyq3298, yy2arr3298 - const yyr3298 bool = false - yyq3298[0] = x.Kind != "" - yyq3298[1] = x.APIVersion != "" - yyq3298[2] = true - var yynn3298 int - if yyr3298 || yy2arr3298 { - r.EncodeArrayStart(4) - } else { - yynn3298 = 1 - for _, b := range yyq3298 { - if b { - yynn3298++ - } - } - r.EncodeMapStart(yynn3298) - yynn3298 = 0 - } - if yyr3298 || yy2arr3298 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3298[0] { - yym3300 := z.EncBinary() - _ = yym3300 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3298[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3301 := z.EncBinary() - _ = yym3301 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3298 || yy2arr3298 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3298[1] { - yym3303 := z.EncBinary() - _ = yym3303 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3298[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3304 := z.EncBinary() - _ = yym3304 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3298 || yy2arr3298 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3298[2] { - yy3306 := &x.ListMeta - yym3307 := z.EncBinary() - _ = yym3307 - if false { - } else if z.HasExtensions() && z.EncExt(yy3306) { - } else { - z.EncFallback(yy3306) - } - } else { - r.EncodeNil() - } - } else { - if yyq3298[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3308 := &x.ListMeta - yym3309 := z.EncBinary() - _ = yym3309 - if false { - } else if z.HasExtensions() && z.EncExt(yy3308) { - } else { - z.EncFallback(yy3308) - } - } - } - if yyr3298 || yy2arr3298 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3311 := z.EncBinary() - _ = yym3311 - 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 { - yym3312 := z.EncBinary() - _ = yym3312 - if false { - } else { - h.encSliceNamespace(([]Namespace)(x.Items), e) - } - } - } - if yyr3298 || yy2arr3298 { - 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 - yym3313 := z.DecBinary() - _ = yym3313 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3314 := r.ContainerType() - if yyct3314 == codecSelferValueTypeMap1234 { - yyl3314 := r.ReadMapStart() - if yyl3314 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3314, d) - } - } else if yyct3314 == codecSelferValueTypeArray1234 { - yyl3314 := r.ReadArrayStart() - if yyl3314 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3314, 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 yys3315Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3315Slc - var yyhl3315 bool = l >= 0 - for yyj3315 := 0; ; yyj3315++ { - if yyhl3315 { - if yyj3315 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3315Slc = r.DecodeBytes(yys3315Slc, true, true) - yys3315 := string(yys3315Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3315 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3318 := &x.ListMeta - yym3319 := z.DecBinary() - _ = yym3319 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3318) { - } else { - z.DecFallback(yyv3318, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3320 := &x.Items - yym3321 := z.DecBinary() - _ = yym3321 - if false { - } else { - h.decSliceNamespace((*[]Namespace)(yyv3320), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3315) - } // end switch yys3315 - } // end for yyj3315 - 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 yyj3322 int - var yyb3322 bool - var yyhl3322 bool = l >= 0 - yyj3322++ - if yyhl3322 { - yyb3322 = yyj3322 > l - } else { - yyb3322 = r.CheckBreak() - } - if yyb3322 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3322++ - if yyhl3322 { - yyb3322 = yyj3322 > l - } else { - yyb3322 = r.CheckBreak() - } - if yyb3322 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3322++ - if yyhl3322 { - yyb3322 = yyj3322 > l - } else { - yyb3322 = r.CheckBreak() - } - if yyb3322 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3325 := &x.ListMeta - yym3326 := z.DecBinary() - _ = yym3326 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3325) { - } else { - z.DecFallback(yyv3325, false) - } - } - yyj3322++ - if yyhl3322 { - yyb3322 = yyj3322 > l - } else { - yyb3322 = r.CheckBreak() - } - if yyb3322 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3327 := &x.Items - yym3328 := z.DecBinary() - _ = yym3328 - if false { - } else { - h.decSliceNamespace((*[]Namespace)(yyv3327), d) - } - } - for { - yyj3322++ - if yyhl3322 { - yyb3322 = yyj3322 > l - } else { - yyb3322 = r.CheckBreak() - } - if yyb3322 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3322-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 { - yym3329 := z.EncBinary() - _ = yym3329 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3330 := !z.EncBinary() - yy2arr3330 := z.EncBasicHandle().StructToArray - var yyq3330 [4]bool - _, _, _ = yysep3330, yyq3330, yy2arr3330 - const yyr3330 bool = false - yyq3330[0] = x.Kind != "" - yyq3330[1] = x.APIVersion != "" - yyq3330[2] = true - var yynn3330 int - if yyr3330 || yy2arr3330 { - r.EncodeArrayStart(4) - } else { - yynn3330 = 1 - for _, b := range yyq3330 { - if b { - yynn3330++ - } - } - r.EncodeMapStart(yynn3330) - yynn3330 = 0 - } - if yyr3330 || yy2arr3330 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3330[0] { - yym3332 := z.EncBinary() - _ = yym3332 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3330[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3333 := z.EncBinary() - _ = yym3333 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3330 || yy2arr3330 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3330[1] { - yym3335 := z.EncBinary() - _ = yym3335 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3330[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3336 := z.EncBinary() - _ = yym3336 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3330 || yy2arr3330 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3330[2] { - yy3338 := &x.ObjectMeta - yy3338.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3330[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3339 := &x.ObjectMeta - yy3339.CodecEncodeSelf(e) - } - } - if yyr3330 || yy2arr3330 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3341 := &x.Target - yy3341.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("target")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3342 := &x.Target - yy3342.CodecEncodeSelf(e) - } - if yyr3330 || yy2arr3330 { - 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 - yym3343 := z.DecBinary() - _ = yym3343 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3344 := r.ContainerType() - if yyct3344 == codecSelferValueTypeMap1234 { - yyl3344 := r.ReadMapStart() - if yyl3344 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3344, d) - } - } else if yyct3344 == codecSelferValueTypeArray1234 { - yyl3344 := r.ReadArrayStart() - if yyl3344 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3344, 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 yys3345Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3345Slc - var yyhl3345 bool = l >= 0 - for yyj3345 := 0; ; yyj3345++ { - if yyhl3345 { - if yyj3345 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3345Slc = r.DecodeBytes(yys3345Slc, true, true) - yys3345 := string(yys3345Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3345 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3348 := &x.ObjectMeta - yyv3348.CodecDecodeSelf(d) - } - case "target": - if r.TryDecodeAsNil() { - x.Target = ObjectReference{} - } else { - yyv3349 := &x.Target - yyv3349.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3345) - } // end switch yys3345 - } // end for yyj3345 - 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 yyj3350 int - var yyb3350 bool - var yyhl3350 bool = l >= 0 - yyj3350++ - if yyhl3350 { - yyb3350 = yyj3350 > l - } else { - yyb3350 = r.CheckBreak() - } - if yyb3350 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3350++ - if yyhl3350 { - yyb3350 = yyj3350 > l - } else { - yyb3350 = r.CheckBreak() - } - if yyb3350 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3350++ - if yyhl3350 { - yyb3350 = yyj3350 > l - } else { - yyb3350 = r.CheckBreak() - } - if yyb3350 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3353 := &x.ObjectMeta - yyv3353.CodecDecodeSelf(d) - } - yyj3350++ - if yyhl3350 { - yyb3350 = yyj3350 > l - } else { - yyb3350 = r.CheckBreak() - } - if yyb3350 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Target = ObjectReference{} - } else { - yyv3354 := &x.Target - yyv3354.CodecDecodeSelf(d) - } - for { - yyj3350++ - if yyhl3350 { - yyb3350 = yyj3350 > l - } else { - yyb3350 = r.CheckBreak() - } - if yyb3350 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3350-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 { - yym3355 := z.EncBinary() - _ = yym3355 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3356 := !z.EncBinary() - yy2arr3356 := z.EncBasicHandle().StructToArray - var yyq3356 [1]bool - _, _, _ = yysep3356, yyq3356, yy2arr3356 - const yyr3356 bool = false - yyq3356[0] = x.UID != nil - var yynn3356 int - if yyr3356 || yy2arr3356 { - r.EncodeArrayStart(1) - } else { - yynn3356 = 0 - for _, b := range yyq3356 { - if b { - yynn3356++ - } - } - r.EncodeMapStart(yynn3356) - yynn3356 = 0 - } - if yyr3356 || yy2arr3356 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3356[0] { - if x.UID == nil { - r.EncodeNil() - } else { - yy3358 := *x.UID - yym3359 := z.EncBinary() - _ = yym3359 - if false { - } else if z.HasExtensions() && z.EncExt(yy3358) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3358)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3356[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.UID == nil { - r.EncodeNil() - } else { - yy3360 := *x.UID - yym3361 := z.EncBinary() - _ = yym3361 - if false { - } else if z.HasExtensions() && z.EncExt(yy3360) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3360)) - } - } - } - } - if yyr3356 || yy2arr3356 { - 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 - yym3362 := z.DecBinary() - _ = yym3362 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3363 := r.ContainerType() - if yyct3363 == codecSelferValueTypeMap1234 { - yyl3363 := r.ReadMapStart() - if yyl3363 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3363, d) - } - } else if yyct3363 == codecSelferValueTypeArray1234 { - yyl3363 := r.ReadArrayStart() - if yyl3363 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3363, 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 yys3364Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3364Slc - var yyhl3364 bool = l >= 0 - for yyj3364 := 0; ; yyj3364++ { - if yyhl3364 { - if yyj3364 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3364Slc = r.DecodeBytes(yys3364Slc, true, true) - yys3364 := string(yys3364Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3364 { - case "uid": - if r.TryDecodeAsNil() { - if x.UID != nil { - x.UID = nil - } - } else { - if x.UID == nil { - x.UID = new(pkg1_types.UID) - } - yym3366 := z.DecBinary() - _ = yym3366 - if false { - } else if z.HasExtensions() && z.DecExt(x.UID) { - } else { - *((*string)(x.UID)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3364) - } // end switch yys3364 - } // end for yyj3364 - 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 yyj3367 int - var yyb3367 bool - var yyhl3367 bool = l >= 0 - yyj3367++ - if yyhl3367 { - yyb3367 = yyj3367 > l - } else { - yyb3367 = r.CheckBreak() - } - if yyb3367 { - 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) - } - yym3369 := z.DecBinary() - _ = yym3369 - if false { - } else if z.HasExtensions() && z.DecExt(x.UID) { - } else { - *((*string)(x.UID)) = r.DecodeString() - } - } - for { - yyj3367++ - if yyhl3367 { - yyb3367 = yyj3367 > l - } else { - yyb3367 = r.CheckBreak() - } - if yyb3367 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3367-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 { - yym3370 := z.EncBinary() - _ = yym3370 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3371 := !z.EncBinary() - yy2arr3371 := z.EncBasicHandle().StructToArray - var yyq3371 [5]bool - _, _, _ = yysep3371, yyq3371, yy2arr3371 - const yyr3371 bool = false - yyq3371[0] = x.Kind != "" - yyq3371[1] = x.APIVersion != "" - yyq3371[2] = x.GracePeriodSeconds != nil - yyq3371[3] = x.Preconditions != nil - yyq3371[4] = x.OrphanDependents != nil - var yynn3371 int - if yyr3371 || yy2arr3371 { - r.EncodeArrayStart(5) - } else { - yynn3371 = 0 - for _, b := range yyq3371 { - if b { - yynn3371++ - } - } - r.EncodeMapStart(yynn3371) - yynn3371 = 0 - } - if yyr3371 || yy2arr3371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3371[0] { - yym3373 := z.EncBinary() - _ = yym3373 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3371[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3374 := z.EncBinary() - _ = yym3374 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3371 || yy2arr3371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3371[1] { - yym3376 := z.EncBinary() - _ = yym3376 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3371[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3377 := z.EncBinary() - _ = yym3377 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3371 || yy2arr3371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3371[2] { - if x.GracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy3379 := *x.GracePeriodSeconds - yym3380 := z.EncBinary() - _ = yym3380 - if false { - } else { - r.EncodeInt(int64(yy3379)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3371[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.GracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy3381 := *x.GracePeriodSeconds - yym3382 := z.EncBinary() - _ = yym3382 - if false { - } else { - r.EncodeInt(int64(yy3381)) - } - } - } - } - if yyr3371 || yy2arr3371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3371[3] { - if x.Preconditions == nil { - r.EncodeNil() - } else { - x.Preconditions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3371[3] { - 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 yyr3371 || yy2arr3371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3371[4] { - if x.OrphanDependents == nil { - r.EncodeNil() - } else { - yy3385 := *x.OrphanDependents - yym3386 := z.EncBinary() - _ = yym3386 - if false { - } else { - r.EncodeBool(bool(yy3385)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3371[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("orphanDependents")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OrphanDependents == nil { - r.EncodeNil() - } else { - yy3387 := *x.OrphanDependents - yym3388 := z.EncBinary() - _ = yym3388 - if false { - } else { - r.EncodeBool(bool(yy3387)) - } - } - } - } - if yyr3371 || yy2arr3371 { - 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 - yym3389 := z.DecBinary() - _ = yym3389 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3390 := r.ContainerType() - if yyct3390 == codecSelferValueTypeMap1234 { - yyl3390 := r.ReadMapStart() - if yyl3390 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3390, d) - } - } else if yyct3390 == codecSelferValueTypeArray1234 { - yyl3390 := r.ReadArrayStart() - if yyl3390 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3390, 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 yys3391Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3391Slc - var yyhl3391 bool = l >= 0 - for yyj3391 := 0; ; yyj3391++ { - if yyhl3391 { - if yyj3391 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3391Slc = r.DecodeBytes(yys3391Slc, true, true) - yys3391 := string(yys3391Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3391 { - 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()) - } - case "gracePeriodSeconds": - if r.TryDecodeAsNil() { - if x.GracePeriodSeconds != nil { - x.GracePeriodSeconds = nil - } - } else { - if x.GracePeriodSeconds == nil { - x.GracePeriodSeconds = new(int64) - } - yym3395 := z.DecBinary() - _ = yym3395 - 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) - } - yym3398 := z.DecBinary() - _ = yym3398 - if false { - } else { - *((*bool)(x.OrphanDependents)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3391) - } // end switch yys3391 - } // end for yyj3391 - 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 yyj3399 int - var yyb3399 bool - var yyhl3399 bool = l >= 0 - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - 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) - } - yym3403 := z.DecBinary() - _ = yym3403 - if false { - } else { - *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - 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) - } - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - 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) - } - yym3406 := z.DecBinary() - _ = yym3406 - if false { - } else { - *((*bool)(x.OrphanDependents)) = r.DecodeBool() - } - } - for { - yyj3399++ - if yyhl3399 { - yyb3399 = yyj3399 > l - } else { - yyb3399 = r.CheckBreak() - } - if yyb3399 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3399-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 { - yym3407 := z.EncBinary() - _ = yym3407 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3408 := !z.EncBinary() - yy2arr3408 := z.EncBasicHandle().StructToArray - var yyq3408 [4]bool - _, _, _ = yysep3408, yyq3408, yy2arr3408 - const yyr3408 bool = false - yyq3408[0] = x.Kind != "" - yyq3408[1] = x.APIVersion != "" - var yynn3408 int - if yyr3408 || yy2arr3408 { - r.EncodeArrayStart(4) - } else { - yynn3408 = 2 - for _, b := range yyq3408 { - if b { - yynn3408++ - } - } - r.EncodeMapStart(yynn3408) - yynn3408 = 0 - } - if yyr3408 || yy2arr3408 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3408[0] { - yym3410 := z.EncBinary() - _ = yym3410 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3408[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3411 := z.EncBinary() - _ = yym3411 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3408 || yy2arr3408 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3408[1] { - yym3413 := z.EncBinary() - _ = yym3413 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3408[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3414 := z.EncBinary() - _ = yym3414 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3408 || yy2arr3408 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3416 := z.EncBinary() - _ = yym3416 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("export")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3417 := z.EncBinary() - _ = yym3417 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } - if yyr3408 || yy2arr3408 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3419 := z.EncBinary() - _ = yym3419 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exact")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3420 := z.EncBinary() - _ = yym3420 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } - if yyr3408 || yy2arr3408 { - 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 - yym3421 := z.DecBinary() - _ = yym3421 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3422 := r.ContainerType() - if yyct3422 == codecSelferValueTypeMap1234 { - yyl3422 := r.ReadMapStart() - if yyl3422 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3422, d) - } - } else if yyct3422 == codecSelferValueTypeArray1234 { - yyl3422 := r.ReadArrayStart() - if yyl3422 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3422, 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 yys3423Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3423Slc - var yyhl3423 bool = l >= 0 - for yyj3423 := 0; ; yyj3423++ { - if yyhl3423 { - if yyj3423 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3423Slc = r.DecodeBytes(yys3423Slc, true, true) - yys3423 := string(yys3423Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3423 { - 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()) - } - 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()) - } - default: - z.DecStructFieldNotFound(-1, yys3423) - } // end switch yys3423 - } // end for yyj3423 - 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 yyj3428 int - var yyb3428 bool - var yyhl3428 bool = l >= 0 - yyj3428++ - if yyhl3428 { - yyb3428 = yyj3428 > l - } else { - yyb3428 = r.CheckBreak() - } - if yyb3428 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3428++ - if yyhl3428 { - yyb3428 = yyj3428 > l - } else { - yyb3428 = r.CheckBreak() - } - if yyb3428 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3428++ - if yyhl3428 { - yyb3428 = yyj3428 > l - } else { - yyb3428 = r.CheckBreak() - } - if yyb3428 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Export = false - } else { - x.Export = bool(r.DecodeBool()) - } - yyj3428++ - if yyhl3428 { - yyb3428 = yyj3428 > l - } else { - yyb3428 = r.CheckBreak() - } - if yyb3428 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Exact = false - } else { - x.Exact = bool(r.DecodeBool()) - } - for { - yyj3428++ - if yyhl3428 { - yyb3428 = yyj3428 > l - } else { - yyb3428 = r.CheckBreak() - } - if yyb3428 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3428-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 { - yym3433 := z.EncBinary() - _ = yym3433 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3434 := !z.EncBinary() - yy2arr3434 := z.EncBasicHandle().StructToArray - var yyq3434 [7]bool - _, _, _ = yysep3434, yyq3434, yy2arr3434 - const yyr3434 bool = false - yyq3434[0] = x.Kind != "" - yyq3434[1] = x.APIVersion != "" - yyq3434[2] = x.LabelSelector != "" - yyq3434[3] = x.FieldSelector != "" - yyq3434[4] = x.Watch != false - yyq3434[5] = x.ResourceVersion != "" - yyq3434[6] = x.TimeoutSeconds != nil - var yynn3434 int - if yyr3434 || yy2arr3434 { - r.EncodeArrayStart(7) - } else { - yynn3434 = 0 - for _, b := range yyq3434 { - if b { - yynn3434++ - } - } - r.EncodeMapStart(yynn3434) - yynn3434 = 0 - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[0] { - yym3436 := z.EncBinary() - _ = yym3436 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3434[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3437 := z.EncBinary() - _ = yym3437 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[1] { - yym3439 := z.EncBinary() - _ = yym3439 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3434[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3440 := z.EncBinary() - _ = yym3440 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[2] { - yym3442 := z.EncBinary() - _ = yym3442 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3434[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labelSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3443 := z.EncBinary() - _ = yym3443 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[3] { - yym3445 := z.EncBinary() - _ = yym3445 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3434[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fieldSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3446 := z.EncBinary() - _ = yym3446 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[4] { - yym3448 := z.EncBinary() - _ = yym3448 - if false { - } else { - r.EncodeBool(bool(x.Watch)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3434[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("watch")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3449 := z.EncBinary() - _ = yym3449 - if false { - } else { - r.EncodeBool(bool(x.Watch)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[5] { - yym3451 := z.EncBinary() - _ = yym3451 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3434[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3452 := z.EncBinary() - _ = yym3452 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr3434 || yy2arr3434 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3434[6] { - if x.TimeoutSeconds == nil { - r.EncodeNil() - } else { - yy3454 := *x.TimeoutSeconds - yym3455 := z.EncBinary() - _ = yym3455 - if false { - } else { - r.EncodeInt(int64(yy3454)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3434[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TimeoutSeconds == nil { - r.EncodeNil() - } else { - yy3456 := *x.TimeoutSeconds - yym3457 := z.EncBinary() - _ = yym3457 - if false { - } else { - r.EncodeInt(int64(yy3456)) - } - } - } - } - if yyr3434 || yy2arr3434 { - 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 - yym3458 := z.DecBinary() - _ = yym3458 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3459 := r.ContainerType() - if yyct3459 == codecSelferValueTypeMap1234 { - yyl3459 := r.ReadMapStart() - if yyl3459 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3459, d) - } - } else if yyct3459 == codecSelferValueTypeArray1234 { - yyl3459 := r.ReadArrayStart() - if yyl3459 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3459, 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 yys3460Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3460Slc - var yyhl3460 bool = l >= 0 - for yyj3460 := 0; ; yyj3460++ { - if yyhl3460 { - if yyj3460 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3460Slc = r.DecodeBytes(yys3460Slc, true, true) - yys3460 := string(yys3460Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3460 { - 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()) - } - 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) - } - yym3468 := z.DecBinary() - _ = yym3468 - if false { - } else { - *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3460) - } // end switch yys3460 - } // end for yyj3460 - 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 yyj3469 int - var yyb3469 bool - var yyhl3469 bool = l >= 0 - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LabelSelector = "" - } else { - x.LabelSelector = string(r.DecodeString()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldSelector = "" - } else { - x.FieldSelector = string(r.DecodeString()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Watch = false - } else { - x.Watch = bool(r.DecodeBool()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - 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) - } - yym3477 := z.DecBinary() - _ = yym3477 - if false { - } else { - *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) - } - } - for { - yyj3469++ - if yyhl3469 { - yyb3469 = yyj3469 > l - } else { - yyb3469 = r.CheckBreak() - } - if yyb3469 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3469-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 { - yym3478 := z.EncBinary() - _ = yym3478 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3479 := !z.EncBinary() - yy2arr3479 := z.EncBasicHandle().StructToArray - var yyq3479 [10]bool - _, _, _ = yysep3479, yyq3479, yy2arr3479 - const yyr3479 bool = false - yyq3479[0] = x.Kind != "" - yyq3479[1] = x.APIVersion != "" - yyq3479[2] = x.Container != "" - yyq3479[3] = x.Follow != false - yyq3479[4] = x.Previous != false - yyq3479[5] = x.SinceSeconds != nil - yyq3479[6] = x.SinceTime != nil - yyq3479[7] = x.Timestamps != false - yyq3479[8] = x.TailLines != nil - yyq3479[9] = x.LimitBytes != nil - var yynn3479 int - if yyr3479 || yy2arr3479 { - r.EncodeArrayStart(10) - } else { - yynn3479 = 0 - for _, b := range yyq3479 { - if b { - yynn3479++ - } - } - r.EncodeMapStart(yynn3479) - yynn3479 = 0 - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[0] { - yym3481 := z.EncBinary() - _ = yym3481 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3479[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3482 := z.EncBinary() - _ = yym3482 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[1] { - yym3484 := z.EncBinary() - _ = yym3484 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3479[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3485 := z.EncBinary() - _ = yym3485 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[2] { - yym3487 := z.EncBinary() - _ = yym3487 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3479[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3488 := z.EncBinary() - _ = yym3488 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[3] { - yym3490 := z.EncBinary() - _ = yym3490 - if false { - } else { - r.EncodeBool(bool(x.Follow)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3479[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("follow")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3491 := z.EncBinary() - _ = yym3491 - if false { - } else { - r.EncodeBool(bool(x.Follow)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[4] { - yym3493 := z.EncBinary() - _ = yym3493 - if false { - } else { - r.EncodeBool(bool(x.Previous)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3479[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("previous")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3494 := z.EncBinary() - _ = yym3494 - if false { - } else { - r.EncodeBool(bool(x.Previous)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[5] { - if x.SinceSeconds == nil { - r.EncodeNil() - } else { - yy3496 := *x.SinceSeconds - yym3497 := z.EncBinary() - _ = yym3497 - if false { - } else { - r.EncodeInt(int64(yy3496)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3479[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sinceSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SinceSeconds == nil { - r.EncodeNil() - } else { - yy3498 := *x.SinceSeconds - yym3499 := z.EncBinary() - _ = yym3499 - if false { - } else { - r.EncodeInt(int64(yy3498)) - } - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[6] { - if x.SinceTime == nil { - r.EncodeNil() - } else { - yym3501 := z.EncBinary() - _ = yym3501 - if false { - } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3501 { - z.EncBinaryMarshal(x.SinceTime) - } else if !yym3501 && z.IsJSONHandle() { - z.EncJSONMarshal(x.SinceTime) - } else { - z.EncFallback(x.SinceTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3479[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sinceTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SinceTime == nil { - r.EncodeNil() - } else { - yym3502 := z.EncBinary() - _ = yym3502 - if false { - } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3502 { - z.EncBinaryMarshal(x.SinceTime) - } else if !yym3502 && z.IsJSONHandle() { - z.EncJSONMarshal(x.SinceTime) - } else { - z.EncFallback(x.SinceTime) - } - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[7] { - yym3504 := z.EncBinary() - _ = yym3504 - if false { - } else { - r.EncodeBool(bool(x.Timestamps)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3479[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("timestamps")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3505 := z.EncBinary() - _ = yym3505 - if false { - } else { - r.EncodeBool(bool(x.Timestamps)) - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[8] { - if x.TailLines == nil { - r.EncodeNil() - } else { - yy3507 := *x.TailLines - yym3508 := z.EncBinary() - _ = yym3508 - if false { - } else { - r.EncodeInt(int64(yy3507)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3479[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tailLines")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TailLines == nil { - r.EncodeNil() - } else { - yy3509 := *x.TailLines - yym3510 := z.EncBinary() - _ = yym3510 - if false { - } else { - r.EncodeInt(int64(yy3509)) - } - } - } - } - if yyr3479 || yy2arr3479 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3479[9] { - if x.LimitBytes == nil { - r.EncodeNil() - } else { - yy3512 := *x.LimitBytes - yym3513 := z.EncBinary() - _ = yym3513 - if false { - } else { - r.EncodeInt(int64(yy3512)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3479[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("limitBytes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LimitBytes == nil { - r.EncodeNil() - } else { - yy3514 := *x.LimitBytes - yym3515 := z.EncBinary() - _ = yym3515 - if false { - } else { - r.EncodeInt(int64(yy3514)) - } - } - } - } - if yyr3479 || yy2arr3479 { - 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 - yym3516 := z.DecBinary() - _ = yym3516 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3517 := r.ContainerType() - if yyct3517 == codecSelferValueTypeMap1234 { - yyl3517 := r.ReadMapStart() - if yyl3517 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3517, d) - } - } else if yyct3517 == codecSelferValueTypeArray1234 { - yyl3517 := r.ReadArrayStart() - if yyl3517 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3517, 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 yys3518Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3518Slc - var yyhl3518 bool = l >= 0 - for yyj3518 := 0; ; yyj3518++ { - if yyhl3518 { - if yyj3518 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3518Slc = r.DecodeBytes(yys3518Slc, true, true) - yys3518 := string(yys3518Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3518 { - 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()) - } - 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) - } - yym3525 := z.DecBinary() - _ = yym3525 - 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) - } - yym3527 := z.DecBinary() - _ = yym3527 - if false { - } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3527 { - z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3527 && 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) - } - yym3530 := z.DecBinary() - _ = yym3530 - 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) - } - yym3532 := z.DecBinary() - _ = yym3532 - if false { - } else { - *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3518) - } // end switch yys3518 - } // end for yyj3518 - 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 yyj3533 int - var yyb3533 bool - var yyhl3533 bool = l >= 0 - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Follow = false - } else { - x.Follow = bool(r.DecodeBool()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Previous = false - } else { - x.Previous = bool(r.DecodeBool()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - 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) - } - yym3540 := z.DecBinary() - _ = yym3540 - if false { - } else { - *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - 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) - } - yym3542 := z.DecBinary() - _ = yym3542 - if false { - } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3542 { - z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3542 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.SinceTime) - } else { - z.DecFallback(x.SinceTime, false) - } - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Timestamps = false - } else { - x.Timestamps = bool(r.DecodeBool()) - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - 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) - } - yym3545 := z.DecBinary() - _ = yym3545 - if false { - } else { - *((*int64)(x.TailLines)) = int64(r.DecodeInt(64)) - } - } - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - 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) - } - yym3547 := z.DecBinary() - _ = yym3547 - if false { - } else { - *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) - } - } - for { - yyj3533++ - if yyhl3533 { - yyb3533 = yyj3533 > l - } else { - yyb3533 = r.CheckBreak() - } - if yyb3533 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3533-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 { - yym3548 := z.EncBinary() - _ = yym3548 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3549 := !z.EncBinary() - yy2arr3549 := z.EncBasicHandle().StructToArray - var yyq3549 [7]bool - _, _, _ = yysep3549, yyq3549, yy2arr3549 - const yyr3549 bool = false - yyq3549[0] = x.Kind != "" - yyq3549[1] = x.APIVersion != "" - yyq3549[2] = x.Stdin != false - yyq3549[3] = x.Stdout != false - yyq3549[4] = x.Stderr != false - yyq3549[5] = x.TTY != false - yyq3549[6] = x.Container != "" - var yynn3549 int - if yyr3549 || yy2arr3549 { - r.EncodeArrayStart(7) - } else { - yynn3549 = 0 - for _, b := range yyq3549 { - if b { - yynn3549++ - } - } - r.EncodeMapStart(yynn3549) - yynn3549 = 0 - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[0] { - yym3551 := z.EncBinary() - _ = yym3551 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3549[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3552 := z.EncBinary() - _ = yym3552 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[1] { - yym3554 := z.EncBinary() - _ = yym3554 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3549[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3555 := z.EncBinary() - _ = yym3555 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[2] { - yym3557 := z.EncBinary() - _ = yym3557 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3549[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3558 := z.EncBinary() - _ = yym3558 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[3] { - yym3560 := z.EncBinary() - _ = yym3560 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3549[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdout")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3561 := z.EncBinary() - _ = yym3561 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[4] { - yym3563 := z.EncBinary() - _ = yym3563 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3549[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stderr")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3564 := z.EncBinary() - _ = yym3564 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[5] { - yym3566 := z.EncBinary() - _ = yym3566 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3549[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tty")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3567 := z.EncBinary() - _ = yym3567 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - } - if yyr3549 || yy2arr3549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3549[6] { - yym3569 := z.EncBinary() - _ = yym3569 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3549[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3570 := z.EncBinary() - _ = yym3570 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - } - if yyr3549 || yy2arr3549 { - 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 - yym3571 := z.DecBinary() - _ = yym3571 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3572 := r.ContainerType() - if yyct3572 == codecSelferValueTypeMap1234 { - yyl3572 := r.ReadMapStart() - if yyl3572 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3572, d) - } - } else if yyct3572 == codecSelferValueTypeArray1234 { - yyl3572 := r.ReadArrayStart() - if yyl3572 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3572, 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 yys3573Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3573Slc - var yyhl3573 bool = l >= 0 - for yyj3573 := 0; ; yyj3573++ { - if yyhl3573 { - if yyj3573 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3573Slc = r.DecodeBytes(yys3573Slc, true, true) - yys3573 := string(yys3573Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3573 { - 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()) - } - 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()) - } - default: - z.DecStructFieldNotFound(-1, yys3573) - } // end switch yys3573 - } // end for yyj3573 - 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 yyj3581 int - var yyb3581 bool - var yyhl3581 bool = l >= 0 - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdout = false - } else { - x.Stdout = bool(r.DecodeBool()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stderr = false - } else { - x.Stderr = bool(r.DecodeBool()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - for { - yyj3581++ - if yyhl3581 { - yyb3581 = yyj3581 > l - } else { - yyb3581 = r.CheckBreak() - } - if yyb3581 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3581-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 { - yym3589 := z.EncBinary() - _ = yym3589 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3590 := !z.EncBinary() - yy2arr3590 := z.EncBasicHandle().StructToArray - var yyq3590 [8]bool - _, _, _ = yysep3590, yyq3590, yy2arr3590 - const yyr3590 bool = false - yyq3590[0] = x.Kind != "" - yyq3590[1] = x.APIVersion != "" - yyq3590[2] = x.Stdin != false - yyq3590[3] = x.Stdout != false - yyq3590[4] = x.Stderr != false - yyq3590[5] = x.TTY != false - yyq3590[6] = x.Container != "" - var yynn3590 int - if yyr3590 || yy2arr3590 { - r.EncodeArrayStart(8) - } else { - yynn3590 = 1 - for _, b := range yyq3590 { - if b { - yynn3590++ - } - } - r.EncodeMapStart(yynn3590) - yynn3590 = 0 - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[0] { - yym3592 := z.EncBinary() - _ = yym3592 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3590[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3593 := z.EncBinary() - _ = yym3593 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[1] { - yym3595 := z.EncBinary() - _ = yym3595 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3590[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3596 := z.EncBinary() - _ = yym3596 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[2] { - yym3598 := z.EncBinary() - _ = yym3598 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3590[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3599 := z.EncBinary() - _ = yym3599 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[3] { - yym3601 := z.EncBinary() - _ = yym3601 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3590[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdout")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3602 := z.EncBinary() - _ = yym3602 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[4] { - yym3604 := z.EncBinary() - _ = yym3604 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3590[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stderr")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3605 := z.EncBinary() - _ = yym3605 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[5] { - yym3607 := z.EncBinary() - _ = yym3607 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3590[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tty")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3608 := z.EncBinary() - _ = yym3608 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3590[6] { - yym3610 := z.EncBinary() - _ = yym3610 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3590[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3611 := z.EncBinary() - _ = yym3611 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - } - if yyr3590 || yy2arr3590 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym3613 := z.EncBinary() - _ = yym3613 - 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 { - yym3614 := z.EncBinary() - _ = yym3614 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - if yyr3590 || yy2arr3590 { - 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 - yym3615 := z.DecBinary() - _ = yym3615 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3616 := r.ContainerType() - if yyct3616 == codecSelferValueTypeMap1234 { - yyl3616 := r.ReadMapStart() - if yyl3616 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3616, d) - } - } else if yyct3616 == codecSelferValueTypeArray1234 { - yyl3616 := r.ReadArrayStart() - if yyl3616 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3616, 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 yys3617Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3617Slc - var yyhl3617 bool = l >= 0 - for yyj3617 := 0; ; yyj3617++ { - if yyhl3617 { - if yyj3617 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3617Slc = r.DecodeBytes(yys3617Slc, true, true) - yys3617 := string(yys3617Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3617 { - 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()) - } - 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 { - yyv3625 := &x.Command - yym3626 := z.DecBinary() - _ = yym3626 - if false { - } else { - z.F.DecSliceStringX(yyv3625, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3617) - } // end switch yys3617 - } // end for yyj3617 - 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 yyj3627 int - var yyb3627 bool - var yyhl3627 bool = l >= 0 - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdout = false - } else { - x.Stdout = bool(r.DecodeBool()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stderr = false - } else { - x.Stderr = bool(r.DecodeBool()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv3635 := &x.Command - yym3636 := z.DecBinary() - _ = yym3636 - if false { - } else { - z.F.DecSliceStringX(yyv3635, false, d) - } - } - for { - yyj3627++ - if yyhl3627 { - yyb3627 = yyj3627 > l - } else { - yyb3627 = r.CheckBreak() - } - if yyb3627 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3627-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 { - yym3637 := z.EncBinary() - _ = yym3637 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3638 := !z.EncBinary() - yy2arr3638 := z.EncBasicHandle().StructToArray - var yyq3638 [3]bool - _, _, _ = yysep3638, yyq3638, yy2arr3638 - const yyr3638 bool = false - yyq3638[0] = x.Kind != "" - yyq3638[1] = x.APIVersion != "" - yyq3638[2] = x.Path != "" - var yynn3638 int - if yyr3638 || yy2arr3638 { - r.EncodeArrayStart(3) - } else { - yynn3638 = 0 - for _, b := range yyq3638 { - if b { - yynn3638++ - } - } - r.EncodeMapStart(yynn3638) - yynn3638 = 0 - } - if yyr3638 || yy2arr3638 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3638[0] { - yym3640 := z.EncBinary() - _ = yym3640 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3638[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3641 := z.EncBinary() - _ = yym3641 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3638 || yy2arr3638 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3638[1] { - yym3643 := z.EncBinary() - _ = yym3643 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3638[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3644 := z.EncBinary() - _ = yym3644 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3638 || yy2arr3638 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3638[2] { - yym3646 := z.EncBinary() - _ = yym3646 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3638[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3647 := z.EncBinary() - _ = yym3647 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr3638 || yy2arr3638 { - 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 - yym3648 := z.DecBinary() - _ = yym3648 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3649 := r.ContainerType() - if yyct3649 == codecSelferValueTypeMap1234 { - yyl3649 := r.ReadMapStart() - if yyl3649 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3649, d) - } - } else if yyct3649 == codecSelferValueTypeArray1234 { - yyl3649 := r.ReadArrayStart() - if yyl3649 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3649, 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 yys3650Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3650Slc - var yyhl3650 bool = l >= 0 - for yyj3650 := 0; ; yyj3650++ { - if yyhl3650 { - if yyj3650 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3650Slc = r.DecodeBytes(yys3650Slc, true, true) - yys3650 := string(yys3650Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3650 { - 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()) - } - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3650) - } // end switch yys3650 - } // end for yyj3650 - 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 yyj3654 int - var yyb3654 bool - var yyhl3654 bool = l >= 0 - yyj3654++ - if yyhl3654 { - yyb3654 = yyj3654 > l - } else { - yyb3654 = r.CheckBreak() - } - if yyb3654 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3654++ - if yyhl3654 { - yyb3654 = yyj3654 > l - } else { - yyb3654 = r.CheckBreak() - } - if yyb3654 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3654++ - if yyhl3654 { - yyb3654 = yyj3654 > l - } else { - yyb3654 = r.CheckBreak() - } - if yyb3654 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3654++ - if yyhl3654 { - yyb3654 = yyj3654 > l - } else { - yyb3654 = r.CheckBreak() - } - if yyb3654 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3654-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 { - yym3658 := z.EncBinary() - _ = yym3658 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3659 := !z.EncBinary() - yy2arr3659 := z.EncBasicHandle().StructToArray - var yyq3659 [3]bool - _, _, _ = yysep3659, yyq3659, yy2arr3659 - const yyr3659 bool = false - yyq3659[0] = x.Kind != "" - yyq3659[1] = x.APIVersion != "" - yyq3659[2] = x.Path != "" - var yynn3659 int - if yyr3659 || yy2arr3659 { - r.EncodeArrayStart(3) - } else { - yynn3659 = 0 - for _, b := range yyq3659 { - if b { - yynn3659++ - } - } - r.EncodeMapStart(yynn3659) - yynn3659 = 0 - } - if yyr3659 || yy2arr3659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3659[0] { - yym3661 := z.EncBinary() - _ = yym3661 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3659[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3662 := z.EncBinary() - _ = yym3662 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3659 || yy2arr3659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3659[1] { - yym3664 := z.EncBinary() - _ = yym3664 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3659[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3665 := z.EncBinary() - _ = yym3665 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3659 || yy2arr3659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3659[2] { - yym3667 := z.EncBinary() - _ = yym3667 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3659[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3668 := z.EncBinary() - _ = yym3668 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr3659 || yy2arr3659 { - 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 - yym3669 := z.DecBinary() - _ = yym3669 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3670 := r.ContainerType() - if yyct3670 == codecSelferValueTypeMap1234 { - yyl3670 := r.ReadMapStart() - if yyl3670 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3670, d) - } - } else if yyct3670 == codecSelferValueTypeArray1234 { - yyl3670 := r.ReadArrayStart() - if yyl3670 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3670, 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 yys3671Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3671Slc - var yyhl3671 bool = l >= 0 - for yyj3671 := 0; ; yyj3671++ { - if yyhl3671 { - if yyj3671 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3671Slc = r.DecodeBytes(yys3671Slc, true, true) - yys3671 := string(yys3671Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3671 { - 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()) - } - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3671) - } // end switch yys3671 - } // end for yyj3671 - 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 yyj3675 int - var yyb3675 bool - var yyhl3675 bool = l >= 0 - yyj3675++ - if yyhl3675 { - yyb3675 = yyj3675 > l - } else { - yyb3675 = r.CheckBreak() - } - if yyb3675 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3675++ - if yyhl3675 { - yyb3675 = yyj3675 > l - } else { - yyb3675 = r.CheckBreak() - } - if yyb3675 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3675++ - if yyhl3675 { - yyb3675 = yyj3675 > l - } else { - yyb3675 = r.CheckBreak() - } - if yyb3675 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3675++ - if yyhl3675 { - yyb3675 = yyj3675 > l - } else { - yyb3675 = r.CheckBreak() - } - if yyb3675 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3675-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 { - yym3679 := z.EncBinary() - _ = yym3679 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3680 := !z.EncBinary() - yy2arr3680 := z.EncBasicHandle().StructToArray - var yyq3680 [3]bool - _, _, _ = yysep3680, yyq3680, yy2arr3680 - const yyr3680 bool = false - yyq3680[0] = x.Kind != "" - yyq3680[1] = x.APIVersion != "" - yyq3680[2] = x.Path != "" - var yynn3680 int - if yyr3680 || yy2arr3680 { - r.EncodeArrayStart(3) - } else { - yynn3680 = 0 - for _, b := range yyq3680 { - if b { - yynn3680++ - } - } - r.EncodeMapStart(yynn3680) - yynn3680 = 0 - } - if yyr3680 || yy2arr3680 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3680[0] { - yym3682 := z.EncBinary() - _ = yym3682 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3680[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3683 := z.EncBinary() - _ = yym3683 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3680 || yy2arr3680 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3680[1] { - yym3685 := z.EncBinary() - _ = yym3685 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3680[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3686 := z.EncBinary() - _ = yym3686 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3680 || yy2arr3680 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3680[2] { - yym3688 := z.EncBinary() - _ = yym3688 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3680[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3689 := z.EncBinary() - _ = yym3689 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr3680 || yy2arr3680 { - 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 - yym3690 := z.DecBinary() - _ = yym3690 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3691 := r.ContainerType() - if yyct3691 == codecSelferValueTypeMap1234 { - yyl3691 := r.ReadMapStart() - if yyl3691 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3691, d) - } - } else if yyct3691 == codecSelferValueTypeArray1234 { - yyl3691 := r.ReadArrayStart() - if yyl3691 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3691, 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 yys3692Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3692Slc - var yyhl3692 bool = l >= 0 - for yyj3692 := 0; ; yyj3692++ { - if yyhl3692 { - if yyj3692 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3692Slc = r.DecodeBytes(yys3692Slc, true, true) - yys3692 := string(yys3692Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3692 { - 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()) - } - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3692) - } // end switch yys3692 - } // end for yyj3692 - 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 yyj3696 int - var yyb3696 bool - var yyhl3696 bool = l >= 0 - yyj3696++ - if yyhl3696 { - yyb3696 = yyj3696 > l - } else { - yyb3696 = r.CheckBreak() - } - if yyb3696 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3696++ - if yyhl3696 { - yyb3696 = yyj3696 > l - } else { - yyb3696 = r.CheckBreak() - } - if yyb3696 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3696++ - if yyhl3696 { - yyb3696 = yyj3696 > l - } else { - yyb3696 = r.CheckBreak() - } - if yyb3696 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3696++ - if yyhl3696 { - yyb3696 = yyj3696 > l - } else { - yyb3696 = r.CheckBreak() - } - if yyb3696 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3696-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 { - yym3700 := z.EncBinary() - _ = yym3700 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3701 := !z.EncBinary() - yy2arr3701 := z.EncBasicHandle().StructToArray - var yyq3701 [5]bool - _, _, _ = yysep3701, yyq3701, yy2arr3701 - const yyr3701 bool = false - yyq3701[4] = x.Controller != nil - var yynn3701 int - if yyr3701 || yy2arr3701 { - r.EncodeArrayStart(5) - } else { - yynn3701 = 4 - for _, b := range yyq3701 { - if b { - yynn3701++ - } - } - r.EncodeMapStart(yynn3701) - yynn3701 = 0 - } - if yyr3701 || yy2arr3701 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3703 := z.EncBinary() - _ = yym3703 - 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) - yym3704 := z.EncBinary() - _ = yym3704 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - if yyr3701 || yy2arr3701 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3706 := z.EncBinary() - _ = yym3706 - 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) - yym3707 := z.EncBinary() - _ = yym3707 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - if yyr3701 || yy2arr3701 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3709 := z.EncBinary() - _ = yym3709 - 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) - yym3710 := z.EncBinary() - _ = yym3710 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr3701 || yy2arr3701 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3712 := z.EncBinary() - _ = yym3712 - 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) - yym3713 := z.EncBinary() - _ = yym3713 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - if yyr3701 || yy2arr3701 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3701[4] { - if x.Controller == nil { - r.EncodeNil() - } else { - yy3715 := *x.Controller - yym3716 := z.EncBinary() - _ = yym3716 - if false { - } else { - r.EncodeBool(bool(yy3715)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3701[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("controller")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Controller == nil { - r.EncodeNil() - } else { - yy3717 := *x.Controller - yym3718 := z.EncBinary() - _ = yym3718 - if false { - } else { - r.EncodeBool(bool(yy3717)) - } - } - } - } - if yyr3701 || yy2arr3701 { - 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 - yym3719 := z.DecBinary() - _ = yym3719 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3720 := r.ContainerType() - if yyct3720 == codecSelferValueTypeMap1234 { - yyl3720 := r.ReadMapStart() - if yyl3720 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3720, d) - } - } else if yyct3720 == codecSelferValueTypeArray1234 { - yyl3720 := r.ReadArrayStart() - if yyl3720 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3720, 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 yys3721Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3721Slc - var yyhl3721 bool = l >= 0 - for yyj3721 := 0; ; yyj3721++ { - if yyhl3721 { - if yyj3721 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3721Slc = r.DecodeBytes(yys3721Slc, true, true) - yys3721 := string(yys3721Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3721 { - 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) - } - yym3727 := z.DecBinary() - _ = yym3727 - if false { - } else { - *((*bool)(x.Controller)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3721) - } // end switch yys3721 - } // end for yyj3721 - 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 yyj3728 int - var yyb3728 bool - var yyhl3728 bool = l >= 0 - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) - } - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - 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) - } - yym3734 := z.DecBinary() - _ = yym3734 - if false { - } else { - *((*bool)(x.Controller)) = r.DecodeBool() - } - } - for { - yyj3728++ - if yyhl3728 { - yyb3728 = yyj3728 > l - } else { - yyb3728 = r.CheckBreak() - } - if yyb3728 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3728-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 { - yym3735 := z.EncBinary() - _ = yym3735 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3736 := !z.EncBinary() - yy2arr3736 := z.EncBasicHandle().StructToArray - var yyq3736 [7]bool - _, _, _ = yysep3736, yyq3736, yy2arr3736 - const yyr3736 bool = false - yyq3736[0] = x.Kind != "" - yyq3736[1] = x.Namespace != "" - yyq3736[2] = x.Name != "" - yyq3736[3] = x.UID != "" - yyq3736[4] = x.APIVersion != "" - yyq3736[5] = x.ResourceVersion != "" - yyq3736[6] = x.FieldPath != "" - var yynn3736 int - if yyr3736 || yy2arr3736 { - r.EncodeArrayStart(7) - } else { - yynn3736 = 0 - for _, b := range yyq3736 { - if b { - yynn3736++ - } - } - r.EncodeMapStart(yynn3736) - yynn3736 = 0 - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[0] { - yym3738 := z.EncBinary() - _ = yym3738 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3739 := z.EncBinary() - _ = yym3739 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[1] { - yym3741 := z.EncBinary() - _ = yym3741 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3742 := z.EncBinary() - _ = yym3742 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[2] { - yym3744 := z.EncBinary() - _ = yym3744 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3745 := z.EncBinary() - _ = yym3745 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[3] { - yym3747 := z.EncBinary() - _ = yym3747 - 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 yyq3736[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3748 := z.EncBinary() - _ = yym3748 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[4] { - yym3750 := z.EncBinary() - _ = yym3750 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3751 := z.EncBinary() - _ = yym3751 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[5] { - yym3753 := z.EncBinary() - _ = yym3753 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3754 := z.EncBinary() - _ = yym3754 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr3736 || yy2arr3736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3736[6] { - yym3756 := z.EncBinary() - _ = yym3756 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3736[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fieldPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3757 := z.EncBinary() - _ = yym3757 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } - } - if yyr3736 || yy2arr3736 { - 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 - yym3758 := z.DecBinary() - _ = yym3758 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3759 := r.ContainerType() - if yyct3759 == codecSelferValueTypeMap1234 { - yyl3759 := r.ReadMapStart() - if yyl3759 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3759, d) - } - } else if yyct3759 == codecSelferValueTypeArray1234 { - yyl3759 := r.ReadArrayStart() - if yyl3759 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3759, 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 yys3760Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3760Slc - var yyhl3760 bool = l >= 0 - for yyj3760 := 0; ; yyj3760++ { - if yyhl3760 { - if yyj3760 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3760Slc = r.DecodeBytes(yys3760Slc, true, true) - yys3760 := string(yys3760Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3760 { - 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, yys3760) - } // end switch yys3760 - } // end for yyj3760 - 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 yyj3768 int - var yyb3768 bool - var yyhl3768 bool = l >= 0 - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldPath = "" - } else { - x.FieldPath = string(r.DecodeString()) - } - for { - yyj3768++ - if yyhl3768 { - yyb3768 = yyj3768 > l - } else { - yyb3768 = r.CheckBreak() - } - if yyb3768 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3768-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 { - yym3776 := z.EncBinary() - _ = yym3776 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3777 := !z.EncBinary() - yy2arr3777 := z.EncBasicHandle().StructToArray - var yyq3777 [1]bool - _, _, _ = yysep3777, yyq3777, yy2arr3777 - const yyr3777 bool = false - yyq3777[0] = x.Name != "" - var yynn3777 int - if yyr3777 || yy2arr3777 { - r.EncodeArrayStart(1) - } else { - yynn3777 = 0 - for _, b := range yyq3777 { - if b { - yynn3777++ - } - } - r.EncodeMapStart(yynn3777) - yynn3777 = 0 - } - if yyr3777 || yy2arr3777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3777[0] { - yym3779 := z.EncBinary() - _ = yym3779 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3777[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3780 := z.EncBinary() - _ = yym3780 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr3777 || yy2arr3777 { - 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 - yym3781 := z.DecBinary() - _ = yym3781 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3782 := r.ContainerType() - if yyct3782 == codecSelferValueTypeMap1234 { - yyl3782 := r.ReadMapStart() - if yyl3782 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3782, d) - } - } else if yyct3782 == codecSelferValueTypeArray1234 { - yyl3782 := r.ReadArrayStart() - if yyl3782 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3782, 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 yys3783Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3783Slc - var yyhl3783 bool = l >= 0 - for yyj3783 := 0; ; yyj3783++ { - if yyhl3783 { - if yyj3783 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3783Slc = r.DecodeBytes(yys3783Slc, true, true) - yys3783 := string(yys3783Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3783 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3783) - } // end switch yys3783 - } // end for yyj3783 - 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 yyj3785 int - var yyb3785 bool - var yyhl3785 bool = l >= 0 - yyj3785++ - if yyhl3785 { - yyb3785 = yyj3785 > l - } else { - yyb3785 = r.CheckBreak() - } - if yyb3785 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - for { - yyj3785++ - if yyhl3785 { - yyb3785 = yyj3785 > l - } else { - yyb3785 = r.CheckBreak() - } - if yyb3785 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3785-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 { - yym3787 := z.EncBinary() - _ = yym3787 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3788 := !z.EncBinary() - yy2arr3788 := z.EncBasicHandle().StructToArray - var yyq3788 [3]bool - _, _, _ = yysep3788, yyq3788, yy2arr3788 - const yyr3788 bool = false - yyq3788[0] = x.Kind != "" - yyq3788[1] = x.APIVersion != "" - yyq3788[2] = true - var yynn3788 int - if yyr3788 || yy2arr3788 { - r.EncodeArrayStart(3) - } else { - yynn3788 = 0 - for _, b := range yyq3788 { - if b { - yynn3788++ - } - } - r.EncodeMapStart(yynn3788) - yynn3788 = 0 - } - if yyr3788 || yy2arr3788 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3788[0] { - yym3790 := z.EncBinary() - _ = yym3790 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3788[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3791 := z.EncBinary() - _ = yym3791 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3788 || yy2arr3788 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3788[1] { - yym3793 := z.EncBinary() - _ = yym3793 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3788[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3794 := z.EncBinary() - _ = yym3794 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3788 || yy2arr3788 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3788[2] { - yy3796 := &x.Reference - yy3796.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3788[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reference")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3797 := &x.Reference - yy3797.CodecEncodeSelf(e) - } - } - if yyr3788 || yy2arr3788 { - 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 - yym3798 := z.DecBinary() - _ = yym3798 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3799 := r.ContainerType() - if yyct3799 == codecSelferValueTypeMap1234 { - yyl3799 := r.ReadMapStart() - if yyl3799 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3799, d) - } - } else if yyct3799 == codecSelferValueTypeArray1234 { - yyl3799 := r.ReadArrayStart() - if yyl3799 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3799, 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 yys3800Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3800Slc - var yyhl3800 bool = l >= 0 - for yyj3800 := 0; ; yyj3800++ { - if yyhl3800 { - if yyj3800 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3800Slc = r.DecodeBytes(yys3800Slc, true, true) - yys3800 := string(yys3800Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3800 { - 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()) - } - case "reference": - if r.TryDecodeAsNil() { - x.Reference = ObjectReference{} - } else { - yyv3803 := &x.Reference - yyv3803.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3800) - } // end switch yys3800 - } // end for yyj3800 - 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 yyj3804 int - var yyb3804 bool - var yyhl3804 bool = l >= 0 - yyj3804++ - if yyhl3804 { - yyb3804 = yyj3804 > l - } else { - yyb3804 = r.CheckBreak() - } - if yyb3804 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3804++ - if yyhl3804 { - yyb3804 = yyj3804 > l - } else { - yyb3804 = r.CheckBreak() - } - if yyb3804 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3804++ - if yyhl3804 { - yyb3804 = yyj3804 > l - } else { - yyb3804 = r.CheckBreak() - } - if yyb3804 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reference = ObjectReference{} - } else { - yyv3807 := &x.Reference - yyv3807.CodecDecodeSelf(d) - } - for { - yyj3804++ - if yyhl3804 { - yyb3804 = yyj3804 > l - } else { - yyb3804 = r.CheckBreak() - } - if yyb3804 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3804-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 { - yym3808 := z.EncBinary() - _ = yym3808 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3809 := !z.EncBinary() - yy2arr3809 := z.EncBasicHandle().StructToArray - var yyq3809 [2]bool - _, _, _ = yysep3809, yyq3809, yy2arr3809 - const yyr3809 bool = false - yyq3809[0] = x.Component != "" - yyq3809[1] = x.Host != "" - var yynn3809 int - if yyr3809 || yy2arr3809 { - r.EncodeArrayStart(2) - } else { - yynn3809 = 0 - for _, b := range yyq3809 { - if b { - yynn3809++ - } - } - r.EncodeMapStart(yynn3809) - yynn3809 = 0 - } - if yyr3809 || yy2arr3809 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3809[0] { - yym3811 := z.EncBinary() - _ = yym3811 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Component)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3809[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("component")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3812 := z.EncBinary() - _ = yym3812 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Component)) - } - } - } - if yyr3809 || yy2arr3809 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3809[1] { - yym3814 := z.EncBinary() - _ = yym3814 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3809[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("host")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3815 := z.EncBinary() - _ = yym3815 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } - } - if yyr3809 || yy2arr3809 { - 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 - yym3816 := z.DecBinary() - _ = yym3816 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3817 := r.ContainerType() - if yyct3817 == codecSelferValueTypeMap1234 { - yyl3817 := r.ReadMapStart() - if yyl3817 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3817, d) - } - } else if yyct3817 == codecSelferValueTypeArray1234 { - yyl3817 := r.ReadArrayStart() - if yyl3817 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3817, 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 yys3818Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3818Slc - var yyhl3818 bool = l >= 0 - for yyj3818 := 0; ; yyj3818++ { - if yyhl3818 { - if yyj3818 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3818Slc = r.DecodeBytes(yys3818Slc, true, true) - yys3818 := string(yys3818Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3818 { - 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, yys3818) - } // end switch yys3818 - } // end for yyj3818 - 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 yyj3821 int - var yyb3821 bool - var yyhl3821 bool = l >= 0 - yyj3821++ - if yyhl3821 { - yyb3821 = yyj3821 > l - } else { - yyb3821 = r.CheckBreak() - } - if yyb3821 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Component = "" - } else { - x.Component = string(r.DecodeString()) - } - yyj3821++ - if yyhl3821 { - yyb3821 = yyj3821 > l - } else { - yyb3821 = r.CheckBreak() - } - if yyb3821 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - for { - yyj3821++ - if yyhl3821 { - yyb3821 = yyj3821 > l - } else { - yyb3821 = r.CheckBreak() - } - if yyb3821 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3821-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 { - yym3824 := z.EncBinary() - _ = yym3824 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3825 := !z.EncBinary() - yy2arr3825 := z.EncBasicHandle().StructToArray - var yyq3825 [11]bool - _, _, _ = yysep3825, yyq3825, yy2arr3825 - const yyr3825 bool = false - yyq3825[0] = x.Kind != "" - yyq3825[1] = x.APIVersion != "" - yyq3825[4] = x.Reason != "" - yyq3825[5] = x.Message != "" - yyq3825[6] = true - yyq3825[7] = true - yyq3825[8] = true - yyq3825[9] = x.Count != 0 - yyq3825[10] = x.Type != "" - var yynn3825 int - if yyr3825 || yy2arr3825 { - r.EncodeArrayStart(11) - } else { - yynn3825 = 2 - for _, b := range yyq3825 { - if b { - yynn3825++ - } - } - r.EncodeMapStart(yynn3825) - yynn3825 = 0 - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[0] { - yym3827 := z.EncBinary() - _ = yym3827 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3825[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3828 := z.EncBinary() - _ = yym3828 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[1] { - yym3830 := z.EncBinary() - _ = yym3830 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3825[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3831 := z.EncBinary() - _ = yym3831 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3833 := &x.ObjectMeta - yy3833.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3834 := &x.ObjectMeta - yy3834.CodecEncodeSelf(e) - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3836 := &x.InvolvedObject - yy3836.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("involvedObject")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3837 := &x.InvolvedObject - yy3837.CodecEncodeSelf(e) - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[4] { - yym3839 := z.EncBinary() - _ = yym3839 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3825[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3840 := z.EncBinary() - _ = yym3840 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[5] { - yym3842 := z.EncBinary() - _ = yym3842 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3825[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3843 := z.EncBinary() - _ = yym3843 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[6] { - yy3845 := &x.Source - yy3845.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3825[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("source")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3846 := &x.Source - yy3846.CodecEncodeSelf(e) - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[7] { - yy3848 := &x.FirstTimestamp - yym3849 := z.EncBinary() - _ = yym3849 - if false { - } else if z.HasExtensions() && z.EncExt(yy3848) { - } else if yym3849 { - z.EncBinaryMarshal(yy3848) - } else if !yym3849 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3848) - } else { - z.EncFallback(yy3848) - } - } else { - r.EncodeNil() - } - } else { - if yyq3825[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("firstTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3850 := &x.FirstTimestamp - yym3851 := z.EncBinary() - _ = yym3851 - if false { - } else if z.HasExtensions() && z.EncExt(yy3850) { - } else if yym3851 { - z.EncBinaryMarshal(yy3850) - } else if !yym3851 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3850) - } else { - z.EncFallback(yy3850) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[8] { - yy3853 := &x.LastTimestamp - yym3854 := z.EncBinary() - _ = yym3854 - if false { - } else if z.HasExtensions() && z.EncExt(yy3853) { - } else if yym3854 { - z.EncBinaryMarshal(yy3853) - } else if !yym3854 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3853) - } else { - z.EncFallback(yy3853) - } - } else { - r.EncodeNil() - } - } else { - if yyq3825[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3855 := &x.LastTimestamp - yym3856 := z.EncBinary() - _ = yym3856 - if false { - } else if z.HasExtensions() && z.EncExt(yy3855) { - } else if yym3856 { - z.EncBinaryMarshal(yy3855) - } else if !yym3856 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3855) - } else { - z.EncFallback(yy3855) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[9] { - yym3858 := z.EncBinary() - _ = yym3858 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq3825[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("count")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3859 := z.EncBinary() - _ = yym3859 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } - } - if yyr3825 || yy2arr3825 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3825[10] { - yym3861 := z.EncBinary() - _ = yym3861 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3825[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3862 := z.EncBinary() - _ = yym3862 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } - } - if yyr3825 || yy2arr3825 { - 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 - yym3863 := z.DecBinary() - _ = yym3863 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3864 := r.ContainerType() - if yyct3864 == codecSelferValueTypeMap1234 { - yyl3864 := r.ReadMapStart() - if yyl3864 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3864, d) - } - } else if yyct3864 == codecSelferValueTypeArray1234 { - yyl3864 := r.ReadArrayStart() - if yyl3864 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3864, 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 yys3865Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3865Slc - var yyhl3865 bool = l >= 0 - for yyj3865 := 0; ; yyj3865++ { - if yyhl3865 { - if yyj3865 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3865Slc = r.DecodeBytes(yys3865Slc, true, true) - yys3865 := string(yys3865Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3865 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3868 := &x.ObjectMeta - yyv3868.CodecDecodeSelf(d) - } - case "involvedObject": - if r.TryDecodeAsNil() { - x.InvolvedObject = ObjectReference{} - } else { - yyv3869 := &x.InvolvedObject - yyv3869.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 { - yyv3872 := &x.Source - yyv3872.CodecDecodeSelf(d) - } - case "firstTimestamp": - if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} - } else { - yyv3873 := &x.FirstTimestamp - yym3874 := z.DecBinary() - _ = yym3874 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3873) { - } else if yym3874 { - z.DecBinaryUnmarshal(yyv3873) - } else if !yym3874 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3873) - } else { - z.DecFallback(yyv3873, false) - } - } - case "lastTimestamp": - if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} - } else { - yyv3875 := &x.LastTimestamp - yym3876 := z.DecBinary() - _ = yym3876 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3875) { - } else if yym3876 { - z.DecBinaryUnmarshal(yyv3875) - } else if !yym3876 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3875) - } else { - z.DecFallback(yyv3875, 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()) - } - default: - z.DecStructFieldNotFound(-1, yys3865) - } // end switch yys3865 - } // end for yyj3865 - 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 yyj3879 int - var yyb3879 bool - var yyhl3879 bool = l >= 0 - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3882 := &x.ObjectMeta - yyv3882.CodecDecodeSelf(d) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.InvolvedObject = ObjectReference{} - } else { - yyv3883 := &x.InvolvedObject - yyv3883.CodecDecodeSelf(d) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Source = EventSource{} - } else { - yyv3886 := &x.Source - yyv3886.CodecDecodeSelf(d) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} - } else { - yyv3887 := &x.FirstTimestamp - yym3888 := z.DecBinary() - _ = yym3888 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3887) { - } else if yym3888 { - z.DecBinaryUnmarshal(yyv3887) - } else if !yym3888 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3887) - } else { - z.DecFallback(yyv3887, false) - } - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} - } else { - yyv3889 := &x.LastTimestamp - yym3890 := z.DecBinary() - _ = yym3890 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3889) { - } else if yym3890 { - z.DecBinaryUnmarshal(yyv3889) - } else if !yym3890 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3889) - } else { - z.DecFallback(yyv3889, false) - } - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Count = 0 - } else { - x.Count = int32(r.DecodeInt(32)) - } - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = string(r.DecodeString()) - } - for { - yyj3879++ - if yyhl3879 { - yyb3879 = yyj3879 > l - } else { - yyb3879 = r.CheckBreak() - } - if yyb3879 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3879-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 { - yym3893 := z.EncBinary() - _ = yym3893 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3894 := !z.EncBinary() - yy2arr3894 := z.EncBasicHandle().StructToArray - var yyq3894 [4]bool - _, _, _ = yysep3894, yyq3894, yy2arr3894 - const yyr3894 bool = false - yyq3894[0] = x.Kind != "" - yyq3894[1] = x.APIVersion != "" - yyq3894[2] = true - var yynn3894 int - if yyr3894 || yy2arr3894 { - r.EncodeArrayStart(4) - } else { - yynn3894 = 1 - for _, b := range yyq3894 { - if b { - yynn3894++ - } - } - r.EncodeMapStart(yynn3894) - yynn3894 = 0 - } - if yyr3894 || yy2arr3894 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3894[0] { - yym3896 := z.EncBinary() - _ = yym3896 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3894[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3897 := z.EncBinary() - _ = yym3897 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3894 || yy2arr3894 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3894[1] { - yym3899 := z.EncBinary() - _ = yym3899 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3894[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3900 := z.EncBinary() - _ = yym3900 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3894 || yy2arr3894 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3894[2] { - yy3902 := &x.ListMeta - yym3903 := z.EncBinary() - _ = yym3903 - if false { - } else if z.HasExtensions() && z.EncExt(yy3902) { - } else { - z.EncFallback(yy3902) - } - } else { - r.EncodeNil() - } - } else { - if yyq3894[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3904 := &x.ListMeta - yym3905 := z.EncBinary() - _ = yym3905 - if false { - } else if z.HasExtensions() && z.EncExt(yy3904) { - } else { - z.EncFallback(yy3904) - } - } - } - if yyr3894 || yy2arr3894 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3907 := z.EncBinary() - _ = yym3907 - 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 { - yym3908 := z.EncBinary() - _ = yym3908 - if false { - } else { - h.encSliceEvent(([]Event)(x.Items), e) - } - } - } - if yyr3894 || yy2arr3894 { - 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 - yym3909 := z.DecBinary() - _ = yym3909 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3910 := r.ContainerType() - if yyct3910 == codecSelferValueTypeMap1234 { - yyl3910 := r.ReadMapStart() - if yyl3910 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3910, d) - } - } else if yyct3910 == codecSelferValueTypeArray1234 { - yyl3910 := r.ReadArrayStart() - if yyl3910 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3910, 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 yys3911Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3911Slc - var yyhl3911 bool = l >= 0 - for yyj3911 := 0; ; yyj3911++ { - if yyhl3911 { - if yyj3911 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3911Slc = r.DecodeBytes(yys3911Slc, true, true) - yys3911 := string(yys3911Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3911 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3914 := &x.ListMeta - yym3915 := z.DecBinary() - _ = yym3915 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3914) { - } else { - z.DecFallback(yyv3914, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3916 := &x.Items - yym3917 := z.DecBinary() - _ = yym3917 - if false { - } else { - h.decSliceEvent((*[]Event)(yyv3916), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3911) - } // end switch yys3911 - } // end for yyj3911 - 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 yyj3918 int - var yyb3918 bool - var yyhl3918 bool = l >= 0 - yyj3918++ - if yyhl3918 { - yyb3918 = yyj3918 > l - } else { - yyb3918 = r.CheckBreak() - } - if yyb3918 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3918++ - if yyhl3918 { - yyb3918 = yyj3918 > l - } else { - yyb3918 = r.CheckBreak() - } - if yyb3918 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3918++ - if yyhl3918 { - yyb3918 = yyj3918 > l - } else { - yyb3918 = r.CheckBreak() - } - if yyb3918 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3921 := &x.ListMeta - yym3922 := z.DecBinary() - _ = yym3922 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3921) { - } else { - z.DecFallback(yyv3921, false) - } - } - yyj3918++ - if yyhl3918 { - yyb3918 = yyj3918 > l - } else { - yyb3918 = r.CheckBreak() - } - if yyb3918 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3923 := &x.Items - yym3924 := z.DecBinary() - _ = yym3924 - if false { - } else { - h.decSliceEvent((*[]Event)(yyv3923), d) - } - } - for { - yyj3918++ - if yyhl3918 { - yyb3918 = yyj3918 > l - } else { - yyb3918 = r.CheckBreak() - } - if yyb3918 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3918-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 { - yym3925 := z.EncBinary() - _ = yym3925 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3926 := !z.EncBinary() - yy2arr3926 := z.EncBasicHandle().StructToArray - var yyq3926 [4]bool - _, _, _ = yysep3926, yyq3926, yy2arr3926 - const yyr3926 bool = false - yyq3926[0] = x.Kind != "" - yyq3926[1] = x.APIVersion != "" - yyq3926[2] = true - var yynn3926 int - if yyr3926 || yy2arr3926 { - r.EncodeArrayStart(4) - } else { - yynn3926 = 1 - for _, b := range yyq3926 { - if b { - yynn3926++ - } - } - r.EncodeMapStart(yynn3926) - yynn3926 = 0 - } - if yyr3926 || yy2arr3926 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3926[0] { - yym3928 := z.EncBinary() - _ = yym3928 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3926[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3929 := z.EncBinary() - _ = yym3929 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3926 || yy2arr3926 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3926[1] { - yym3931 := z.EncBinary() - _ = yym3931 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3926[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3932 := z.EncBinary() - _ = yym3932 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3926 || yy2arr3926 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3926[2] { - yy3934 := &x.ListMeta - yym3935 := z.EncBinary() - _ = yym3935 - if false { - } else if z.HasExtensions() && z.EncExt(yy3934) { - } else { - z.EncFallback(yy3934) - } - } else { - r.EncodeNil() - } - } else { - if yyq3926[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3936 := &x.ListMeta - yym3937 := z.EncBinary() - _ = yym3937 - if false { - } else if z.HasExtensions() && z.EncExt(yy3936) { - } else { - z.EncFallback(yy3936) - } - } - } - if yyr3926 || yy2arr3926 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3939 := z.EncBinary() - _ = yym3939 - 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 { - yym3940 := z.EncBinary() - _ = yym3940 - if false { - } else { - h.encSliceruntime_RawExtension(([]pkg5_runtime.RawExtension)(x.Items), e) - } - } - } - if yyr3926 || yy2arr3926 { - 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 - yym3941 := z.DecBinary() - _ = yym3941 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3942 := r.ContainerType() - if yyct3942 == codecSelferValueTypeMap1234 { - yyl3942 := r.ReadMapStart() - if yyl3942 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3942, d) - } - } else if yyct3942 == codecSelferValueTypeArray1234 { - yyl3942 := r.ReadArrayStart() - if yyl3942 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3942, 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 yys3943Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3943Slc - var yyhl3943 bool = l >= 0 - for yyj3943 := 0; ; yyj3943++ { - if yyhl3943 { - if yyj3943 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3943Slc = r.DecodeBytes(yys3943Slc, true, true) - yys3943 := string(yys3943Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3943 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3946 := &x.ListMeta - yym3947 := z.DecBinary() - _ = yym3947 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3946) { - } else { - z.DecFallback(yyv3946, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3948 := &x.Items - yym3949 := z.DecBinary() - _ = yym3949 - if false { - } else { - h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv3948), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3943) - } // end switch yys3943 - } // end for yyj3943 - 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 yyj3950 int - var yyb3950 bool - var yyhl3950 bool = l >= 0 - yyj3950++ - if yyhl3950 { - yyb3950 = yyj3950 > l - } else { - yyb3950 = r.CheckBreak() - } - if yyb3950 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3950++ - if yyhl3950 { - yyb3950 = yyj3950 > l - } else { - yyb3950 = r.CheckBreak() - } - if yyb3950 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3950++ - if yyhl3950 { - yyb3950 = yyj3950 > l - } else { - yyb3950 = r.CheckBreak() - } - if yyb3950 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3953 := &x.ListMeta - yym3954 := z.DecBinary() - _ = yym3954 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3953) { - } else { - z.DecFallback(yyv3953, false) - } - } - yyj3950++ - if yyhl3950 { - yyb3950 = yyj3950 > l - } else { - yyb3950 = r.CheckBreak() - } - if yyb3950 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3955 := &x.Items - yym3956 := z.DecBinary() - _ = yym3956 - if false { - } else { - h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv3955), d) - } - } - for { - yyj3950++ - if yyhl3950 { - yyb3950 = yyj3950 > l - } else { - yyb3950 = r.CheckBreak() - } - if yyb3950 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3950-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x LimitType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3957 := z.EncBinary() - _ = yym3957 - 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 - yym3958 := z.DecBinary() - _ = yym3958 - 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 { - yym3959 := z.EncBinary() - _ = yym3959 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3960 := !z.EncBinary() - yy2arr3960 := z.EncBasicHandle().StructToArray - var yyq3960 [6]bool - _, _, _ = yysep3960, yyq3960, yy2arr3960 - const yyr3960 bool = false - yyq3960[0] = x.Type != "" - yyq3960[1] = len(x.Max) != 0 - yyq3960[2] = len(x.Min) != 0 - yyq3960[3] = len(x.Default) != 0 - yyq3960[4] = len(x.DefaultRequest) != 0 - yyq3960[5] = len(x.MaxLimitRequestRatio) != 0 - var yynn3960 int - if yyr3960 || yy2arr3960 { - r.EncodeArrayStart(6) - } else { - yynn3960 = 0 - for _, b := range yyq3960 { - if b { - yynn3960++ - } - } - r.EncodeMapStart(yynn3960) - yynn3960 = 0 - } - if yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[0] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3960[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[1] { - if x.Max == nil { - r.EncodeNil() - } else { - x.Max.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3960[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 yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[2] { - if x.Min == nil { - r.EncodeNil() - } else { - x.Min.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3960[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 yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[3] { - if x.Default == nil { - r.EncodeNil() - } else { - x.Default.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3960[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 yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[4] { - if x.DefaultRequest == nil { - r.EncodeNil() - } else { - x.DefaultRequest.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3960[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 yyr3960 || yy2arr3960 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3960[5] { - if x.MaxLimitRequestRatio == nil { - r.EncodeNil() - } else { - x.MaxLimitRequestRatio.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3960[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 yyr3960 || yy2arr3960 { - 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 - yym3967 := z.DecBinary() - _ = yym3967 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3968 := r.ContainerType() - if yyct3968 == codecSelferValueTypeMap1234 { - yyl3968 := r.ReadMapStart() - if yyl3968 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3968, d) - } - } else if yyct3968 == codecSelferValueTypeArray1234 { - yyl3968 := r.ReadArrayStart() - if yyl3968 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3968, 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 yys3969Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3969Slc - var yyhl3969 bool = l >= 0 - for yyj3969 := 0; ; yyj3969++ { - if yyhl3969 { - if yyj3969 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3969Slc = r.DecodeBytes(yys3969Slc, true, true) - yys3969 := string(yys3969Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3969 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = LimitType(r.DecodeString()) - } - case "max": - if r.TryDecodeAsNil() { - x.Max = nil - } else { - yyv3971 := &x.Max - yyv3971.CodecDecodeSelf(d) - } - case "min": - if r.TryDecodeAsNil() { - x.Min = nil - } else { - yyv3972 := &x.Min - yyv3972.CodecDecodeSelf(d) - } - case "default": - if r.TryDecodeAsNil() { - x.Default = nil - } else { - yyv3973 := &x.Default - yyv3973.CodecDecodeSelf(d) - } - case "defaultRequest": - if r.TryDecodeAsNil() { - x.DefaultRequest = nil - } else { - yyv3974 := &x.DefaultRequest - yyv3974.CodecDecodeSelf(d) - } - case "maxLimitRequestRatio": - if r.TryDecodeAsNil() { - x.MaxLimitRequestRatio = nil - } else { - yyv3975 := &x.MaxLimitRequestRatio - yyv3975.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3969) - } // end switch yys3969 - } // end for yyj3969 - 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 yyj3976 int - var yyb3976 bool - var yyhl3976 bool = l >= 0 - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = LimitType(r.DecodeString()) - } - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Max = nil - } else { - yyv3978 := &x.Max - yyv3978.CodecDecodeSelf(d) - } - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Min = nil - } else { - yyv3979 := &x.Min - yyv3979.CodecDecodeSelf(d) - } - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Default = nil - } else { - yyv3980 := &x.Default - yyv3980.CodecDecodeSelf(d) - } - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DefaultRequest = nil - } else { - yyv3981 := &x.DefaultRequest - yyv3981.CodecDecodeSelf(d) - } - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxLimitRequestRatio = nil - } else { - yyv3982 := &x.MaxLimitRequestRatio - yyv3982.CodecDecodeSelf(d) - } - for { - yyj3976++ - if yyhl3976 { - yyb3976 = yyj3976 > l - } else { - yyb3976 = r.CheckBreak() - } - if yyb3976 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3976-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 { - yym3983 := z.EncBinary() - _ = yym3983 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3984 := !z.EncBinary() - yy2arr3984 := z.EncBasicHandle().StructToArray - var yyq3984 [1]bool - _, _, _ = yysep3984, yyq3984, yy2arr3984 - const yyr3984 bool = false - var yynn3984 int - if yyr3984 || yy2arr3984 { - r.EncodeArrayStart(1) - } else { - yynn3984 = 1 - for _, b := range yyq3984 { - if b { - yynn3984++ - } - } - r.EncodeMapStart(yynn3984) - yynn3984 = 0 - } - if yyr3984 || yy2arr3984 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Limits == nil { - r.EncodeNil() - } else { - yym3986 := z.EncBinary() - _ = yym3986 - 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 { - yym3987 := z.EncBinary() - _ = yym3987 - if false { - } else { - h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e) - } - } - } - if yyr3984 || yy2arr3984 { - 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 - yym3988 := z.DecBinary() - _ = yym3988 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3989 := r.ContainerType() - if yyct3989 == codecSelferValueTypeMap1234 { - yyl3989 := r.ReadMapStart() - if yyl3989 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3989, d) - } - } else if yyct3989 == codecSelferValueTypeArray1234 { - yyl3989 := r.ReadArrayStart() - if yyl3989 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3989, 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 yys3990Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3990Slc - var yyhl3990 bool = l >= 0 - for yyj3990 := 0; ; yyj3990++ { - if yyhl3990 { - if yyj3990 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3990Slc = r.DecodeBytes(yys3990Slc, true, true) - yys3990 := string(yys3990Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3990 { - case "limits": - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv3991 := &x.Limits - yym3992 := z.DecBinary() - _ = yym3992 - if false { - } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv3991), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3990) - } // end switch yys3990 - } // end for yyj3990 - 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 yyj3993 int - var yyb3993 bool - var yyhl3993 bool = l >= 0 - yyj3993++ - if yyhl3993 { - yyb3993 = yyj3993 > l - } else { - yyb3993 = r.CheckBreak() - } - if yyb3993 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv3994 := &x.Limits - yym3995 := z.DecBinary() - _ = yym3995 - if false { - } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv3994), d) - } - } - for { - yyj3993++ - if yyhl3993 { - yyb3993 = yyj3993 > l - } else { - yyb3993 = r.CheckBreak() - } - if yyb3993 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3993-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 { - yym3996 := z.EncBinary() - _ = yym3996 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3997 := !z.EncBinary() - yy2arr3997 := z.EncBasicHandle().StructToArray - var yyq3997 [4]bool - _, _, _ = yysep3997, yyq3997, yy2arr3997 - const yyr3997 bool = false - yyq3997[0] = x.Kind != "" - yyq3997[1] = x.APIVersion != "" - yyq3997[2] = true - yyq3997[3] = true - var yynn3997 int - if yyr3997 || yy2arr3997 { - r.EncodeArrayStart(4) - } else { - yynn3997 = 0 - for _, b := range yyq3997 { - if b { - yynn3997++ - } - } - r.EncodeMapStart(yynn3997) - yynn3997 = 0 - } - if yyr3997 || yy2arr3997 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3997[0] { - yym3999 := z.EncBinary() - _ = yym3999 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3997[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4000 := z.EncBinary() - _ = yym4000 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3997 || yy2arr3997 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3997[1] { - yym4002 := z.EncBinary() - _ = yym4002 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3997[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4003 := z.EncBinary() - _ = yym4003 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3997 || yy2arr3997 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3997[2] { - yy4005 := &x.ObjectMeta - yy4005.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3997[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4006 := &x.ObjectMeta - yy4006.CodecEncodeSelf(e) - } - } - if yyr3997 || yy2arr3997 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3997[3] { - yy4008 := &x.Spec - yy4008.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3997[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4009 := &x.Spec - yy4009.CodecEncodeSelf(e) - } - } - if yyr3997 || yy2arr3997 { - 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 - yym4010 := z.DecBinary() - _ = yym4010 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4011 := r.ContainerType() - if yyct4011 == codecSelferValueTypeMap1234 { - yyl4011 := r.ReadMapStart() - if yyl4011 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4011, d) - } - } else if yyct4011 == codecSelferValueTypeArray1234 { - yyl4011 := r.ReadArrayStart() - if yyl4011 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4011, 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 yys4012Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4012Slc - var yyhl4012 bool = l >= 0 - for yyj4012 := 0; ; yyj4012++ { - if yyhl4012 { - if yyj4012 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4012Slc = r.DecodeBytes(yys4012Slc, true, true) - yys4012 := string(yys4012Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4012 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4015 := &x.ObjectMeta - yyv4015.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = LimitRangeSpec{} - } else { - yyv4016 := &x.Spec - yyv4016.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4012) - } // end switch yys4012 - } // end for yyj4012 - 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 yyj4017 int - var yyb4017 bool - var yyhl4017 bool = l >= 0 - yyj4017++ - if yyhl4017 { - yyb4017 = yyj4017 > l - } else { - yyb4017 = r.CheckBreak() - } - if yyb4017 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4017++ - if yyhl4017 { - yyb4017 = yyj4017 > l - } else { - yyb4017 = r.CheckBreak() - } - if yyb4017 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4017++ - if yyhl4017 { - yyb4017 = yyj4017 > l - } else { - yyb4017 = r.CheckBreak() - } - if yyb4017 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4020 := &x.ObjectMeta - yyv4020.CodecDecodeSelf(d) - } - yyj4017++ - if yyhl4017 { - yyb4017 = yyj4017 > l - } else { - yyb4017 = r.CheckBreak() - } - if yyb4017 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = LimitRangeSpec{} - } else { - yyv4021 := &x.Spec - yyv4021.CodecDecodeSelf(d) - } - for { - yyj4017++ - if yyhl4017 { - yyb4017 = yyj4017 > l - } else { - yyb4017 = r.CheckBreak() - } - if yyb4017 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4017-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 { - yym4022 := z.EncBinary() - _ = yym4022 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4023 := !z.EncBinary() - yy2arr4023 := z.EncBasicHandle().StructToArray - var yyq4023 [4]bool - _, _, _ = yysep4023, yyq4023, yy2arr4023 - const yyr4023 bool = false - yyq4023[0] = x.Kind != "" - yyq4023[1] = x.APIVersion != "" - yyq4023[2] = true - var yynn4023 int - if yyr4023 || yy2arr4023 { - r.EncodeArrayStart(4) - } else { - yynn4023 = 1 - for _, b := range yyq4023 { - if b { - yynn4023++ - } - } - r.EncodeMapStart(yynn4023) - yynn4023 = 0 - } - if yyr4023 || yy2arr4023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4023[0] { - yym4025 := z.EncBinary() - _ = yym4025 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4023[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4026 := z.EncBinary() - _ = yym4026 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4023 || yy2arr4023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4023[1] { - yym4028 := z.EncBinary() - _ = yym4028 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4023[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4029 := z.EncBinary() - _ = yym4029 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4023 || yy2arr4023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4023[2] { - yy4031 := &x.ListMeta - yym4032 := z.EncBinary() - _ = yym4032 - if false { - } else if z.HasExtensions() && z.EncExt(yy4031) { - } else { - z.EncFallback(yy4031) - } - } else { - r.EncodeNil() - } - } else { - if yyq4023[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4033 := &x.ListMeta - yym4034 := z.EncBinary() - _ = yym4034 - if false { - } else if z.HasExtensions() && z.EncExt(yy4033) { - } else { - z.EncFallback(yy4033) - } - } - } - if yyr4023 || yy2arr4023 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4036 := z.EncBinary() - _ = yym4036 - 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 { - yym4037 := z.EncBinary() - _ = yym4037 - if false { - } else { - h.encSliceLimitRange(([]LimitRange)(x.Items), e) - } - } - } - if yyr4023 || yy2arr4023 { - 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 - yym4038 := z.DecBinary() - _ = yym4038 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4039 := r.ContainerType() - if yyct4039 == codecSelferValueTypeMap1234 { - yyl4039 := r.ReadMapStart() - if yyl4039 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4039, d) - } - } else if yyct4039 == codecSelferValueTypeArray1234 { - yyl4039 := r.ReadArrayStart() - if yyl4039 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4039, 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 yys4040Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4040Slc - var yyhl4040 bool = l >= 0 - for yyj4040 := 0; ; yyj4040++ { - if yyhl4040 { - if yyj4040 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4040Slc = r.DecodeBytes(yys4040Slc, true, true) - yys4040 := string(yys4040Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4040 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4043 := &x.ListMeta - yym4044 := z.DecBinary() - _ = yym4044 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4043) { - } else { - z.DecFallback(yyv4043, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4045 := &x.Items - yym4046 := z.DecBinary() - _ = yym4046 - if false { - } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4045), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4040) - } // end switch yys4040 - } // end for yyj4040 - 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 yyj4047 int - var yyb4047 bool - var yyhl4047 bool = l >= 0 - yyj4047++ - if yyhl4047 { - yyb4047 = yyj4047 > l - } else { - yyb4047 = r.CheckBreak() - } - if yyb4047 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4047++ - if yyhl4047 { - yyb4047 = yyj4047 > l - } else { - yyb4047 = r.CheckBreak() - } - if yyb4047 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4047++ - if yyhl4047 { - yyb4047 = yyj4047 > l - } else { - yyb4047 = r.CheckBreak() - } - if yyb4047 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4050 := &x.ListMeta - yym4051 := z.DecBinary() - _ = yym4051 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4050) { - } else { - z.DecFallback(yyv4050, false) - } - } - yyj4047++ - if yyhl4047 { - yyb4047 = yyj4047 > l - } else { - yyb4047 = r.CheckBreak() - } - if yyb4047 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4052 := &x.Items - yym4053 := z.DecBinary() - _ = yym4053 - if false { - } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4052), d) - } - } - for { - yyj4047++ - if yyhl4047 { - yyb4047 = yyj4047 > l - } else { - yyb4047 = r.CheckBreak() - } - if yyb4047 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4047-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4054 := z.EncBinary() - _ = yym4054 - 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 - yym4055 := z.DecBinary() - _ = yym4055 - 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 { - yym4056 := z.EncBinary() - _ = yym4056 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4057 := !z.EncBinary() - yy2arr4057 := z.EncBasicHandle().StructToArray - var yyq4057 [2]bool - _, _, _ = yysep4057, yyq4057, yy2arr4057 - const yyr4057 bool = false - yyq4057[0] = len(x.Hard) != 0 - yyq4057[1] = len(x.Scopes) != 0 - var yynn4057 int - if yyr4057 || yy2arr4057 { - r.EncodeArrayStart(2) - } else { - yynn4057 = 0 - for _, b := range yyq4057 { - if b { - yynn4057++ - } - } - r.EncodeMapStart(yynn4057) - yynn4057 = 0 - } - if yyr4057 || yy2arr4057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4057[0] { - if x.Hard == nil { - r.EncodeNil() - } else { - x.Hard.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4057[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 yyr4057 || yy2arr4057 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4057[1] { - if x.Scopes == nil { - r.EncodeNil() - } else { - yym4060 := z.EncBinary() - _ = yym4060 - if false { - } else { - h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4057[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scopes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Scopes == nil { - r.EncodeNil() - } else { - yym4061 := z.EncBinary() - _ = yym4061 - if false { - } else { - h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) - } - } - } - } - if yyr4057 || yy2arr4057 { - 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 - yym4062 := z.DecBinary() - _ = yym4062 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4063 := r.ContainerType() - if yyct4063 == codecSelferValueTypeMap1234 { - yyl4063 := r.ReadMapStart() - if yyl4063 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4063, d) - } - } else if yyct4063 == codecSelferValueTypeArray1234 { - yyl4063 := r.ReadArrayStart() - if yyl4063 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4063, 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 yys4064Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4064Slc - var yyhl4064 bool = l >= 0 - for yyj4064 := 0; ; yyj4064++ { - if yyhl4064 { - if yyj4064 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4064Slc = r.DecodeBytes(yys4064Slc, true, true) - yys4064 := string(yys4064Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4064 { - case "hard": - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4065 := &x.Hard - yyv4065.CodecDecodeSelf(d) - } - case "scopes": - if r.TryDecodeAsNil() { - x.Scopes = nil - } else { - yyv4066 := &x.Scopes - yym4067 := z.DecBinary() - _ = yym4067 - if false { - } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4066), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4064) - } // end switch yys4064 - } // end for yyj4064 - 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 yyj4068 int - var yyb4068 bool - var yyhl4068 bool = l >= 0 - yyj4068++ - if yyhl4068 { - yyb4068 = yyj4068 > l - } else { - yyb4068 = r.CheckBreak() - } - if yyb4068 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4069 := &x.Hard - yyv4069.CodecDecodeSelf(d) - } - yyj4068++ - if yyhl4068 { - yyb4068 = yyj4068 > l - } else { - yyb4068 = r.CheckBreak() - } - if yyb4068 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Scopes = nil - } else { - yyv4070 := &x.Scopes - yym4071 := z.DecBinary() - _ = yym4071 - if false { - } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4070), d) - } - } - for { - yyj4068++ - if yyhl4068 { - yyb4068 = yyj4068 > l - } else { - yyb4068 = r.CheckBreak() - } - if yyb4068 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4068-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 { - yym4072 := z.EncBinary() - _ = yym4072 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4073 := !z.EncBinary() - yy2arr4073 := z.EncBasicHandle().StructToArray - var yyq4073 [2]bool - _, _, _ = yysep4073, yyq4073, yy2arr4073 - const yyr4073 bool = false - yyq4073[0] = len(x.Hard) != 0 - yyq4073[1] = len(x.Used) != 0 - var yynn4073 int - if yyr4073 || yy2arr4073 { - r.EncodeArrayStart(2) - } else { - yynn4073 = 0 - for _, b := range yyq4073 { - if b { - yynn4073++ - } - } - r.EncodeMapStart(yynn4073) - yynn4073 = 0 - } - if yyr4073 || yy2arr4073 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4073[0] { - if x.Hard == nil { - r.EncodeNil() - } else { - x.Hard.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4073[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 yyr4073 || yy2arr4073 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4073[1] { - if x.Used == nil { - r.EncodeNil() - } else { - x.Used.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4073[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 yyr4073 || yy2arr4073 { - 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 - yym4076 := z.DecBinary() - _ = yym4076 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4077 := r.ContainerType() - if yyct4077 == codecSelferValueTypeMap1234 { - yyl4077 := r.ReadMapStart() - if yyl4077 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4077, d) - } - } else if yyct4077 == codecSelferValueTypeArray1234 { - yyl4077 := r.ReadArrayStart() - if yyl4077 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4077, 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 yys4078Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4078Slc - var yyhl4078 bool = l >= 0 - for yyj4078 := 0; ; yyj4078++ { - if yyhl4078 { - if yyj4078 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4078Slc = r.DecodeBytes(yys4078Slc, true, true) - yys4078 := string(yys4078Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4078 { - case "hard": - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4079 := &x.Hard - yyv4079.CodecDecodeSelf(d) - } - case "used": - if r.TryDecodeAsNil() { - x.Used = nil - } else { - yyv4080 := &x.Used - yyv4080.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4078) - } // end switch yys4078 - } // end for yyj4078 - 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 yyj4081 int - var yyb4081 bool - var yyhl4081 bool = l >= 0 - yyj4081++ - if yyhl4081 { - yyb4081 = yyj4081 > l - } else { - yyb4081 = r.CheckBreak() - } - if yyb4081 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4082 := &x.Hard - yyv4082.CodecDecodeSelf(d) - } - yyj4081++ - if yyhl4081 { - yyb4081 = yyj4081 > l - } else { - yyb4081 = r.CheckBreak() - } - if yyb4081 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Used = nil - } else { - yyv4083 := &x.Used - yyv4083.CodecDecodeSelf(d) - } - for { - yyj4081++ - if yyhl4081 { - yyb4081 = yyj4081 > l - } else { - yyb4081 = r.CheckBreak() - } - if yyb4081 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4081-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 { - yym4084 := z.EncBinary() - _ = yym4084 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4085 := !z.EncBinary() - yy2arr4085 := z.EncBasicHandle().StructToArray - var yyq4085 [5]bool - _, _, _ = yysep4085, yyq4085, yy2arr4085 - const yyr4085 bool = false - yyq4085[0] = x.Kind != "" - yyq4085[1] = x.APIVersion != "" - yyq4085[2] = true - yyq4085[3] = true - yyq4085[4] = true - var yynn4085 int - if yyr4085 || yy2arr4085 { - r.EncodeArrayStart(5) - } else { - yynn4085 = 0 - for _, b := range yyq4085 { - if b { - yynn4085++ - } - } - r.EncodeMapStart(yynn4085) - yynn4085 = 0 - } - if yyr4085 || yy2arr4085 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4085[0] { - yym4087 := z.EncBinary() - _ = yym4087 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4085[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4088 := z.EncBinary() - _ = yym4088 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4085 || yy2arr4085 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4085[1] { - yym4090 := z.EncBinary() - _ = yym4090 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4085[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4091 := z.EncBinary() - _ = yym4091 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4085 || yy2arr4085 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4085[2] { - yy4093 := &x.ObjectMeta - yy4093.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4085[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4094 := &x.ObjectMeta - yy4094.CodecEncodeSelf(e) - } - } - if yyr4085 || yy2arr4085 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4085[3] { - yy4096 := &x.Spec - yy4096.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4085[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4097 := &x.Spec - yy4097.CodecEncodeSelf(e) - } - } - if yyr4085 || yy2arr4085 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4085[4] { - yy4099 := &x.Status - yy4099.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4085[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4100 := &x.Status - yy4100.CodecEncodeSelf(e) - } - } - if yyr4085 || yy2arr4085 { - 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 - yym4101 := z.DecBinary() - _ = yym4101 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4102 := r.ContainerType() - if yyct4102 == codecSelferValueTypeMap1234 { - yyl4102 := r.ReadMapStart() - if yyl4102 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4102, d) - } - } else if yyct4102 == codecSelferValueTypeArray1234 { - yyl4102 := r.ReadArrayStart() - if yyl4102 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4102, 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 yys4103Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4103Slc - var yyhl4103 bool = l >= 0 - for yyj4103 := 0; ; yyj4103++ { - if yyhl4103 { - if yyj4103 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4103Slc = r.DecodeBytes(yys4103Slc, true, true) - yys4103 := string(yys4103Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4103 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4106 := &x.ObjectMeta - yyv4106.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ResourceQuotaSpec{} - } else { - yyv4107 := &x.Spec - yyv4107.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ResourceQuotaStatus{} - } else { - yyv4108 := &x.Status - yyv4108.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4103) - } // end switch yys4103 - } // end for yyj4103 - 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 yyj4109 int - var yyb4109 bool - var yyhl4109 bool = l >= 0 - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4112 := &x.ObjectMeta - yyv4112.CodecDecodeSelf(d) - } - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ResourceQuotaSpec{} - } else { - yyv4113 := &x.Spec - yyv4113.CodecDecodeSelf(d) - } - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ResourceQuotaStatus{} - } else { - yyv4114 := &x.Status - yyv4114.CodecDecodeSelf(d) - } - for { - yyj4109++ - if yyhl4109 { - yyb4109 = yyj4109 > l - } else { - yyb4109 = r.CheckBreak() - } - if yyb4109 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4109-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 { - yym4115 := z.EncBinary() - _ = yym4115 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4116 := !z.EncBinary() - yy2arr4116 := z.EncBasicHandle().StructToArray - var yyq4116 [4]bool - _, _, _ = yysep4116, yyq4116, yy2arr4116 - const yyr4116 bool = false - yyq4116[0] = x.Kind != "" - yyq4116[1] = x.APIVersion != "" - yyq4116[2] = true - var yynn4116 int - if yyr4116 || yy2arr4116 { - r.EncodeArrayStart(4) - } else { - yynn4116 = 1 - for _, b := range yyq4116 { - if b { - yynn4116++ - } - } - r.EncodeMapStart(yynn4116) - yynn4116 = 0 - } - if yyr4116 || yy2arr4116 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4116[0] { - yym4118 := z.EncBinary() - _ = yym4118 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4116[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4119 := z.EncBinary() - _ = yym4119 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4116 || yy2arr4116 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4116[1] { - yym4121 := z.EncBinary() - _ = yym4121 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4116[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4122 := z.EncBinary() - _ = yym4122 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4116 || yy2arr4116 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4116[2] { - yy4124 := &x.ListMeta - yym4125 := z.EncBinary() - _ = yym4125 - if false { - } else if z.HasExtensions() && z.EncExt(yy4124) { - } else { - z.EncFallback(yy4124) - } - } else { - r.EncodeNil() - } - } else { - if yyq4116[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4126 := &x.ListMeta - yym4127 := z.EncBinary() - _ = yym4127 - if false { - } else if z.HasExtensions() && z.EncExt(yy4126) { - } else { - z.EncFallback(yy4126) - } - } - } - if yyr4116 || yy2arr4116 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4129 := z.EncBinary() - _ = yym4129 - 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 { - yym4130 := z.EncBinary() - _ = yym4130 - if false { - } else { - h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e) - } - } - } - if yyr4116 || yy2arr4116 { - 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 - yym4131 := z.DecBinary() - _ = yym4131 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4132 := r.ContainerType() - if yyct4132 == codecSelferValueTypeMap1234 { - yyl4132 := r.ReadMapStart() - if yyl4132 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4132, d) - } - } else if yyct4132 == codecSelferValueTypeArray1234 { - yyl4132 := r.ReadArrayStart() - if yyl4132 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4132, 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 yys4133Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4133Slc - var yyhl4133 bool = l >= 0 - for yyj4133 := 0; ; yyj4133++ { - if yyhl4133 { - if yyj4133 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4133Slc = r.DecodeBytes(yys4133Slc, true, true) - yys4133 := string(yys4133Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4133 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4136 := &x.ListMeta - yym4137 := z.DecBinary() - _ = yym4137 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4136) { - } else { - z.DecFallback(yyv4136, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4138 := &x.Items - yym4139 := z.DecBinary() - _ = yym4139 - if false { - } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4138), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4133) - } // end switch yys4133 - } // end for yyj4133 - 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 yyj4140 int - var yyb4140 bool - var yyhl4140 bool = l >= 0 - yyj4140++ - if yyhl4140 { - yyb4140 = yyj4140 > l - } else { - yyb4140 = r.CheckBreak() - } - if yyb4140 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4140++ - if yyhl4140 { - yyb4140 = yyj4140 > l - } else { - yyb4140 = r.CheckBreak() - } - if yyb4140 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4140++ - if yyhl4140 { - yyb4140 = yyj4140 > l - } else { - yyb4140 = r.CheckBreak() - } - if yyb4140 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4143 := &x.ListMeta - yym4144 := z.DecBinary() - _ = yym4144 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4143) { - } else { - z.DecFallback(yyv4143, false) - } - } - yyj4140++ - if yyhl4140 { - yyb4140 = yyj4140 > l - } else { - yyb4140 = r.CheckBreak() - } - if yyb4140 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4145 := &x.Items - yym4146 := z.DecBinary() - _ = yym4146 - if false { - } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4145), d) - } - } - for { - yyj4140++ - if yyhl4140 { - yyb4140 = yyj4140 > l - } else { - yyb4140 = r.CheckBreak() - } - if yyb4140 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4140-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 { - yym4147 := z.EncBinary() - _ = yym4147 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4148 := !z.EncBinary() - yy2arr4148 := z.EncBasicHandle().StructToArray - var yyq4148 [6]bool - _, _, _ = yysep4148, yyq4148, yy2arr4148 - const yyr4148 bool = false - yyq4148[0] = x.Kind != "" - yyq4148[1] = x.APIVersion != "" - yyq4148[2] = true - yyq4148[3] = len(x.Data) != 0 - yyq4148[4] = len(x.StringData) != 0 - yyq4148[5] = x.Type != "" - var yynn4148 int - if yyr4148 || yy2arr4148 { - r.EncodeArrayStart(6) - } else { - yynn4148 = 0 - for _, b := range yyq4148 { - if b { - yynn4148++ - } - } - r.EncodeMapStart(yynn4148) - yynn4148 = 0 - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[0] { - yym4150 := z.EncBinary() - _ = yym4150 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4148[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4151 := z.EncBinary() - _ = yym4151 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[1] { - yym4153 := z.EncBinary() - _ = yym4153 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4148[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4154 := z.EncBinary() - _ = yym4154 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[2] { - yy4156 := &x.ObjectMeta - yy4156.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4148[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4157 := &x.ObjectMeta - yy4157.CodecEncodeSelf(e) - } - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[3] { - if x.Data == nil { - r.EncodeNil() - } else { - yym4159 := z.EncBinary() - _ = yym4159 - if false { - } else { - h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4148[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4160 := z.EncBinary() - _ = yym4160 - if false { - } else { - h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) - } - } - } - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[4] { - if x.StringData == nil { - r.EncodeNil() - } else { - yym4162 := z.EncBinary() - _ = yym4162 - if false { - } else { - z.F.EncMapStringStringV(x.StringData, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4148[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stringData")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StringData == nil { - r.EncodeNil() - } else { - yym4163 := z.EncBinary() - _ = yym4163 - if false { - } else { - z.F.EncMapStringStringV(x.StringData, false, e) - } - } - } - } - if yyr4148 || yy2arr4148 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4148[5] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4148[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr4148 || yy2arr4148 { - 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 - yym4165 := z.DecBinary() - _ = yym4165 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4166 := r.ContainerType() - if yyct4166 == codecSelferValueTypeMap1234 { - yyl4166 := r.ReadMapStart() - if yyl4166 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4166, d) - } - } else if yyct4166 == codecSelferValueTypeArray1234 { - yyl4166 := r.ReadArrayStart() - if yyl4166 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4166, 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 yys4167Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4167Slc - var yyhl4167 bool = l >= 0 - for yyj4167 := 0; ; yyj4167++ { - if yyhl4167 { - if yyj4167 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4167Slc = r.DecodeBytes(yys4167Slc, true, true) - yys4167 := string(yys4167Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4167 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4170 := &x.ObjectMeta - yyv4170.CodecDecodeSelf(d) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4171 := &x.Data - yym4172 := z.DecBinary() - _ = yym4172 - if false { - } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4171), d) - } - } - case "stringData": - if r.TryDecodeAsNil() { - x.StringData = nil - } else { - yyv4173 := &x.StringData - yym4174 := z.DecBinary() - _ = yym4174 - if false { - } else { - z.F.DecMapStringStringX(yyv4173, false, d) - } - } - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = SecretType(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys4167) - } // end switch yys4167 - } // end for yyj4167 - 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 yyj4176 int - var yyb4176 bool - var yyhl4176 bool = l >= 0 - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4179 := &x.ObjectMeta - yyv4179.CodecDecodeSelf(d) - } - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4180 := &x.Data - yym4181 := z.DecBinary() - _ = yym4181 - if false { - } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4180), d) - } - } - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StringData = nil - } else { - yyv4182 := &x.StringData - yym4183 := z.DecBinary() - _ = yym4183 - if false { - } else { - z.F.DecMapStringStringX(yyv4182, false, d) - } - } - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = SecretType(r.DecodeString()) - } - for { - yyj4176++ - if yyhl4176 { - yyb4176 = yyj4176 > l - } else { - yyb4176 = r.CheckBreak() - } - if yyb4176 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4176-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x SecretType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4185 := z.EncBinary() - _ = yym4185 - 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 - yym4186 := z.DecBinary() - _ = yym4186 - 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 { - yym4187 := z.EncBinary() - _ = yym4187 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4188 := !z.EncBinary() - yy2arr4188 := z.EncBasicHandle().StructToArray - var yyq4188 [4]bool - _, _, _ = yysep4188, yyq4188, yy2arr4188 - const yyr4188 bool = false - yyq4188[0] = x.Kind != "" - yyq4188[1] = x.APIVersion != "" - yyq4188[2] = true - var yynn4188 int - if yyr4188 || yy2arr4188 { - r.EncodeArrayStart(4) - } else { - yynn4188 = 1 - for _, b := range yyq4188 { - if b { - yynn4188++ - } - } - r.EncodeMapStart(yynn4188) - yynn4188 = 0 - } - if yyr4188 || yy2arr4188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4188[0] { - yym4190 := z.EncBinary() - _ = yym4190 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4188[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4191 := z.EncBinary() - _ = yym4191 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4188 || yy2arr4188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4188[1] { - yym4193 := z.EncBinary() - _ = yym4193 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4188[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4194 := z.EncBinary() - _ = yym4194 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4188 || yy2arr4188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4188[2] { - yy4196 := &x.ListMeta - yym4197 := z.EncBinary() - _ = yym4197 - if false { - } else if z.HasExtensions() && z.EncExt(yy4196) { - } else { - z.EncFallback(yy4196) - } - } else { - r.EncodeNil() - } - } else { - if yyq4188[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4198 := &x.ListMeta - yym4199 := z.EncBinary() - _ = yym4199 - if false { - } else if z.HasExtensions() && z.EncExt(yy4198) { - } else { - z.EncFallback(yy4198) - } - } - } - if yyr4188 || yy2arr4188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4201 := z.EncBinary() - _ = yym4201 - 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 { - yym4202 := z.EncBinary() - _ = yym4202 - if false { - } else { - h.encSliceSecret(([]Secret)(x.Items), e) - } - } - } - if yyr4188 || yy2arr4188 { - 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 - yym4203 := z.DecBinary() - _ = yym4203 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4204 := r.ContainerType() - if yyct4204 == codecSelferValueTypeMap1234 { - yyl4204 := r.ReadMapStart() - if yyl4204 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4204, d) - } - } else if yyct4204 == codecSelferValueTypeArray1234 { - yyl4204 := r.ReadArrayStart() - if yyl4204 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4204, 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 yys4205Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4205Slc - var yyhl4205 bool = l >= 0 - for yyj4205 := 0; ; yyj4205++ { - if yyhl4205 { - if yyj4205 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4205Slc = r.DecodeBytes(yys4205Slc, true, true) - yys4205 := string(yys4205Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4205 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4208 := &x.ListMeta - yym4209 := z.DecBinary() - _ = yym4209 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4208) { - } else { - z.DecFallback(yyv4208, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4210 := &x.Items - yym4211 := z.DecBinary() - _ = yym4211 - if false { - } else { - h.decSliceSecret((*[]Secret)(yyv4210), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4205) - } // end switch yys4205 - } // end for yyj4205 - 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 yyj4212 int - var yyb4212 bool - var yyhl4212 bool = l >= 0 - yyj4212++ - if yyhl4212 { - yyb4212 = yyj4212 > l - } else { - yyb4212 = r.CheckBreak() - } - if yyb4212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4212++ - if yyhl4212 { - yyb4212 = yyj4212 > l - } else { - yyb4212 = r.CheckBreak() - } - if yyb4212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4212++ - if yyhl4212 { - yyb4212 = yyj4212 > l - } else { - yyb4212 = r.CheckBreak() - } - if yyb4212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4215 := &x.ListMeta - yym4216 := z.DecBinary() - _ = yym4216 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4215) { - } else { - z.DecFallback(yyv4215, false) - } - } - yyj4212++ - if yyhl4212 { - yyb4212 = yyj4212 > l - } else { - yyb4212 = r.CheckBreak() - } - if yyb4212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4217 := &x.Items - yym4218 := z.DecBinary() - _ = yym4218 - if false { - } else { - h.decSliceSecret((*[]Secret)(yyv4217), d) - } - } - for { - yyj4212++ - if yyhl4212 { - yyb4212 = yyj4212 > l - } else { - yyb4212 = r.CheckBreak() - } - if yyb4212 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4212-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 { - yym4219 := z.EncBinary() - _ = yym4219 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4220 := !z.EncBinary() - yy2arr4220 := z.EncBasicHandle().StructToArray - var yyq4220 [4]bool - _, _, _ = yysep4220, yyq4220, yy2arr4220 - const yyr4220 bool = false - yyq4220[0] = x.Kind != "" - yyq4220[1] = x.APIVersion != "" - yyq4220[2] = true - yyq4220[3] = len(x.Data) != 0 - var yynn4220 int - if yyr4220 || yy2arr4220 { - r.EncodeArrayStart(4) - } else { - yynn4220 = 0 - for _, b := range yyq4220 { - if b { - yynn4220++ - } - } - r.EncodeMapStart(yynn4220) - yynn4220 = 0 - } - if yyr4220 || yy2arr4220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4220[0] { - yym4222 := z.EncBinary() - _ = yym4222 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4220[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4223 := z.EncBinary() - _ = yym4223 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4220 || yy2arr4220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4220[1] { - yym4225 := z.EncBinary() - _ = yym4225 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4220[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4226 := z.EncBinary() - _ = yym4226 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4220 || yy2arr4220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4220[2] { - yy4228 := &x.ObjectMeta - yy4228.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4220[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4229 := &x.ObjectMeta - yy4229.CodecEncodeSelf(e) - } - } - if yyr4220 || yy2arr4220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4220[3] { - if x.Data == nil { - r.EncodeNil() - } else { - yym4231 := z.EncBinary() - _ = yym4231 - if false { - } else { - z.F.EncMapStringStringV(x.Data, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4220[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4232 := z.EncBinary() - _ = yym4232 - if false { - } else { - z.F.EncMapStringStringV(x.Data, false, e) - } - } - } - } - if yyr4220 || yy2arr4220 { - 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 - yym4233 := z.DecBinary() - _ = yym4233 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4234 := r.ContainerType() - if yyct4234 == codecSelferValueTypeMap1234 { - yyl4234 := r.ReadMapStart() - if yyl4234 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4234, d) - } - } else if yyct4234 == codecSelferValueTypeArray1234 { - yyl4234 := r.ReadArrayStart() - if yyl4234 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4234, 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 yys4235Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4235Slc - var yyhl4235 bool = l >= 0 - for yyj4235 := 0; ; yyj4235++ { - if yyhl4235 { - if yyj4235 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4235Slc = r.DecodeBytes(yys4235Slc, true, true) - yys4235 := string(yys4235Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4235 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4238 := &x.ObjectMeta - yyv4238.CodecDecodeSelf(d) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4239 := &x.Data - yym4240 := z.DecBinary() - _ = yym4240 - if false { - } else { - z.F.DecMapStringStringX(yyv4239, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4235) - } // end switch yys4235 - } // end for yyj4235 - 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 yyj4241 int - var yyb4241 bool - var yyhl4241 bool = l >= 0 - yyj4241++ - if yyhl4241 { - yyb4241 = yyj4241 > l - } else { - yyb4241 = r.CheckBreak() - } - if yyb4241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4241++ - if yyhl4241 { - yyb4241 = yyj4241 > l - } else { - yyb4241 = r.CheckBreak() - } - if yyb4241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4241++ - if yyhl4241 { - yyb4241 = yyj4241 > l - } else { - yyb4241 = r.CheckBreak() - } - if yyb4241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4244 := &x.ObjectMeta - yyv4244.CodecDecodeSelf(d) - } - yyj4241++ - if yyhl4241 { - yyb4241 = yyj4241 > l - } else { - yyb4241 = r.CheckBreak() - } - if yyb4241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4245 := &x.Data - yym4246 := z.DecBinary() - _ = yym4246 - if false { - } else { - z.F.DecMapStringStringX(yyv4245, false, d) - } - } - for { - yyj4241++ - if yyhl4241 { - yyb4241 = yyj4241 > l - } else { - yyb4241 = r.CheckBreak() - } - if yyb4241 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4241-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 { - yym4247 := z.EncBinary() - _ = yym4247 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4248 := !z.EncBinary() - yy2arr4248 := z.EncBasicHandle().StructToArray - var yyq4248 [4]bool - _, _, _ = yysep4248, yyq4248, yy2arr4248 - const yyr4248 bool = false - yyq4248[0] = x.Kind != "" - yyq4248[1] = x.APIVersion != "" - yyq4248[2] = true - var yynn4248 int - if yyr4248 || yy2arr4248 { - r.EncodeArrayStart(4) - } else { - yynn4248 = 1 - for _, b := range yyq4248 { - if b { - yynn4248++ - } - } - r.EncodeMapStart(yynn4248) - yynn4248 = 0 - } - if yyr4248 || yy2arr4248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4248[0] { - yym4250 := z.EncBinary() - _ = yym4250 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4248[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4251 := z.EncBinary() - _ = yym4251 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4248 || yy2arr4248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4248[1] { - yym4253 := z.EncBinary() - _ = yym4253 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4248[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4254 := z.EncBinary() - _ = yym4254 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4248 || yy2arr4248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4248[2] { - yy4256 := &x.ListMeta - yym4257 := z.EncBinary() - _ = yym4257 - if false { - } else if z.HasExtensions() && z.EncExt(yy4256) { - } else { - z.EncFallback(yy4256) - } - } else { - r.EncodeNil() - } - } else { - if yyq4248[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4258 := &x.ListMeta - yym4259 := z.EncBinary() - _ = yym4259 - if false { - } else if z.HasExtensions() && z.EncExt(yy4258) { - } else { - z.EncFallback(yy4258) - } - } - } - if yyr4248 || yy2arr4248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4261 := z.EncBinary() - _ = yym4261 - 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 { - yym4262 := z.EncBinary() - _ = yym4262 - if false { - } else { - h.encSliceConfigMap(([]ConfigMap)(x.Items), e) - } - } - } - if yyr4248 || yy2arr4248 { - 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 - yym4263 := z.DecBinary() - _ = yym4263 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4264 := r.ContainerType() - if yyct4264 == codecSelferValueTypeMap1234 { - yyl4264 := r.ReadMapStart() - if yyl4264 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4264, d) - } - } else if yyct4264 == codecSelferValueTypeArray1234 { - yyl4264 := r.ReadArrayStart() - if yyl4264 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4264, 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 yys4265Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4265Slc - var yyhl4265 bool = l >= 0 - for yyj4265 := 0; ; yyj4265++ { - if yyhl4265 { - if yyj4265 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4265Slc = r.DecodeBytes(yys4265Slc, true, true) - yys4265 := string(yys4265Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4265 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4268 := &x.ListMeta - yym4269 := z.DecBinary() - _ = yym4269 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4268) { - } else { - z.DecFallback(yyv4268, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4270 := &x.Items - yym4271 := z.DecBinary() - _ = yym4271 - if false { - } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4270), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4265) - } // end switch yys4265 - } // end for yyj4265 - 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 yyj4272 int - var yyb4272 bool - var yyhl4272 bool = l >= 0 - yyj4272++ - if yyhl4272 { - yyb4272 = yyj4272 > l - } else { - yyb4272 = r.CheckBreak() - } - if yyb4272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4272++ - if yyhl4272 { - yyb4272 = yyj4272 > l - } else { - yyb4272 = r.CheckBreak() - } - if yyb4272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4272++ - if yyhl4272 { - yyb4272 = yyj4272 > l - } else { - yyb4272 = r.CheckBreak() - } - if yyb4272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4275 := &x.ListMeta - yym4276 := z.DecBinary() - _ = yym4276 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4275) { - } else { - z.DecFallback(yyv4275, false) - } - } - yyj4272++ - if yyhl4272 { - yyb4272 = yyj4272 > l - } else { - yyb4272 = r.CheckBreak() - } - if yyb4272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4277 := &x.Items - yym4278 := z.DecBinary() - _ = yym4278 - if false { - } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4277), d) - } - } - for { - yyj4272++ - if yyhl4272 { - yyb4272 = yyj4272 > l - } else { - yyb4272 = r.CheckBreak() - } - if yyb4272 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4272-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ComponentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4279 := z.EncBinary() - _ = yym4279 - 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 - yym4280 := z.DecBinary() - _ = yym4280 - 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 { - yym4281 := z.EncBinary() - _ = yym4281 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4282 := !z.EncBinary() - yy2arr4282 := z.EncBasicHandle().StructToArray - var yyq4282 [4]bool - _, _, _ = yysep4282, yyq4282, yy2arr4282 - const yyr4282 bool = false - yyq4282[2] = x.Message != "" - yyq4282[3] = x.Error != "" - var yynn4282 int - if yyr4282 || yy2arr4282 { - r.EncodeArrayStart(4) - } else { - yynn4282 = 2 - for _, b := range yyq4282 { - if b { - yynn4282++ - } - } - r.EncodeMapStart(yynn4282) - yynn4282 = 0 - } - if yyr4282 || yy2arr4282 { - 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 yyr4282 || yy2arr4282 { - 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 yyr4282 || yy2arr4282 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4282[2] { - yym4286 := z.EncBinary() - _ = yym4286 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4282[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4287 := z.EncBinary() - _ = yym4287 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr4282 || yy2arr4282 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4282[3] { - yym4289 := z.EncBinary() - _ = yym4289 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4282[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("error")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4290 := z.EncBinary() - _ = yym4290 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } - } - if yyr4282 || yy2arr4282 { - 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 - yym4291 := z.DecBinary() - _ = yym4291 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4292 := r.ContainerType() - if yyct4292 == codecSelferValueTypeMap1234 { - yyl4292 := r.ReadMapStart() - if yyl4292 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4292, d) - } - } else if yyct4292 == codecSelferValueTypeArray1234 { - yyl4292 := r.ReadArrayStart() - if yyl4292 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4292, 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 yys4293Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4293Slc - var yyhl4293 bool = l >= 0 - for yyj4293 := 0; ; yyj4293++ { - if yyhl4293 { - if yyj4293 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4293Slc = r.DecodeBytes(yys4293Slc, true, true) - yys4293 := string(yys4293Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4293 { - 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, yys4293) - } // end switch yys4293 - } // end for yyj4293 - 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 yyj4298 int - var yyb4298 bool - var yyhl4298 bool = l >= 0 - yyj4298++ - if yyhl4298 { - yyb4298 = yyj4298 > l - } else { - yyb4298 = r.CheckBreak() - } - if yyb4298 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ComponentConditionType(r.DecodeString()) - } - yyj4298++ - if yyhl4298 { - yyb4298 = yyj4298 > l - } else { - yyb4298 = r.CheckBreak() - } - if yyb4298 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj4298++ - if yyhl4298 { - yyb4298 = yyj4298 > l - } else { - yyb4298 = r.CheckBreak() - } - if yyb4298 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj4298++ - if yyhl4298 { - yyb4298 = yyj4298 > l - } else { - yyb4298 = r.CheckBreak() - } - if yyb4298 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Error = "" - } else { - x.Error = string(r.DecodeString()) - } - for { - yyj4298++ - if yyhl4298 { - yyb4298 = yyj4298 > l - } else { - yyb4298 = r.CheckBreak() - } - if yyb4298 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4298-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 { - yym4303 := z.EncBinary() - _ = yym4303 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4304 := !z.EncBinary() - yy2arr4304 := z.EncBasicHandle().StructToArray - var yyq4304 [4]bool - _, _, _ = yysep4304, yyq4304, yy2arr4304 - const yyr4304 bool = false - yyq4304[0] = x.Kind != "" - yyq4304[1] = x.APIVersion != "" - yyq4304[2] = true - yyq4304[3] = len(x.Conditions) != 0 - var yynn4304 int - if yyr4304 || yy2arr4304 { - r.EncodeArrayStart(4) - } else { - yynn4304 = 0 - for _, b := range yyq4304 { - if b { - yynn4304++ - } - } - r.EncodeMapStart(yynn4304) - yynn4304 = 0 - } - if yyr4304 || yy2arr4304 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4304[0] { - yym4306 := z.EncBinary() - _ = yym4306 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4304[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4307 := z.EncBinary() - _ = yym4307 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4304 || yy2arr4304 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4304[1] { - yym4309 := z.EncBinary() - _ = yym4309 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4304[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4310 := z.EncBinary() - _ = yym4310 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4304 || yy2arr4304 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4304[2] { - yy4312 := &x.ObjectMeta - yy4312.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4304[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4313 := &x.ObjectMeta - yy4313.CodecEncodeSelf(e) - } - } - if yyr4304 || yy2arr4304 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4304[3] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym4315 := z.EncBinary() - _ = yym4315 - if false { - } else { - h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4304[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym4316 := z.EncBinary() - _ = yym4316 - if false { - } else { - h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) - } - } - } - } - if yyr4304 || yy2arr4304 { - 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 - yym4317 := z.DecBinary() - _ = yym4317 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4318 := r.ContainerType() - if yyct4318 == codecSelferValueTypeMap1234 { - yyl4318 := r.ReadMapStart() - if yyl4318 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4318, d) - } - } else if yyct4318 == codecSelferValueTypeArray1234 { - yyl4318 := r.ReadArrayStart() - if yyl4318 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4318, 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 yys4319Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4319Slc - var yyhl4319 bool = l >= 0 - for yyj4319 := 0; ; yyj4319++ { - if yyhl4319 { - if yyj4319 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4319Slc = r.DecodeBytes(yys4319Slc, true, true) - yys4319 := string(yys4319Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4319 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4322 := &x.ObjectMeta - yyv4322.CodecDecodeSelf(d) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv4323 := &x.Conditions - yym4324 := z.DecBinary() - _ = yym4324 - if false { - } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4323), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4319) - } // end switch yys4319 - } // end for yyj4319 - 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 yyj4325 int - var yyb4325 bool - var yyhl4325 bool = l >= 0 - yyj4325++ - if yyhl4325 { - yyb4325 = yyj4325 > l - } else { - yyb4325 = r.CheckBreak() - } - if yyb4325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4325++ - if yyhl4325 { - yyb4325 = yyj4325 > l - } else { - yyb4325 = r.CheckBreak() - } - if yyb4325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4325++ - if yyhl4325 { - yyb4325 = yyj4325 > l - } else { - yyb4325 = r.CheckBreak() - } - if yyb4325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4328 := &x.ObjectMeta - yyv4328.CodecDecodeSelf(d) - } - yyj4325++ - if yyhl4325 { - yyb4325 = yyj4325 > l - } else { - yyb4325 = r.CheckBreak() - } - if yyb4325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv4329 := &x.Conditions - yym4330 := z.DecBinary() - _ = yym4330 - if false { - } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4329), d) - } - } - for { - yyj4325++ - if yyhl4325 { - yyb4325 = yyj4325 > l - } else { - yyb4325 = r.CheckBreak() - } - if yyb4325 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4325-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 { - yym4331 := z.EncBinary() - _ = yym4331 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4332 := !z.EncBinary() - yy2arr4332 := z.EncBasicHandle().StructToArray - var yyq4332 [4]bool - _, _, _ = yysep4332, yyq4332, yy2arr4332 - const yyr4332 bool = false - yyq4332[0] = x.Kind != "" - yyq4332[1] = x.APIVersion != "" - yyq4332[2] = true - var yynn4332 int - if yyr4332 || yy2arr4332 { - r.EncodeArrayStart(4) - } else { - yynn4332 = 1 - for _, b := range yyq4332 { - if b { - yynn4332++ - } - } - r.EncodeMapStart(yynn4332) - yynn4332 = 0 - } - if yyr4332 || yy2arr4332 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4332[0] { - yym4334 := z.EncBinary() - _ = yym4334 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4332[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4335 := z.EncBinary() - _ = yym4335 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4332 || yy2arr4332 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4332[1] { - yym4337 := z.EncBinary() - _ = yym4337 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4332[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4338 := z.EncBinary() - _ = yym4338 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4332 || yy2arr4332 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4332[2] { - yy4340 := &x.ListMeta - yym4341 := z.EncBinary() - _ = yym4341 - if false { - } else if z.HasExtensions() && z.EncExt(yy4340) { - } else { - z.EncFallback(yy4340) - } - } else { - r.EncodeNil() - } - } else { - if yyq4332[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4342 := &x.ListMeta - yym4343 := z.EncBinary() - _ = yym4343 - if false { - } else if z.HasExtensions() && z.EncExt(yy4342) { - } else { - z.EncFallback(yy4342) - } - } - } - if yyr4332 || yy2arr4332 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4345 := z.EncBinary() - _ = yym4345 - 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 { - yym4346 := z.EncBinary() - _ = yym4346 - if false { - } else { - h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e) - } - } - } - if yyr4332 || yy2arr4332 { - 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 - yym4347 := z.DecBinary() - _ = yym4347 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4348 := r.ContainerType() - if yyct4348 == codecSelferValueTypeMap1234 { - yyl4348 := r.ReadMapStart() - if yyl4348 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4348, d) - } - } else if yyct4348 == codecSelferValueTypeArray1234 { - yyl4348 := r.ReadArrayStart() - if yyl4348 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4348, 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 yys4349Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4349Slc - var yyhl4349 bool = l >= 0 - for yyj4349 := 0; ; yyj4349++ { - if yyhl4349 { - if yyj4349 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4349Slc = r.DecodeBytes(yys4349Slc, true, true) - yys4349 := string(yys4349Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4349 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4352 := &x.ListMeta - yym4353 := z.DecBinary() - _ = yym4353 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4352) { - } else { - z.DecFallback(yyv4352, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4354 := &x.Items - yym4355 := z.DecBinary() - _ = yym4355 - if false { - } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4354), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4349) - } // end switch yys4349 - } // end for yyj4349 - 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 yyj4356 int - var yyb4356 bool - var yyhl4356 bool = l >= 0 - yyj4356++ - if yyhl4356 { - yyb4356 = yyj4356 > l - } else { - yyb4356 = r.CheckBreak() - } - if yyb4356 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4356++ - if yyhl4356 { - yyb4356 = yyj4356 > l - } else { - yyb4356 = r.CheckBreak() - } - if yyb4356 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4356++ - if yyhl4356 { - yyb4356 = yyj4356 > l - } else { - yyb4356 = r.CheckBreak() - } - if yyb4356 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4359 := &x.ListMeta - yym4360 := z.DecBinary() - _ = yym4360 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4359) { - } else { - z.DecFallback(yyv4359, false) - } - } - yyj4356++ - if yyhl4356 { - yyb4356 = yyj4356 > l - } else { - yyb4356 = r.CheckBreak() - } - if yyb4356 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4361 := &x.Items - yym4362 := z.DecBinary() - _ = yym4362 - if false { - } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4361), d) - } - } - for { - yyj4356++ - if yyhl4356 { - yyb4356 = yyj4356 > l - } else { - yyb4356 = r.CheckBreak() - } - if yyb4356 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4356-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 { - yym4363 := z.EncBinary() - _ = yym4363 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4364 := !z.EncBinary() - yy2arr4364 := z.EncBasicHandle().StructToArray - var yyq4364 [2]bool - _, _, _ = yysep4364, yyq4364, yy2arr4364 - const yyr4364 bool = false - yyq4364[0] = len(x.Items) != 0 - yyq4364[1] = x.DefaultMode != nil - var yynn4364 int - if yyr4364 || yy2arr4364 { - r.EncodeArrayStart(2) - } else { - yynn4364 = 0 - for _, b := range yyq4364 { - if b { - yynn4364++ - } - } - r.EncodeMapStart(yynn4364) - yynn4364 = 0 - } - if yyr4364 || yy2arr4364 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4364[0] { - if x.Items == nil { - r.EncodeNil() - } else { - yym4366 := z.EncBinary() - _ = yym4366 - if false { - } else { - h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4364[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4367 := z.EncBinary() - _ = yym4367 - if false { - } else { - h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) - } - } - } - } - if yyr4364 || yy2arr4364 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4364[1] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy4369 := *x.DefaultMode - yym4370 := z.EncBinary() - _ = yym4370 - if false { - } else { - r.EncodeInt(int64(yy4369)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4364[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy4371 := *x.DefaultMode - yym4372 := z.EncBinary() - _ = yym4372 - if false { - } else { - r.EncodeInt(int64(yy4371)) - } - } - } - } - if yyr4364 || yy2arr4364 { - 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 - yym4373 := z.DecBinary() - _ = yym4373 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4374 := r.ContainerType() - if yyct4374 == codecSelferValueTypeMap1234 { - yyl4374 := r.ReadMapStart() - if yyl4374 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4374, d) - } - } else if yyct4374 == codecSelferValueTypeArray1234 { - yyl4374 := r.ReadArrayStart() - if yyl4374 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4374, 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 yys4375Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4375Slc - var yyhl4375 bool = l >= 0 - for yyj4375 := 0; ; yyj4375++ { - if yyhl4375 { - if yyj4375 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4375Slc = r.DecodeBytes(yys4375Slc, true, true) - yys4375 := string(yys4375Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4375 { - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4376 := &x.Items - yym4377 := z.DecBinary() - _ = yym4377 - if false { - } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4376), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym4379 := z.DecBinary() - _ = yym4379 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys4375) - } // end switch yys4375 - } // end for yyj4375 - 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 yyj4380 int - var yyb4380 bool - var yyhl4380 bool = l >= 0 - yyj4380++ - if yyhl4380 { - yyb4380 = yyj4380 > l - } else { - yyb4380 = r.CheckBreak() - } - if yyb4380 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4381 := &x.Items - yym4382 := z.DecBinary() - _ = yym4382 - if false { - } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4381), d) - } - } - yyj4380++ - if yyhl4380 { - yyb4380 = yyj4380 > l - } else { - yyb4380 = r.CheckBreak() - } - if yyb4380 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym4384 := z.DecBinary() - _ = yym4384 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj4380++ - if yyhl4380 { - yyb4380 = yyj4380 > l - } else { - yyb4380 = r.CheckBreak() - } - if yyb4380 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4380-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 { - yym4385 := z.EncBinary() - _ = yym4385 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4386 := !z.EncBinary() - yy2arr4386 := z.EncBasicHandle().StructToArray - var yyq4386 [4]bool - _, _, _ = yysep4386, yyq4386, yy2arr4386 - const yyr4386 bool = false - yyq4386[1] = x.FieldRef != nil - yyq4386[2] = x.ResourceFieldRef != nil - yyq4386[3] = x.Mode != nil - var yynn4386 int - if yyr4386 || yy2arr4386 { - r.EncodeArrayStart(4) - } else { - yynn4386 = 1 - for _, b := range yyq4386 { - if b { - yynn4386++ - } - } - r.EncodeMapStart(yynn4386) - yynn4386 = 0 - } - if yyr4386 || yy2arr4386 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym4388 := z.EncBinary() - _ = yym4388 - 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) - yym4389 := z.EncBinary() - _ = yym4389 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr4386 || yy2arr4386 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4386[1] { - if x.FieldRef == nil { - r.EncodeNil() - } else { - x.FieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4386[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 yyr4386 || yy2arr4386 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4386[2] { - if x.ResourceFieldRef == nil { - r.EncodeNil() - } else { - x.ResourceFieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4386[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 yyr4386 || yy2arr4386 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4386[3] { - if x.Mode == nil { - r.EncodeNil() - } else { - yy4393 := *x.Mode - yym4394 := z.EncBinary() - _ = yym4394 - if false { - } else { - r.EncodeInt(int64(yy4393)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4386[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Mode == nil { - r.EncodeNil() - } else { - yy4395 := *x.Mode - yym4396 := z.EncBinary() - _ = yym4396 - if false { - } else { - r.EncodeInt(int64(yy4395)) - } - } - } - } - if yyr4386 || yy2arr4386 { - 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 - yym4397 := z.DecBinary() - _ = yym4397 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4398 := r.ContainerType() - if yyct4398 == codecSelferValueTypeMap1234 { - yyl4398 := r.ReadMapStart() - if yyl4398 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4398, d) - } - } else if yyct4398 == codecSelferValueTypeArray1234 { - yyl4398 := r.ReadArrayStart() - if yyl4398 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4398, 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 yys4399Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4399Slc - var yyhl4399 bool = l >= 0 - for yyj4399 := 0; ; yyj4399++ { - if yyhl4399 { - if yyj4399 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4399Slc = r.DecodeBytes(yys4399Slc, true, true) - yys4399 := string(yys4399Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4399 { - 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) - } - case "mode": - if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } - } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym4404 := z.DecBinary() - _ = yym4404 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys4399) - } // end switch yys4399 - } // end for yyj4399 - 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 yyj4405 int - var yyb4405 bool - var yyhl4405 bool = l >= 0 - yyj4405++ - if yyhl4405 { - yyb4405 = yyj4405 > l - } else { - yyb4405 = r.CheckBreak() - } - if yyb4405 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj4405++ - if yyhl4405 { - yyb4405 = yyj4405 > l - } else { - yyb4405 = r.CheckBreak() - } - if yyb4405 { - 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) - } - yyj4405++ - if yyhl4405 { - yyb4405 = yyj4405 > l - } else { - yyb4405 = r.CheckBreak() - } - if yyb4405 { - 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) - } - yyj4405++ - if yyhl4405 { - yyb4405 = yyj4405 > l - } else { - yyb4405 = r.CheckBreak() - } - if yyb4405 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } - } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym4410 := z.DecBinary() - _ = yym4410 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj4405++ - if yyhl4405 { - yyb4405 = yyj4405 > l - } else { - yyb4405 = r.CheckBreak() - } - if yyb4405 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4405-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 { - yym4411 := z.EncBinary() - _ = yym4411 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4412 := !z.EncBinary() - yy2arr4412 := z.EncBasicHandle().StructToArray - var yyq4412 [6]bool - _, _, _ = yysep4412, yyq4412, yy2arr4412 - const yyr4412 bool = false - yyq4412[0] = x.Capabilities != nil - yyq4412[1] = x.Privileged != nil - yyq4412[2] = x.SELinuxOptions != nil - yyq4412[3] = x.RunAsUser != nil - yyq4412[4] = x.RunAsNonRoot != nil - yyq4412[5] = x.ReadOnlyRootFilesystem != nil - var yynn4412 int - if yyr4412 || yy2arr4412 { - r.EncodeArrayStart(6) - } else { - yynn4412 = 0 - for _, b := range yyq4412 { - if b { - yynn4412++ - } - } - r.EncodeMapStart(yynn4412) - yynn4412 = 0 - } - if yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[0] { - if x.Capabilities == nil { - r.EncodeNil() - } else { - x.Capabilities.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[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 yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[1] { - if x.Privileged == nil { - r.EncodeNil() - } else { - yy4415 := *x.Privileged - yym4416 := z.EncBinary() - _ = yym4416 - if false { - } else { - r.EncodeBool(bool(yy4415)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("privileged")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Privileged == nil { - r.EncodeNil() - } else { - yy4417 := *x.Privileged - yym4418 := z.EncBinary() - _ = yym4418 - if false { - } else { - r.EncodeBool(bool(yy4417)) - } - } - } - } - if yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[2] { - if x.SELinuxOptions == nil { - r.EncodeNil() - } else { - x.SELinuxOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[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 yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[3] { - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy4421 := *x.RunAsUser - yym4422 := z.EncBinary() - _ = yym4422 - if false { - } else { - r.EncodeInt(int64(yy4421)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy4423 := *x.RunAsUser - yym4424 := z.EncBinary() - _ = yym4424 - if false { - } else { - r.EncodeInt(int64(yy4423)) - } - } - } - } - if yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[4] { - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy4426 := *x.RunAsNonRoot - yym4427 := z.EncBinary() - _ = yym4427 - if false { - } else { - r.EncodeBool(bool(yy4426)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy4428 := *x.RunAsNonRoot - yym4429 := z.EncBinary() - _ = yym4429 - if false { - } else { - r.EncodeBool(bool(yy4428)) - } - } - } - } - if yyr4412 || yy2arr4412 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4412[5] { - if x.ReadOnlyRootFilesystem == nil { - r.EncodeNil() - } else { - yy4431 := *x.ReadOnlyRootFilesystem - yym4432 := z.EncBinary() - _ = yym4432 - if false { - } else { - r.EncodeBool(bool(yy4431)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4412[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ReadOnlyRootFilesystem == nil { - r.EncodeNil() - } else { - yy4433 := *x.ReadOnlyRootFilesystem - yym4434 := z.EncBinary() - _ = yym4434 - if false { - } else { - r.EncodeBool(bool(yy4433)) - } - } - } - } - if yyr4412 || yy2arr4412 { - 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 - yym4435 := z.DecBinary() - _ = yym4435 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4436 := r.ContainerType() - if yyct4436 == codecSelferValueTypeMap1234 { - yyl4436 := r.ReadMapStart() - if yyl4436 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4436, d) - } - } else if yyct4436 == codecSelferValueTypeArray1234 { - yyl4436 := r.ReadArrayStart() - if yyl4436 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4436, 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 yys4437Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4437Slc - var yyhl4437 bool = l >= 0 - for yyj4437 := 0; ; yyj4437++ { - if yyhl4437 { - if yyj4437 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4437Slc = r.DecodeBytes(yys4437Slc, true, true) - yys4437 := string(yys4437Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4437 { - 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) - } - yym4440 := z.DecBinary() - _ = yym4440 - 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) - } - yym4443 := z.DecBinary() - _ = yym4443 - 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) - } - yym4445 := z.DecBinary() - _ = yym4445 - 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) - } - yym4447 := z.DecBinary() - _ = yym4447 - if false { - } else { - *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys4437) - } // end switch yys4437 - } // end for yyj4437 - 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 yyj4448 int - var yyb4448 bool - var yyhl4448 bool = l >= 0 - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yym4451 := z.DecBinary() - _ = yym4451 - if false { - } else { - *((*bool)(x.Privileged)) = r.DecodeBool() - } - } - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yym4454 := z.DecBinary() - _ = yym4454 - if false { - } else { - *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) - } - } - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yym4456 := z.DecBinary() - _ = yym4456 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - 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) - } - yym4458 := z.DecBinary() - _ = yym4458 - if false { - } else { - *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() - } - } - for { - yyj4448++ - if yyhl4448 { - yyb4448 = yyj4448 > l - } else { - yyb4448 = r.CheckBreak() - } - if yyb4448 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4448-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 { - yym4459 := z.EncBinary() - _ = yym4459 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4460 := !z.EncBinary() - yy2arr4460 := z.EncBasicHandle().StructToArray - var yyq4460 [4]bool - _, _, _ = yysep4460, yyq4460, yy2arr4460 - const yyr4460 bool = false - yyq4460[0] = x.User != "" - yyq4460[1] = x.Role != "" - yyq4460[2] = x.Type != "" - yyq4460[3] = x.Level != "" - var yynn4460 int - if yyr4460 || yy2arr4460 { - r.EncodeArrayStart(4) - } else { - yynn4460 = 0 - for _, b := range yyq4460 { - if b { - yynn4460++ - } - } - r.EncodeMapStart(yynn4460) - yynn4460 = 0 - } - if yyr4460 || yy2arr4460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4460[0] { - yym4462 := z.EncBinary() - _ = yym4462 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4460[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4463 := z.EncBinary() - _ = yym4463 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr4460 || yy2arr4460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4460[1] { - yym4465 := z.EncBinary() - _ = yym4465 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Role)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4460[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("role")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4466 := z.EncBinary() - _ = yym4466 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Role)) - } - } - } - if yyr4460 || yy2arr4460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4460[2] { - yym4468 := z.EncBinary() - _ = yym4468 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4460[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4469 := z.EncBinary() - _ = yym4469 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } - } - if yyr4460 || yy2arr4460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4460[3] { - yym4471 := z.EncBinary() - _ = yym4471 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Level)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4460[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("level")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4472 := z.EncBinary() - _ = yym4472 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Level)) - } - } - } - if yyr4460 || yy2arr4460 { - 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 - yym4473 := z.DecBinary() - _ = yym4473 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4474 := r.ContainerType() - if yyct4474 == codecSelferValueTypeMap1234 { - yyl4474 := r.ReadMapStart() - if yyl4474 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4474, d) - } - } else if yyct4474 == codecSelferValueTypeArray1234 { - yyl4474 := r.ReadArrayStart() - if yyl4474 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4474, 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 yys4475Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4475Slc - var yyhl4475 bool = l >= 0 - for yyj4475 := 0; ; yyj4475++ { - if yyhl4475 { - if yyj4475 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4475Slc = r.DecodeBytes(yys4475Slc, true, true) - yys4475 := string(yys4475Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4475 { - 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, yys4475) - } // end switch yys4475 - } // end for yyj4475 - 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 yyj4480 int - var yyb4480 bool - var yyhl4480 bool = l >= 0 - yyj4480++ - if yyhl4480 { - yyb4480 = yyj4480 > l - } else { - yyb4480 = r.CheckBreak() - } - if yyb4480 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj4480++ - if yyhl4480 { - yyb4480 = yyj4480 > l - } else { - yyb4480 = r.CheckBreak() - } - if yyb4480 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Role = "" - } else { - x.Role = string(r.DecodeString()) - } - yyj4480++ - if yyhl4480 { - yyb4480 = yyj4480 > l - } else { - yyb4480 = r.CheckBreak() - } - if yyb4480 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = string(r.DecodeString()) - } - yyj4480++ - if yyhl4480 { - yyb4480 = yyj4480 > l - } else { - yyb4480 = r.CheckBreak() - } - if yyb4480 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Level = "" - } else { - x.Level = string(r.DecodeString()) - } - for { - yyj4480++ - if yyhl4480 { - yyb4480 = yyj4480 > l - } else { - yyb4480 = r.CheckBreak() - } - if yyb4480 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4480-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 { - yym4485 := z.EncBinary() - _ = yym4485 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4486 := !z.EncBinary() - yy2arr4486 := z.EncBasicHandle().StructToArray - var yyq4486 [5]bool - _, _, _ = yysep4486, yyq4486, yy2arr4486 - const yyr4486 bool = false - yyq4486[0] = x.Kind != "" - yyq4486[1] = x.APIVersion != "" - yyq4486[2] = true - var yynn4486 int - if yyr4486 || yy2arr4486 { - r.EncodeArrayStart(5) - } else { - yynn4486 = 2 - for _, b := range yyq4486 { - if b { - yynn4486++ - } - } - r.EncodeMapStart(yynn4486) - yynn4486 = 0 - } - if yyr4486 || yy2arr4486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4486[0] { - yym4488 := z.EncBinary() - _ = yym4488 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4486[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4489 := z.EncBinary() - _ = yym4489 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4486 || yy2arr4486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4486[1] { - yym4491 := z.EncBinary() - _ = yym4491 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4486[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4492 := z.EncBinary() - _ = yym4492 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4486 || yy2arr4486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4486[2] { - yy4494 := &x.ObjectMeta - yy4494.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4486[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4495 := &x.ObjectMeta - yy4495.CodecEncodeSelf(e) - } - } - if yyr4486 || yy2arr4486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym4497 := z.EncBinary() - _ = yym4497 - 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) - yym4498 := z.EncBinary() - _ = yym4498 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Range)) - } - } - if yyr4486 || yy2arr4486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4500 := z.EncBinary() - _ = yym4500 - 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 { - yym4501 := z.EncBinary() - _ = yym4501 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) - } - } - } - if yyr4486 || yy2arr4486 { - 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 - yym4502 := z.DecBinary() - _ = yym4502 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4503 := r.ContainerType() - if yyct4503 == codecSelferValueTypeMap1234 { - yyl4503 := r.ReadMapStart() - if yyl4503 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4503, d) - } - } else if yyct4503 == codecSelferValueTypeArray1234 { - yyl4503 := r.ReadArrayStart() - if yyl4503 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4503, 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 yys4504Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4504Slc - var yyhl4504 bool = l >= 0 - for yyj4504 := 0; ; yyj4504++ { - if yyhl4504 { - if yyj4504 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4504Slc = r.DecodeBytes(yys4504Slc, true, true) - yys4504 := string(yys4504Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4504 { - 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()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4507 := &x.ObjectMeta - yyv4507.CodecDecodeSelf(d) - } - case "range": - if r.TryDecodeAsNil() { - x.Range = "" - } else { - x.Range = string(r.DecodeString()) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4509 := &x.Data - yym4510 := z.DecBinary() - _ = yym4510 - if false { - } else { - *yyv4509 = r.DecodeBytes(*(*[]byte)(yyv4509), false, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys4504) - } // end switch yys4504 - } // end for yyj4504 - 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 yyj4511 int - var yyb4511 bool - var yyhl4511 bool = l >= 0 - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4514 := &x.ObjectMeta - yyv4514.CodecDecodeSelf(d) - } - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Range = "" - } else { - x.Range = string(r.DecodeString()) - } - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4516 := &x.Data - yym4517 := z.DecBinary() - _ = yym4517 - if false { - } else { - *yyv4516 = r.DecodeBytes(*(*[]byte)(yyv4516), false, false) - } - } - for { - yyj4511++ - if yyhl4511 { - yyb4511 = yyj4511 > l - } else { - yyb4511 = r.CheckBreak() - } - if yyb4511 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4511-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 _, yyv4518 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4519 := &yyv4518 - yy4519.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 - - yyv4520 := *v - yyh4520, yyl4520 := z.DecSliceHelperStart() - var yyc4520 bool - if yyl4520 == 0 { - if yyv4520 == nil { - yyv4520 = []OwnerReference{} - yyc4520 = true - } else if len(yyv4520) != 0 { - yyv4520 = yyv4520[:0] - yyc4520 = true - } - } else if yyl4520 > 0 { - var yyrr4520, yyrl4520 int - var yyrt4520 bool - if yyl4520 > cap(yyv4520) { - - yyrg4520 := len(yyv4520) > 0 - yyv24520 := yyv4520 - yyrl4520, yyrt4520 = z.DecInferLen(yyl4520, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4520 { - if yyrl4520 <= cap(yyv4520) { - yyv4520 = yyv4520[:yyrl4520] - } else { - yyv4520 = make([]OwnerReference, yyrl4520) - } - } else { - yyv4520 = make([]OwnerReference, yyrl4520) - } - yyc4520 = true - yyrr4520 = len(yyv4520) - if yyrg4520 { - copy(yyv4520, yyv24520) - } - } else if yyl4520 != len(yyv4520) { - yyv4520 = yyv4520[:yyl4520] - yyc4520 = true - } - yyj4520 := 0 - for ; yyj4520 < yyrr4520; yyj4520++ { - yyh4520.ElemContainerState(yyj4520) - if r.TryDecodeAsNil() { - yyv4520[yyj4520] = OwnerReference{} - } else { - yyv4521 := &yyv4520[yyj4520] - yyv4521.CodecDecodeSelf(d) - } - - } - if yyrt4520 { - for ; yyj4520 < yyl4520; yyj4520++ { - yyv4520 = append(yyv4520, OwnerReference{}) - yyh4520.ElemContainerState(yyj4520) - if r.TryDecodeAsNil() { - yyv4520[yyj4520] = OwnerReference{} - } else { - yyv4522 := &yyv4520[yyj4520] - yyv4522.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4520 := 0 - for ; !r.CheckBreak(); yyj4520++ { - - if yyj4520 >= len(yyv4520) { - yyv4520 = append(yyv4520, OwnerReference{}) // var yyz4520 OwnerReference - yyc4520 = true - } - yyh4520.ElemContainerState(yyj4520) - if yyj4520 < len(yyv4520) { - if r.TryDecodeAsNil() { - yyv4520[yyj4520] = OwnerReference{} - } else { - yyv4523 := &yyv4520[yyj4520] - yyv4523.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4520 < len(yyv4520) { - yyv4520 = yyv4520[:yyj4520] - yyc4520 = true - } else if yyj4520 == 0 && yyv4520 == nil { - yyv4520 = []OwnerReference{} - yyc4520 = true - } - } - yyh4520.End() - if yyc4520 { - *v = yyv4520 - } -} - -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 _, yyv4524 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4524.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 - - yyv4525 := *v - yyh4525, yyl4525 := z.DecSliceHelperStart() - var yyc4525 bool - if yyl4525 == 0 { - if yyv4525 == nil { - yyv4525 = []PersistentVolumeAccessMode{} - yyc4525 = true - } else if len(yyv4525) != 0 { - yyv4525 = yyv4525[:0] - yyc4525 = true - } - } else if yyl4525 > 0 { - var yyrr4525, yyrl4525 int - var yyrt4525 bool - if yyl4525 > cap(yyv4525) { - - yyrl4525, yyrt4525 = z.DecInferLen(yyl4525, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4525 { - if yyrl4525 <= cap(yyv4525) { - yyv4525 = yyv4525[:yyrl4525] - } else { - yyv4525 = make([]PersistentVolumeAccessMode, yyrl4525) - } - } else { - yyv4525 = make([]PersistentVolumeAccessMode, yyrl4525) - } - yyc4525 = true - yyrr4525 = len(yyv4525) - } else if yyl4525 != len(yyv4525) { - yyv4525 = yyv4525[:yyl4525] - yyc4525 = true - } - yyj4525 := 0 - for ; yyj4525 < yyrr4525; yyj4525++ { - yyh4525.ElemContainerState(yyj4525) - if r.TryDecodeAsNil() { - yyv4525[yyj4525] = "" - } else { - yyv4525[yyj4525] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } - if yyrt4525 { - for ; yyj4525 < yyl4525; yyj4525++ { - yyv4525 = append(yyv4525, "") - yyh4525.ElemContainerState(yyj4525) - if r.TryDecodeAsNil() { - yyv4525[yyj4525] = "" - } else { - yyv4525[yyj4525] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } - } - - } else { - yyj4525 := 0 - for ; !r.CheckBreak(); yyj4525++ { - - if yyj4525 >= len(yyv4525) { - yyv4525 = append(yyv4525, "") // var yyz4525 PersistentVolumeAccessMode - yyc4525 = true - } - yyh4525.ElemContainerState(yyj4525) - if yyj4525 < len(yyv4525) { - if r.TryDecodeAsNil() { - yyv4525[yyj4525] = "" - } else { - yyv4525[yyj4525] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4525 < len(yyv4525) { - yyv4525 = yyv4525[:yyj4525] - yyc4525 = true - } else if yyj4525 == 0 && yyv4525 == nil { - yyv4525 = []PersistentVolumeAccessMode{} - yyc4525 = true - } - } - yyh4525.End() - if yyc4525 { - *v = yyv4525 - } -} - -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 _, yyv4529 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4530 := &yyv4529 - yy4530.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 - - yyv4531 := *v - yyh4531, yyl4531 := z.DecSliceHelperStart() - var yyc4531 bool - if yyl4531 == 0 { - if yyv4531 == nil { - yyv4531 = []PersistentVolume{} - yyc4531 = true - } else if len(yyv4531) != 0 { - yyv4531 = yyv4531[:0] - yyc4531 = true - } - } else if yyl4531 > 0 { - var yyrr4531, yyrl4531 int - var yyrt4531 bool - if yyl4531 > cap(yyv4531) { - - yyrg4531 := len(yyv4531) > 0 - yyv24531 := yyv4531 - yyrl4531, yyrt4531 = z.DecInferLen(yyl4531, z.DecBasicHandle().MaxInitLen, 488) - if yyrt4531 { - if yyrl4531 <= cap(yyv4531) { - yyv4531 = yyv4531[:yyrl4531] - } else { - yyv4531 = make([]PersistentVolume, yyrl4531) - } - } else { - yyv4531 = make([]PersistentVolume, yyrl4531) - } - yyc4531 = true - yyrr4531 = len(yyv4531) - if yyrg4531 { - copy(yyv4531, yyv24531) - } - } else if yyl4531 != len(yyv4531) { - yyv4531 = yyv4531[:yyl4531] - yyc4531 = true - } - yyj4531 := 0 - for ; yyj4531 < yyrr4531; yyj4531++ { - yyh4531.ElemContainerState(yyj4531) - if r.TryDecodeAsNil() { - yyv4531[yyj4531] = PersistentVolume{} - } else { - yyv4532 := &yyv4531[yyj4531] - yyv4532.CodecDecodeSelf(d) - } - - } - if yyrt4531 { - for ; yyj4531 < yyl4531; yyj4531++ { - yyv4531 = append(yyv4531, PersistentVolume{}) - yyh4531.ElemContainerState(yyj4531) - if r.TryDecodeAsNil() { - yyv4531[yyj4531] = PersistentVolume{} - } else { - yyv4533 := &yyv4531[yyj4531] - yyv4533.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4531 := 0 - for ; !r.CheckBreak(); yyj4531++ { - - if yyj4531 >= len(yyv4531) { - yyv4531 = append(yyv4531, PersistentVolume{}) // var yyz4531 PersistentVolume - yyc4531 = true - } - yyh4531.ElemContainerState(yyj4531) - if yyj4531 < len(yyv4531) { - if r.TryDecodeAsNil() { - yyv4531[yyj4531] = PersistentVolume{} - } else { - yyv4534 := &yyv4531[yyj4531] - yyv4534.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4531 < len(yyv4531) { - yyv4531 = yyv4531[:yyj4531] - yyc4531 = true - } else if yyj4531 == 0 && yyv4531 == nil { - yyv4531 = []PersistentVolume{} - yyc4531 = true - } - } - yyh4531.End() - if yyc4531 { - *v = yyv4531 - } -} - -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 _, yyv4535 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4536 := &yyv4535 - yy4536.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 - - yyv4537 := *v - yyh4537, yyl4537 := z.DecSliceHelperStart() - var yyc4537 bool - if yyl4537 == 0 { - if yyv4537 == nil { - yyv4537 = []PersistentVolumeClaim{} - yyc4537 = true - } else if len(yyv4537) != 0 { - yyv4537 = yyv4537[:0] - yyc4537 = true - } - } else if yyl4537 > 0 { - var yyrr4537, yyrl4537 int - var yyrt4537 bool - if yyl4537 > cap(yyv4537) { - - yyrg4537 := len(yyv4537) > 0 - yyv24537 := yyv4537 - yyrl4537, yyrt4537 = z.DecInferLen(yyl4537, z.DecBasicHandle().MaxInitLen, 368) - if yyrt4537 { - if yyrl4537 <= cap(yyv4537) { - yyv4537 = yyv4537[:yyrl4537] - } else { - yyv4537 = make([]PersistentVolumeClaim, yyrl4537) - } - } else { - yyv4537 = make([]PersistentVolumeClaim, yyrl4537) - } - yyc4537 = true - yyrr4537 = len(yyv4537) - if yyrg4537 { - copy(yyv4537, yyv24537) - } - } else if yyl4537 != len(yyv4537) { - yyv4537 = yyv4537[:yyl4537] - yyc4537 = true - } - yyj4537 := 0 - for ; yyj4537 < yyrr4537; yyj4537++ { - yyh4537.ElemContainerState(yyj4537) - if r.TryDecodeAsNil() { - yyv4537[yyj4537] = PersistentVolumeClaim{} - } else { - yyv4538 := &yyv4537[yyj4537] - yyv4538.CodecDecodeSelf(d) - } - - } - if yyrt4537 { - for ; yyj4537 < yyl4537; yyj4537++ { - yyv4537 = append(yyv4537, PersistentVolumeClaim{}) - yyh4537.ElemContainerState(yyj4537) - if r.TryDecodeAsNil() { - yyv4537[yyj4537] = PersistentVolumeClaim{} - } else { - yyv4539 := &yyv4537[yyj4537] - yyv4539.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4537 := 0 - for ; !r.CheckBreak(); yyj4537++ { - - if yyj4537 >= len(yyv4537) { - yyv4537 = append(yyv4537, PersistentVolumeClaim{}) // var yyz4537 PersistentVolumeClaim - yyc4537 = true - } - yyh4537.ElemContainerState(yyj4537) - if yyj4537 < len(yyv4537) { - if r.TryDecodeAsNil() { - yyv4537[yyj4537] = PersistentVolumeClaim{} - } else { - yyv4540 := &yyv4537[yyj4537] - yyv4540.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4537 < len(yyv4537) { - yyv4537 = yyv4537[:yyj4537] - yyc4537 = true - } else if yyj4537 == 0 && yyv4537 == nil { - yyv4537 = []PersistentVolumeClaim{} - yyc4537 = true - } - } - yyh4537.End() - if yyc4537 { - *v = yyv4537 - } -} - -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 _, yyv4541 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4542 := &yyv4541 - yy4542.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 - - yyv4543 := *v - yyh4543, yyl4543 := z.DecSliceHelperStart() - var yyc4543 bool - if yyl4543 == 0 { - if yyv4543 == nil { - yyv4543 = []KeyToPath{} - yyc4543 = true - } else if len(yyv4543) != 0 { - yyv4543 = yyv4543[:0] - yyc4543 = true - } - } else if yyl4543 > 0 { - var yyrr4543, yyrl4543 int - var yyrt4543 bool - if yyl4543 > cap(yyv4543) { - - yyrg4543 := len(yyv4543) > 0 - yyv24543 := yyv4543 - yyrl4543, yyrt4543 = z.DecInferLen(yyl4543, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4543 { - if yyrl4543 <= cap(yyv4543) { - yyv4543 = yyv4543[:yyrl4543] - } else { - yyv4543 = make([]KeyToPath, yyrl4543) - } - } else { - yyv4543 = make([]KeyToPath, yyrl4543) - } - yyc4543 = true - yyrr4543 = len(yyv4543) - if yyrg4543 { - copy(yyv4543, yyv24543) - } - } else if yyl4543 != len(yyv4543) { - yyv4543 = yyv4543[:yyl4543] - yyc4543 = true - } - yyj4543 := 0 - for ; yyj4543 < yyrr4543; yyj4543++ { - yyh4543.ElemContainerState(yyj4543) - if r.TryDecodeAsNil() { - yyv4543[yyj4543] = KeyToPath{} - } else { - yyv4544 := &yyv4543[yyj4543] - yyv4544.CodecDecodeSelf(d) - } - - } - if yyrt4543 { - for ; yyj4543 < yyl4543; yyj4543++ { - yyv4543 = append(yyv4543, KeyToPath{}) - yyh4543.ElemContainerState(yyj4543) - if r.TryDecodeAsNil() { - yyv4543[yyj4543] = KeyToPath{} - } else { - yyv4545 := &yyv4543[yyj4543] - yyv4545.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4543 := 0 - for ; !r.CheckBreak(); yyj4543++ { - - if yyj4543 >= len(yyv4543) { - yyv4543 = append(yyv4543, KeyToPath{}) // var yyz4543 KeyToPath - yyc4543 = true - } - yyh4543.ElemContainerState(yyj4543) - if yyj4543 < len(yyv4543) { - if r.TryDecodeAsNil() { - yyv4543[yyj4543] = KeyToPath{} - } else { - yyv4546 := &yyv4543[yyj4543] - yyv4546.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4543 < len(yyv4543) { - yyv4543 = yyv4543[:yyj4543] - yyc4543 = true - } else if yyj4543 == 0 && yyv4543 == nil { - yyv4543 = []KeyToPath{} - yyc4543 = true - } - } - yyh4543.End() - if yyc4543 { - *v = yyv4543 - } -} - -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 _, yyv4547 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4548 := &yyv4547 - yy4548.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 - - yyv4549 := *v - yyh4549, yyl4549 := z.DecSliceHelperStart() - var yyc4549 bool - if yyl4549 == 0 { - if yyv4549 == nil { - yyv4549 = []HTTPHeader{} - yyc4549 = true - } else if len(yyv4549) != 0 { - yyv4549 = yyv4549[:0] - yyc4549 = true - } - } else if yyl4549 > 0 { - var yyrr4549, yyrl4549 int - var yyrt4549 bool - if yyl4549 > cap(yyv4549) { - - yyrg4549 := len(yyv4549) > 0 - yyv24549 := yyv4549 - yyrl4549, yyrt4549 = z.DecInferLen(yyl4549, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4549 { - if yyrl4549 <= cap(yyv4549) { - yyv4549 = yyv4549[:yyrl4549] - } else { - yyv4549 = make([]HTTPHeader, yyrl4549) - } - } else { - yyv4549 = make([]HTTPHeader, yyrl4549) - } - yyc4549 = true - yyrr4549 = len(yyv4549) - if yyrg4549 { - copy(yyv4549, yyv24549) - } - } else if yyl4549 != len(yyv4549) { - yyv4549 = yyv4549[:yyl4549] - yyc4549 = true - } - yyj4549 := 0 - for ; yyj4549 < yyrr4549; yyj4549++ { - yyh4549.ElemContainerState(yyj4549) - if r.TryDecodeAsNil() { - yyv4549[yyj4549] = HTTPHeader{} - } else { - yyv4550 := &yyv4549[yyj4549] - yyv4550.CodecDecodeSelf(d) - } - - } - if yyrt4549 { - for ; yyj4549 < yyl4549; yyj4549++ { - yyv4549 = append(yyv4549, HTTPHeader{}) - yyh4549.ElemContainerState(yyj4549) - if r.TryDecodeAsNil() { - yyv4549[yyj4549] = HTTPHeader{} - } else { - yyv4551 := &yyv4549[yyj4549] - yyv4551.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4549 := 0 - for ; !r.CheckBreak(); yyj4549++ { - - if yyj4549 >= len(yyv4549) { - yyv4549 = append(yyv4549, HTTPHeader{}) // var yyz4549 HTTPHeader - yyc4549 = true - } - yyh4549.ElemContainerState(yyj4549) - if yyj4549 < len(yyv4549) { - if r.TryDecodeAsNil() { - yyv4549[yyj4549] = HTTPHeader{} - } else { - yyv4552 := &yyv4549[yyj4549] - yyv4552.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4549 < len(yyv4549) { - yyv4549 = yyv4549[:yyj4549] - yyc4549 = true - } else if yyj4549 == 0 && yyv4549 == nil { - yyv4549 = []HTTPHeader{} - yyc4549 = true - } - } - yyh4549.End() - if yyc4549 { - *v = yyv4549 - } -} - -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 _, yyv4553 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4553.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 - - yyv4554 := *v - yyh4554, yyl4554 := z.DecSliceHelperStart() - var yyc4554 bool - if yyl4554 == 0 { - if yyv4554 == nil { - yyv4554 = []Capability{} - yyc4554 = true - } else if len(yyv4554) != 0 { - yyv4554 = yyv4554[:0] - yyc4554 = true - } - } else if yyl4554 > 0 { - var yyrr4554, yyrl4554 int - var yyrt4554 bool - if yyl4554 > cap(yyv4554) { - - yyrl4554, yyrt4554 = z.DecInferLen(yyl4554, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4554 { - if yyrl4554 <= cap(yyv4554) { - yyv4554 = yyv4554[:yyrl4554] - } else { - yyv4554 = make([]Capability, yyrl4554) - } - } else { - yyv4554 = make([]Capability, yyrl4554) - } - yyc4554 = true - yyrr4554 = len(yyv4554) - } else if yyl4554 != len(yyv4554) { - yyv4554 = yyv4554[:yyl4554] - yyc4554 = true - } - yyj4554 := 0 - for ; yyj4554 < yyrr4554; yyj4554++ { - yyh4554.ElemContainerState(yyj4554) - if r.TryDecodeAsNil() { - yyv4554[yyj4554] = "" - } else { - yyv4554[yyj4554] = Capability(r.DecodeString()) - } - - } - if yyrt4554 { - for ; yyj4554 < yyl4554; yyj4554++ { - yyv4554 = append(yyv4554, "") - yyh4554.ElemContainerState(yyj4554) - if r.TryDecodeAsNil() { - yyv4554[yyj4554] = "" - } else { - yyv4554[yyj4554] = Capability(r.DecodeString()) - } - - } - } - - } else { - yyj4554 := 0 - for ; !r.CheckBreak(); yyj4554++ { - - if yyj4554 >= len(yyv4554) { - yyv4554 = append(yyv4554, "") // var yyz4554 Capability - yyc4554 = true - } - yyh4554.ElemContainerState(yyj4554) - if yyj4554 < len(yyv4554) { - if r.TryDecodeAsNil() { - yyv4554[yyj4554] = "" - } else { - yyv4554[yyj4554] = Capability(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4554 < len(yyv4554) { - yyv4554 = yyv4554[:yyj4554] - yyc4554 = true - } else if yyj4554 == 0 && yyv4554 == nil { - yyv4554 = []Capability{} - yyc4554 = true - } - } - yyh4554.End() - if yyc4554 { - *v = yyv4554 - } -} - -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 _, yyv4558 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4559 := &yyv4558 - yy4559.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 - - yyv4560 := *v - yyh4560, yyl4560 := z.DecSliceHelperStart() - var yyc4560 bool - if yyl4560 == 0 { - if yyv4560 == nil { - yyv4560 = []ContainerPort{} - yyc4560 = true - } else if len(yyv4560) != 0 { - yyv4560 = yyv4560[:0] - yyc4560 = true - } - } else if yyl4560 > 0 { - var yyrr4560, yyrl4560 int - var yyrt4560 bool - if yyl4560 > cap(yyv4560) { - - yyrg4560 := len(yyv4560) > 0 - yyv24560 := yyv4560 - yyrl4560, yyrt4560 = z.DecInferLen(yyl4560, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4560 { - if yyrl4560 <= cap(yyv4560) { - yyv4560 = yyv4560[:yyrl4560] - } else { - yyv4560 = make([]ContainerPort, yyrl4560) - } - } else { - yyv4560 = make([]ContainerPort, yyrl4560) - } - yyc4560 = true - yyrr4560 = len(yyv4560) - if yyrg4560 { - copy(yyv4560, yyv24560) - } - } else if yyl4560 != len(yyv4560) { - yyv4560 = yyv4560[:yyl4560] - yyc4560 = true - } - yyj4560 := 0 - for ; yyj4560 < yyrr4560; yyj4560++ { - yyh4560.ElemContainerState(yyj4560) - if r.TryDecodeAsNil() { - yyv4560[yyj4560] = ContainerPort{} - } else { - yyv4561 := &yyv4560[yyj4560] - yyv4561.CodecDecodeSelf(d) - } - - } - if yyrt4560 { - for ; yyj4560 < yyl4560; yyj4560++ { - yyv4560 = append(yyv4560, ContainerPort{}) - yyh4560.ElemContainerState(yyj4560) - if r.TryDecodeAsNil() { - yyv4560[yyj4560] = ContainerPort{} - } else { - yyv4562 := &yyv4560[yyj4560] - yyv4562.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4560 := 0 - for ; !r.CheckBreak(); yyj4560++ { - - if yyj4560 >= len(yyv4560) { - yyv4560 = append(yyv4560, ContainerPort{}) // var yyz4560 ContainerPort - yyc4560 = true - } - yyh4560.ElemContainerState(yyj4560) - if yyj4560 < len(yyv4560) { - if r.TryDecodeAsNil() { - yyv4560[yyj4560] = ContainerPort{} - } else { - yyv4563 := &yyv4560[yyj4560] - yyv4563.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4560 < len(yyv4560) { - yyv4560 = yyv4560[:yyj4560] - yyc4560 = true - } else if yyj4560 == 0 && yyv4560 == nil { - yyv4560 = []ContainerPort{} - yyc4560 = true - } - } - yyh4560.End() - if yyc4560 { - *v = yyv4560 - } -} - -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 _, yyv4564 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4565 := &yyv4564 - yy4565.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 - - yyv4566 := *v - yyh4566, yyl4566 := z.DecSliceHelperStart() - var yyc4566 bool - if yyl4566 == 0 { - if yyv4566 == nil { - yyv4566 = []EnvVar{} - yyc4566 = true - } else if len(yyv4566) != 0 { - yyv4566 = yyv4566[:0] - yyc4566 = true - } - } else if yyl4566 > 0 { - var yyrr4566, yyrl4566 int - var yyrt4566 bool - if yyl4566 > cap(yyv4566) { - - yyrg4566 := len(yyv4566) > 0 - yyv24566 := yyv4566 - yyrl4566, yyrt4566 = z.DecInferLen(yyl4566, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4566 { - if yyrl4566 <= cap(yyv4566) { - yyv4566 = yyv4566[:yyrl4566] - } else { - yyv4566 = make([]EnvVar, yyrl4566) - } - } else { - yyv4566 = make([]EnvVar, yyrl4566) - } - yyc4566 = true - yyrr4566 = len(yyv4566) - if yyrg4566 { - copy(yyv4566, yyv24566) - } - } else if yyl4566 != len(yyv4566) { - yyv4566 = yyv4566[:yyl4566] - yyc4566 = true - } - yyj4566 := 0 - for ; yyj4566 < yyrr4566; yyj4566++ { - yyh4566.ElemContainerState(yyj4566) - if r.TryDecodeAsNil() { - yyv4566[yyj4566] = EnvVar{} - } else { - yyv4567 := &yyv4566[yyj4566] - yyv4567.CodecDecodeSelf(d) - } - - } - if yyrt4566 { - for ; yyj4566 < yyl4566; yyj4566++ { - yyv4566 = append(yyv4566, EnvVar{}) - yyh4566.ElemContainerState(yyj4566) - if r.TryDecodeAsNil() { - yyv4566[yyj4566] = EnvVar{} - } else { - yyv4568 := &yyv4566[yyj4566] - yyv4568.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4566 := 0 - for ; !r.CheckBreak(); yyj4566++ { - - if yyj4566 >= len(yyv4566) { - yyv4566 = append(yyv4566, EnvVar{}) // var yyz4566 EnvVar - yyc4566 = true - } - yyh4566.ElemContainerState(yyj4566) - if yyj4566 < len(yyv4566) { - if r.TryDecodeAsNil() { - yyv4566[yyj4566] = EnvVar{} - } else { - yyv4569 := &yyv4566[yyj4566] - yyv4569.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4566 < len(yyv4566) { - yyv4566 = yyv4566[:yyj4566] - yyc4566 = true - } else if yyj4566 == 0 && yyv4566 == nil { - yyv4566 = []EnvVar{} - yyc4566 = true - } - } - yyh4566.End() - if yyc4566 { - *v = yyv4566 - } -} - -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 _, yyv4570 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4571 := &yyv4570 - yy4571.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 - - yyv4572 := *v - yyh4572, yyl4572 := z.DecSliceHelperStart() - var yyc4572 bool - if yyl4572 == 0 { - if yyv4572 == nil { - yyv4572 = []VolumeMount{} - yyc4572 = true - } else if len(yyv4572) != 0 { - yyv4572 = yyv4572[:0] - yyc4572 = true - } - } else if yyl4572 > 0 { - var yyrr4572, yyrl4572 int - var yyrt4572 bool - if yyl4572 > cap(yyv4572) { - - yyrg4572 := len(yyv4572) > 0 - yyv24572 := yyv4572 - yyrl4572, yyrt4572 = z.DecInferLen(yyl4572, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4572 { - if yyrl4572 <= cap(yyv4572) { - yyv4572 = yyv4572[:yyrl4572] - } else { - yyv4572 = make([]VolumeMount, yyrl4572) - } - } else { - yyv4572 = make([]VolumeMount, yyrl4572) - } - yyc4572 = true - yyrr4572 = len(yyv4572) - if yyrg4572 { - copy(yyv4572, yyv24572) - } - } else if yyl4572 != len(yyv4572) { - yyv4572 = yyv4572[:yyl4572] - yyc4572 = true - } - yyj4572 := 0 - for ; yyj4572 < yyrr4572; yyj4572++ { - yyh4572.ElemContainerState(yyj4572) - if r.TryDecodeAsNil() { - yyv4572[yyj4572] = VolumeMount{} - } else { - yyv4573 := &yyv4572[yyj4572] - yyv4573.CodecDecodeSelf(d) - } - - } - if yyrt4572 { - for ; yyj4572 < yyl4572; yyj4572++ { - yyv4572 = append(yyv4572, VolumeMount{}) - yyh4572.ElemContainerState(yyj4572) - if r.TryDecodeAsNil() { - yyv4572[yyj4572] = VolumeMount{} - } else { - yyv4574 := &yyv4572[yyj4572] - yyv4574.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4572 := 0 - for ; !r.CheckBreak(); yyj4572++ { - - if yyj4572 >= len(yyv4572) { - yyv4572 = append(yyv4572, VolumeMount{}) // var yyz4572 VolumeMount - yyc4572 = true - } - yyh4572.ElemContainerState(yyj4572) - if yyj4572 < len(yyv4572) { - if r.TryDecodeAsNil() { - yyv4572[yyj4572] = VolumeMount{} - } else { - yyv4575 := &yyv4572[yyj4572] - yyv4575.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4572 < len(yyv4572) { - yyv4572 = yyv4572[:yyj4572] - yyc4572 = true - } else if yyj4572 == 0 && yyv4572 == nil { - yyv4572 = []VolumeMount{} - yyc4572 = true - } - } - yyh4572.End() - if yyc4572 { - *v = yyv4572 - } -} - -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 _, yyv4576 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4577 := &yyv4576 - yy4577.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 - - yyv4578 := *v - yyh4578, yyl4578 := z.DecSliceHelperStart() - var yyc4578 bool - if yyl4578 == 0 { - if yyv4578 == nil { - yyv4578 = []NodeSelectorTerm{} - yyc4578 = true - } else if len(yyv4578) != 0 { - yyv4578 = yyv4578[:0] - yyc4578 = true - } - } else if yyl4578 > 0 { - var yyrr4578, yyrl4578 int - var yyrt4578 bool - if yyl4578 > cap(yyv4578) { - - yyrg4578 := len(yyv4578) > 0 - yyv24578 := yyv4578 - yyrl4578, yyrt4578 = z.DecInferLen(yyl4578, z.DecBasicHandle().MaxInitLen, 24) - if yyrt4578 { - if yyrl4578 <= cap(yyv4578) { - yyv4578 = yyv4578[:yyrl4578] - } else { - yyv4578 = make([]NodeSelectorTerm, yyrl4578) - } - } else { - yyv4578 = make([]NodeSelectorTerm, yyrl4578) - } - yyc4578 = true - yyrr4578 = len(yyv4578) - if yyrg4578 { - copy(yyv4578, yyv24578) - } - } else if yyl4578 != len(yyv4578) { - yyv4578 = yyv4578[:yyl4578] - yyc4578 = true - } - yyj4578 := 0 - for ; yyj4578 < yyrr4578; yyj4578++ { - yyh4578.ElemContainerState(yyj4578) - if r.TryDecodeAsNil() { - yyv4578[yyj4578] = NodeSelectorTerm{} - } else { - yyv4579 := &yyv4578[yyj4578] - yyv4579.CodecDecodeSelf(d) - } - - } - if yyrt4578 { - for ; yyj4578 < yyl4578; yyj4578++ { - yyv4578 = append(yyv4578, NodeSelectorTerm{}) - yyh4578.ElemContainerState(yyj4578) - if r.TryDecodeAsNil() { - yyv4578[yyj4578] = NodeSelectorTerm{} - } else { - yyv4580 := &yyv4578[yyj4578] - yyv4580.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4578 := 0 - for ; !r.CheckBreak(); yyj4578++ { - - if yyj4578 >= len(yyv4578) { - yyv4578 = append(yyv4578, NodeSelectorTerm{}) // var yyz4578 NodeSelectorTerm - yyc4578 = true - } - yyh4578.ElemContainerState(yyj4578) - if yyj4578 < len(yyv4578) { - if r.TryDecodeAsNil() { - yyv4578[yyj4578] = NodeSelectorTerm{} - } else { - yyv4581 := &yyv4578[yyj4578] - yyv4581.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4578 < len(yyv4578) { - yyv4578 = yyv4578[:yyj4578] - yyc4578 = true - } else if yyj4578 == 0 && yyv4578 == nil { - yyv4578 = []NodeSelectorTerm{} - yyc4578 = true - } - } - yyh4578.End() - if yyc4578 { - *v = yyv4578 - } -} - -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 _, yyv4582 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4583 := &yyv4582 - yy4583.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 - - yyv4584 := *v - yyh4584, yyl4584 := z.DecSliceHelperStart() - var yyc4584 bool - if yyl4584 == 0 { - if yyv4584 == nil { - yyv4584 = []NodeSelectorRequirement{} - yyc4584 = true - } else if len(yyv4584) != 0 { - yyv4584 = yyv4584[:0] - yyc4584 = true - } - } else if yyl4584 > 0 { - var yyrr4584, yyrl4584 int - var yyrt4584 bool - if yyl4584 > cap(yyv4584) { - - yyrg4584 := len(yyv4584) > 0 - yyv24584 := yyv4584 - yyrl4584, yyrt4584 = z.DecInferLen(yyl4584, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4584 { - if yyrl4584 <= cap(yyv4584) { - yyv4584 = yyv4584[:yyrl4584] - } else { - yyv4584 = make([]NodeSelectorRequirement, yyrl4584) - } - } else { - yyv4584 = make([]NodeSelectorRequirement, yyrl4584) - } - yyc4584 = true - yyrr4584 = len(yyv4584) - if yyrg4584 { - copy(yyv4584, yyv24584) - } - } else if yyl4584 != len(yyv4584) { - yyv4584 = yyv4584[:yyl4584] - yyc4584 = true - } - yyj4584 := 0 - for ; yyj4584 < yyrr4584; yyj4584++ { - yyh4584.ElemContainerState(yyj4584) - if r.TryDecodeAsNil() { - yyv4584[yyj4584] = NodeSelectorRequirement{} - } else { - yyv4585 := &yyv4584[yyj4584] - yyv4585.CodecDecodeSelf(d) - } - - } - if yyrt4584 { - for ; yyj4584 < yyl4584; yyj4584++ { - yyv4584 = append(yyv4584, NodeSelectorRequirement{}) - yyh4584.ElemContainerState(yyj4584) - if r.TryDecodeAsNil() { - yyv4584[yyj4584] = NodeSelectorRequirement{} - } else { - yyv4586 := &yyv4584[yyj4584] - yyv4586.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4584 := 0 - for ; !r.CheckBreak(); yyj4584++ { - - if yyj4584 >= len(yyv4584) { - yyv4584 = append(yyv4584, NodeSelectorRequirement{}) // var yyz4584 NodeSelectorRequirement - yyc4584 = true - } - yyh4584.ElemContainerState(yyj4584) - if yyj4584 < len(yyv4584) { - if r.TryDecodeAsNil() { - yyv4584[yyj4584] = NodeSelectorRequirement{} - } else { - yyv4587 := &yyv4584[yyj4584] - yyv4587.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4584 < len(yyv4584) { - yyv4584 = yyv4584[:yyj4584] - yyc4584 = true - } else if yyj4584 == 0 && yyv4584 == nil { - yyv4584 = []NodeSelectorRequirement{} - yyc4584 = true - } - } - yyh4584.End() - if yyc4584 { - *v = yyv4584 - } -} - -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 _, yyv4588 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4589 := &yyv4588 - yy4589.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 - - yyv4590 := *v - yyh4590, yyl4590 := z.DecSliceHelperStart() - var yyc4590 bool - if yyl4590 == 0 { - if yyv4590 == nil { - yyv4590 = []PodAffinityTerm{} - yyc4590 = true - } else if len(yyv4590) != 0 { - yyv4590 = yyv4590[:0] - yyc4590 = true - } - } else if yyl4590 > 0 { - var yyrr4590, yyrl4590 int - var yyrt4590 bool - if yyl4590 > cap(yyv4590) { - - yyrg4590 := len(yyv4590) > 0 - yyv24590 := yyv4590 - yyrl4590, yyrt4590 = z.DecInferLen(yyl4590, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4590 { - if yyrl4590 <= cap(yyv4590) { - yyv4590 = yyv4590[:yyrl4590] - } else { - yyv4590 = make([]PodAffinityTerm, yyrl4590) - } - } else { - yyv4590 = make([]PodAffinityTerm, yyrl4590) - } - yyc4590 = true - yyrr4590 = len(yyv4590) - if yyrg4590 { - copy(yyv4590, yyv24590) - } - } else if yyl4590 != len(yyv4590) { - yyv4590 = yyv4590[:yyl4590] - yyc4590 = true - } - yyj4590 := 0 - for ; yyj4590 < yyrr4590; yyj4590++ { - yyh4590.ElemContainerState(yyj4590) - if r.TryDecodeAsNil() { - yyv4590[yyj4590] = PodAffinityTerm{} - } else { - yyv4591 := &yyv4590[yyj4590] - yyv4591.CodecDecodeSelf(d) - } - - } - if yyrt4590 { - for ; yyj4590 < yyl4590; yyj4590++ { - yyv4590 = append(yyv4590, PodAffinityTerm{}) - yyh4590.ElemContainerState(yyj4590) - if r.TryDecodeAsNil() { - yyv4590[yyj4590] = PodAffinityTerm{} - } else { - yyv4592 := &yyv4590[yyj4590] - yyv4592.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4590 := 0 - for ; !r.CheckBreak(); yyj4590++ { - - if yyj4590 >= len(yyv4590) { - yyv4590 = append(yyv4590, PodAffinityTerm{}) // var yyz4590 PodAffinityTerm - yyc4590 = true - } - yyh4590.ElemContainerState(yyj4590) - if yyj4590 < len(yyv4590) { - if r.TryDecodeAsNil() { - yyv4590[yyj4590] = PodAffinityTerm{} - } else { - yyv4593 := &yyv4590[yyj4590] - yyv4593.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4590 < len(yyv4590) { - yyv4590 = yyv4590[:yyj4590] - yyc4590 = true - } else if yyj4590 == 0 && yyv4590 == nil { - yyv4590 = []PodAffinityTerm{} - yyc4590 = true - } - } - yyh4590.End() - if yyc4590 { - *v = yyv4590 - } -} - -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 _, yyv4594 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4595 := &yyv4594 - yy4595.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 - - yyv4596 := *v - yyh4596, yyl4596 := z.DecSliceHelperStart() - var yyc4596 bool - if yyl4596 == 0 { - if yyv4596 == nil { - yyv4596 = []WeightedPodAffinityTerm{} - yyc4596 = true - } else if len(yyv4596) != 0 { - yyv4596 = yyv4596[:0] - yyc4596 = true - } - } else if yyl4596 > 0 { - var yyrr4596, yyrl4596 int - var yyrt4596 bool - if yyl4596 > cap(yyv4596) { - - yyrg4596 := len(yyv4596) > 0 - yyv24596 := yyv4596 - yyrl4596, yyrt4596 = z.DecInferLen(yyl4596, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4596 { - if yyrl4596 <= cap(yyv4596) { - yyv4596 = yyv4596[:yyrl4596] - } else { - yyv4596 = make([]WeightedPodAffinityTerm, yyrl4596) - } - } else { - yyv4596 = make([]WeightedPodAffinityTerm, yyrl4596) - } - yyc4596 = true - yyrr4596 = len(yyv4596) - if yyrg4596 { - copy(yyv4596, yyv24596) - } - } else if yyl4596 != len(yyv4596) { - yyv4596 = yyv4596[:yyl4596] - yyc4596 = true - } - yyj4596 := 0 - for ; yyj4596 < yyrr4596; yyj4596++ { - yyh4596.ElemContainerState(yyj4596) - if r.TryDecodeAsNil() { - yyv4596[yyj4596] = WeightedPodAffinityTerm{} - } else { - yyv4597 := &yyv4596[yyj4596] - yyv4597.CodecDecodeSelf(d) - } - - } - if yyrt4596 { - for ; yyj4596 < yyl4596; yyj4596++ { - yyv4596 = append(yyv4596, WeightedPodAffinityTerm{}) - yyh4596.ElemContainerState(yyj4596) - if r.TryDecodeAsNil() { - yyv4596[yyj4596] = WeightedPodAffinityTerm{} - } else { - yyv4598 := &yyv4596[yyj4596] - yyv4598.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4596 := 0 - for ; !r.CheckBreak(); yyj4596++ { - - if yyj4596 >= len(yyv4596) { - yyv4596 = append(yyv4596, WeightedPodAffinityTerm{}) // var yyz4596 WeightedPodAffinityTerm - yyc4596 = true - } - yyh4596.ElemContainerState(yyj4596) - if yyj4596 < len(yyv4596) { - if r.TryDecodeAsNil() { - yyv4596[yyj4596] = WeightedPodAffinityTerm{} - } else { - yyv4599 := &yyv4596[yyj4596] - yyv4599.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4596 < len(yyv4596) { - yyv4596 = yyv4596[:yyj4596] - yyc4596 = true - } else if yyj4596 == 0 && yyv4596 == nil { - yyv4596 = []WeightedPodAffinityTerm{} - yyc4596 = true - } - } - yyh4596.End() - if yyc4596 { - *v = yyv4596 - } -} - -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 _, yyv4600 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4601 := &yyv4600 - yy4601.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 - - yyv4602 := *v - yyh4602, yyl4602 := z.DecSliceHelperStart() - var yyc4602 bool - if yyl4602 == 0 { - if yyv4602 == nil { - yyv4602 = []PreferredSchedulingTerm{} - yyc4602 = true - } else if len(yyv4602) != 0 { - yyv4602 = yyv4602[:0] - yyc4602 = true - } - } else if yyl4602 > 0 { - var yyrr4602, yyrl4602 int - var yyrt4602 bool - if yyl4602 > cap(yyv4602) { - - yyrg4602 := len(yyv4602) > 0 - yyv24602 := yyv4602 - yyrl4602, yyrt4602 = z.DecInferLen(yyl4602, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4602 { - if yyrl4602 <= cap(yyv4602) { - yyv4602 = yyv4602[:yyrl4602] - } else { - yyv4602 = make([]PreferredSchedulingTerm, yyrl4602) - } - } else { - yyv4602 = make([]PreferredSchedulingTerm, yyrl4602) - } - yyc4602 = true - yyrr4602 = len(yyv4602) - if yyrg4602 { - copy(yyv4602, yyv24602) - } - } else if yyl4602 != len(yyv4602) { - yyv4602 = yyv4602[:yyl4602] - yyc4602 = true - } - yyj4602 := 0 - for ; yyj4602 < yyrr4602; yyj4602++ { - yyh4602.ElemContainerState(yyj4602) - if r.TryDecodeAsNil() { - yyv4602[yyj4602] = PreferredSchedulingTerm{} - } else { - yyv4603 := &yyv4602[yyj4602] - yyv4603.CodecDecodeSelf(d) - } - - } - if yyrt4602 { - for ; yyj4602 < yyl4602; yyj4602++ { - yyv4602 = append(yyv4602, PreferredSchedulingTerm{}) - yyh4602.ElemContainerState(yyj4602) - if r.TryDecodeAsNil() { - yyv4602[yyj4602] = PreferredSchedulingTerm{} - } else { - yyv4604 := &yyv4602[yyj4602] - yyv4604.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4602 := 0 - for ; !r.CheckBreak(); yyj4602++ { - - if yyj4602 >= len(yyv4602) { - yyv4602 = append(yyv4602, PreferredSchedulingTerm{}) // var yyz4602 PreferredSchedulingTerm - yyc4602 = true - } - yyh4602.ElemContainerState(yyj4602) - if yyj4602 < len(yyv4602) { - if r.TryDecodeAsNil() { - yyv4602[yyj4602] = PreferredSchedulingTerm{} - } else { - yyv4605 := &yyv4602[yyj4602] - yyv4605.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4602 < len(yyv4602) { - yyv4602 = yyv4602[:yyj4602] - yyc4602 = true - } else if yyj4602 == 0 && yyv4602 == nil { - yyv4602 = []PreferredSchedulingTerm{} - yyc4602 = true - } - } - yyh4602.End() - if yyc4602 { - *v = yyv4602 - } -} - -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 _, yyv4606 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4607 := &yyv4606 - yy4607.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 - - yyv4608 := *v - yyh4608, yyl4608 := z.DecSliceHelperStart() - var yyc4608 bool - if yyl4608 == 0 { - if yyv4608 == nil { - yyv4608 = []Volume{} - yyc4608 = true - } else if len(yyv4608) != 0 { - yyv4608 = yyv4608[:0] - yyc4608 = true - } - } else if yyl4608 > 0 { - var yyrr4608, yyrl4608 int - var yyrt4608 bool - if yyl4608 > cap(yyv4608) { - - yyrg4608 := len(yyv4608) > 0 - yyv24608 := yyv4608 - yyrl4608, yyrt4608 = z.DecInferLen(yyl4608, z.DecBasicHandle().MaxInitLen, 192) - if yyrt4608 { - if yyrl4608 <= cap(yyv4608) { - yyv4608 = yyv4608[:yyrl4608] - } else { - yyv4608 = make([]Volume, yyrl4608) - } - } else { - yyv4608 = make([]Volume, yyrl4608) - } - yyc4608 = true - yyrr4608 = len(yyv4608) - if yyrg4608 { - copy(yyv4608, yyv24608) - } - } else if yyl4608 != len(yyv4608) { - yyv4608 = yyv4608[:yyl4608] - yyc4608 = true - } - yyj4608 := 0 - for ; yyj4608 < yyrr4608; yyj4608++ { - yyh4608.ElemContainerState(yyj4608) - if r.TryDecodeAsNil() { - yyv4608[yyj4608] = Volume{} - } else { - yyv4609 := &yyv4608[yyj4608] - yyv4609.CodecDecodeSelf(d) - } - - } - if yyrt4608 { - for ; yyj4608 < yyl4608; yyj4608++ { - yyv4608 = append(yyv4608, Volume{}) - yyh4608.ElemContainerState(yyj4608) - if r.TryDecodeAsNil() { - yyv4608[yyj4608] = Volume{} - } else { - yyv4610 := &yyv4608[yyj4608] - yyv4610.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4608 := 0 - for ; !r.CheckBreak(); yyj4608++ { - - if yyj4608 >= len(yyv4608) { - yyv4608 = append(yyv4608, Volume{}) // var yyz4608 Volume - yyc4608 = true - } - yyh4608.ElemContainerState(yyj4608) - if yyj4608 < len(yyv4608) { - if r.TryDecodeAsNil() { - yyv4608[yyj4608] = Volume{} - } else { - yyv4611 := &yyv4608[yyj4608] - yyv4611.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4608 < len(yyv4608) { - yyv4608 = yyv4608[:yyj4608] - yyc4608 = true - } else if yyj4608 == 0 && yyv4608 == nil { - yyv4608 = []Volume{} - yyc4608 = true - } - } - yyh4608.End() - if yyc4608 { - *v = yyv4608 - } -} - -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 _, yyv4612 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4613 := &yyv4612 - yy4613.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 - - yyv4614 := *v - yyh4614, yyl4614 := z.DecSliceHelperStart() - var yyc4614 bool - if yyl4614 == 0 { - if yyv4614 == nil { - yyv4614 = []Container{} - yyc4614 = true - } else if len(yyv4614) != 0 { - yyv4614 = yyv4614[:0] - yyc4614 = true - } - } else if yyl4614 > 0 { - var yyrr4614, yyrl4614 int - var yyrt4614 bool - if yyl4614 > cap(yyv4614) { - - yyrg4614 := len(yyv4614) > 0 - yyv24614 := yyv4614 - yyrl4614, yyrt4614 = z.DecInferLen(yyl4614, z.DecBasicHandle().MaxInitLen, 256) - if yyrt4614 { - if yyrl4614 <= cap(yyv4614) { - yyv4614 = yyv4614[:yyrl4614] - } else { - yyv4614 = make([]Container, yyrl4614) - } - } else { - yyv4614 = make([]Container, yyrl4614) - } - yyc4614 = true - yyrr4614 = len(yyv4614) - if yyrg4614 { - copy(yyv4614, yyv24614) - } - } else if yyl4614 != len(yyv4614) { - yyv4614 = yyv4614[:yyl4614] - yyc4614 = true - } - yyj4614 := 0 - for ; yyj4614 < yyrr4614; yyj4614++ { - yyh4614.ElemContainerState(yyj4614) - if r.TryDecodeAsNil() { - yyv4614[yyj4614] = Container{} - } else { - yyv4615 := &yyv4614[yyj4614] - yyv4615.CodecDecodeSelf(d) - } - - } - if yyrt4614 { - for ; yyj4614 < yyl4614; yyj4614++ { - yyv4614 = append(yyv4614, Container{}) - yyh4614.ElemContainerState(yyj4614) - if r.TryDecodeAsNil() { - yyv4614[yyj4614] = Container{} - } else { - yyv4616 := &yyv4614[yyj4614] - yyv4616.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4614 := 0 - for ; !r.CheckBreak(); yyj4614++ { - - if yyj4614 >= len(yyv4614) { - yyv4614 = append(yyv4614, Container{}) // var yyz4614 Container - yyc4614 = true - } - yyh4614.ElemContainerState(yyj4614) - if yyj4614 < len(yyv4614) { - if r.TryDecodeAsNil() { - yyv4614[yyj4614] = Container{} - } else { - yyv4617 := &yyv4614[yyj4614] - yyv4617.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4614 < len(yyv4614) { - yyv4614 = yyv4614[:yyj4614] - yyc4614 = true - } else if yyj4614 == 0 && yyv4614 == nil { - yyv4614 = []Container{} - yyc4614 = true - } - } - yyh4614.End() - if yyc4614 { - *v = yyv4614 - } -} - -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 _, yyv4618 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4619 := &yyv4618 - yy4619.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 - - yyv4620 := *v - yyh4620, yyl4620 := z.DecSliceHelperStart() - var yyc4620 bool - if yyl4620 == 0 { - if yyv4620 == nil { - yyv4620 = []LocalObjectReference{} - yyc4620 = true - } else if len(yyv4620) != 0 { - yyv4620 = yyv4620[:0] - yyc4620 = true - } - } else if yyl4620 > 0 { - var yyrr4620, yyrl4620 int - var yyrt4620 bool - if yyl4620 > cap(yyv4620) { - - yyrg4620 := len(yyv4620) > 0 - yyv24620 := yyv4620 - yyrl4620, yyrt4620 = z.DecInferLen(yyl4620, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4620 { - if yyrl4620 <= cap(yyv4620) { - yyv4620 = yyv4620[:yyrl4620] - } else { - yyv4620 = make([]LocalObjectReference, yyrl4620) - } - } else { - yyv4620 = make([]LocalObjectReference, yyrl4620) - } - yyc4620 = true - yyrr4620 = len(yyv4620) - if yyrg4620 { - copy(yyv4620, yyv24620) - } - } else if yyl4620 != len(yyv4620) { - yyv4620 = yyv4620[:yyl4620] - yyc4620 = true - } - yyj4620 := 0 - for ; yyj4620 < yyrr4620; yyj4620++ { - yyh4620.ElemContainerState(yyj4620) - if r.TryDecodeAsNil() { - yyv4620[yyj4620] = LocalObjectReference{} - } else { - yyv4621 := &yyv4620[yyj4620] - yyv4621.CodecDecodeSelf(d) - } - - } - if yyrt4620 { - for ; yyj4620 < yyl4620; yyj4620++ { - yyv4620 = append(yyv4620, LocalObjectReference{}) - yyh4620.ElemContainerState(yyj4620) - if r.TryDecodeAsNil() { - yyv4620[yyj4620] = LocalObjectReference{} - } else { - yyv4622 := &yyv4620[yyj4620] - yyv4622.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4620 := 0 - for ; !r.CheckBreak(); yyj4620++ { - - if yyj4620 >= len(yyv4620) { - yyv4620 = append(yyv4620, LocalObjectReference{}) // var yyz4620 LocalObjectReference - yyc4620 = true - } - yyh4620.ElemContainerState(yyj4620) - if yyj4620 < len(yyv4620) { - if r.TryDecodeAsNil() { - yyv4620[yyj4620] = LocalObjectReference{} - } else { - yyv4623 := &yyv4620[yyj4620] - yyv4623.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4620 < len(yyv4620) { - yyv4620 = yyv4620[:yyj4620] - yyc4620 = true - } else if yyj4620 == 0 && yyv4620 == nil { - yyv4620 = []LocalObjectReference{} - yyc4620 = true - } - } - yyh4620.End() - if yyc4620 { - *v = yyv4620 - } -} - -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 _, yyv4624 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4625 := &yyv4624 - yy4625.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 - - yyv4626 := *v - yyh4626, yyl4626 := z.DecSliceHelperStart() - var yyc4626 bool - if yyl4626 == 0 { - if yyv4626 == nil { - yyv4626 = []PodCondition{} - yyc4626 = true - } else if len(yyv4626) != 0 { - yyv4626 = yyv4626[:0] - yyc4626 = true - } - } else if yyl4626 > 0 { - var yyrr4626, yyrl4626 int - var yyrt4626 bool - if yyl4626 > cap(yyv4626) { - - yyrg4626 := len(yyv4626) > 0 - yyv24626 := yyv4626 - yyrl4626, yyrt4626 = z.DecInferLen(yyl4626, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4626 { - if yyrl4626 <= cap(yyv4626) { - yyv4626 = yyv4626[:yyrl4626] - } else { - yyv4626 = make([]PodCondition, yyrl4626) - } - } else { - yyv4626 = make([]PodCondition, yyrl4626) - } - yyc4626 = true - yyrr4626 = len(yyv4626) - if yyrg4626 { - copy(yyv4626, yyv24626) - } - } else if yyl4626 != len(yyv4626) { - yyv4626 = yyv4626[:yyl4626] - yyc4626 = true - } - yyj4626 := 0 - for ; yyj4626 < yyrr4626; yyj4626++ { - yyh4626.ElemContainerState(yyj4626) - if r.TryDecodeAsNil() { - yyv4626[yyj4626] = PodCondition{} - } else { - yyv4627 := &yyv4626[yyj4626] - yyv4627.CodecDecodeSelf(d) - } - - } - if yyrt4626 { - for ; yyj4626 < yyl4626; yyj4626++ { - yyv4626 = append(yyv4626, PodCondition{}) - yyh4626.ElemContainerState(yyj4626) - if r.TryDecodeAsNil() { - yyv4626[yyj4626] = PodCondition{} - } else { - yyv4628 := &yyv4626[yyj4626] - yyv4628.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4626 := 0 - for ; !r.CheckBreak(); yyj4626++ { - - if yyj4626 >= len(yyv4626) { - yyv4626 = append(yyv4626, PodCondition{}) // var yyz4626 PodCondition - yyc4626 = true - } - yyh4626.ElemContainerState(yyj4626) - if yyj4626 < len(yyv4626) { - if r.TryDecodeAsNil() { - yyv4626[yyj4626] = PodCondition{} - } else { - yyv4629 := &yyv4626[yyj4626] - yyv4629.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4626 < len(yyv4626) { - yyv4626 = yyv4626[:yyj4626] - yyc4626 = true - } else if yyj4626 == 0 && yyv4626 == nil { - yyv4626 = []PodCondition{} - yyc4626 = true - } - } - yyh4626.End() - if yyc4626 { - *v = yyv4626 - } -} - -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 _, yyv4630 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4631 := &yyv4630 - yy4631.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 - - yyv4632 := *v - yyh4632, yyl4632 := z.DecSliceHelperStart() - var yyc4632 bool - if yyl4632 == 0 { - if yyv4632 == nil { - yyv4632 = []ContainerStatus{} - yyc4632 = true - } else if len(yyv4632) != 0 { - yyv4632 = yyv4632[:0] - yyc4632 = true - } - } else if yyl4632 > 0 { - var yyrr4632, yyrl4632 int - var yyrt4632 bool - if yyl4632 > cap(yyv4632) { - - yyrg4632 := len(yyv4632) > 0 - yyv24632 := yyv4632 - yyrl4632, yyrt4632 = z.DecInferLen(yyl4632, z.DecBasicHandle().MaxInitLen, 120) - if yyrt4632 { - if yyrl4632 <= cap(yyv4632) { - yyv4632 = yyv4632[:yyrl4632] - } else { - yyv4632 = make([]ContainerStatus, yyrl4632) - } - } else { - yyv4632 = make([]ContainerStatus, yyrl4632) - } - yyc4632 = true - yyrr4632 = len(yyv4632) - if yyrg4632 { - copy(yyv4632, yyv24632) - } - } else if yyl4632 != len(yyv4632) { - yyv4632 = yyv4632[:yyl4632] - yyc4632 = true - } - yyj4632 := 0 - for ; yyj4632 < yyrr4632; yyj4632++ { - yyh4632.ElemContainerState(yyj4632) - if r.TryDecodeAsNil() { - yyv4632[yyj4632] = ContainerStatus{} - } else { - yyv4633 := &yyv4632[yyj4632] - yyv4633.CodecDecodeSelf(d) - } - - } - if yyrt4632 { - for ; yyj4632 < yyl4632; yyj4632++ { - yyv4632 = append(yyv4632, ContainerStatus{}) - yyh4632.ElemContainerState(yyj4632) - if r.TryDecodeAsNil() { - yyv4632[yyj4632] = ContainerStatus{} - } else { - yyv4634 := &yyv4632[yyj4632] - yyv4634.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4632 := 0 - for ; !r.CheckBreak(); yyj4632++ { - - if yyj4632 >= len(yyv4632) { - yyv4632 = append(yyv4632, ContainerStatus{}) // var yyz4632 ContainerStatus - yyc4632 = true - } - yyh4632.ElemContainerState(yyj4632) - if yyj4632 < len(yyv4632) { - if r.TryDecodeAsNil() { - yyv4632[yyj4632] = ContainerStatus{} - } else { - yyv4635 := &yyv4632[yyj4632] - yyv4635.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4632 < len(yyv4632) { - yyv4632 = yyv4632[:yyj4632] - yyc4632 = true - } else if yyj4632 == 0 && yyv4632 == nil { - yyv4632 = []ContainerStatus{} - yyc4632 = true - } - } - yyh4632.End() - if yyc4632 { - *v = yyv4632 - } -} - -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 _, yyv4636 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4637 := &yyv4636 - yy4637.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 - - yyv4638 := *v - yyh4638, yyl4638 := z.DecSliceHelperStart() - var yyc4638 bool - if yyl4638 == 0 { - if yyv4638 == nil { - yyv4638 = []Pod{} - yyc4638 = true - } else if len(yyv4638) != 0 { - yyv4638 = yyv4638[:0] - yyc4638 = true - } - } else if yyl4638 > 0 { - var yyrr4638, yyrl4638 int - var yyrt4638 bool - if yyl4638 > cap(yyv4638) { - - yyrg4638 := len(yyv4638) > 0 - yyv24638 := yyv4638 - yyrl4638, yyrt4638 = z.DecInferLen(yyl4638, z.DecBasicHandle().MaxInitLen, 664) - if yyrt4638 { - if yyrl4638 <= cap(yyv4638) { - yyv4638 = yyv4638[:yyrl4638] - } else { - yyv4638 = make([]Pod, yyrl4638) - } - } else { - yyv4638 = make([]Pod, yyrl4638) - } - yyc4638 = true - yyrr4638 = len(yyv4638) - if yyrg4638 { - copy(yyv4638, yyv24638) - } - } else if yyl4638 != len(yyv4638) { - yyv4638 = yyv4638[:yyl4638] - yyc4638 = true - } - yyj4638 := 0 - for ; yyj4638 < yyrr4638; yyj4638++ { - yyh4638.ElemContainerState(yyj4638) - if r.TryDecodeAsNil() { - yyv4638[yyj4638] = Pod{} - } else { - yyv4639 := &yyv4638[yyj4638] - yyv4639.CodecDecodeSelf(d) - } - - } - if yyrt4638 { - for ; yyj4638 < yyl4638; yyj4638++ { - yyv4638 = append(yyv4638, Pod{}) - yyh4638.ElemContainerState(yyj4638) - if r.TryDecodeAsNil() { - yyv4638[yyj4638] = Pod{} - } else { - yyv4640 := &yyv4638[yyj4638] - yyv4640.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4638 := 0 - for ; !r.CheckBreak(); yyj4638++ { - - if yyj4638 >= len(yyv4638) { - yyv4638 = append(yyv4638, Pod{}) // var yyz4638 Pod - yyc4638 = true - } - yyh4638.ElemContainerState(yyj4638) - if yyj4638 < len(yyv4638) { - if r.TryDecodeAsNil() { - yyv4638[yyj4638] = Pod{} - } else { - yyv4641 := &yyv4638[yyj4638] - yyv4641.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4638 < len(yyv4638) { - yyv4638 = yyv4638[:yyj4638] - yyc4638 = true - } else if yyj4638 == 0 && yyv4638 == nil { - yyv4638 = []Pod{} - yyc4638 = true - } - } - yyh4638.End() - if yyc4638 { - *v = yyv4638 - } -} - -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 _, yyv4642 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4643 := &yyv4642 - yy4643.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 - - yyv4644 := *v - yyh4644, yyl4644 := z.DecSliceHelperStart() - var yyc4644 bool - if yyl4644 == 0 { - if yyv4644 == nil { - yyv4644 = []PodTemplate{} - yyc4644 = true - } else if len(yyv4644) != 0 { - yyv4644 = yyv4644[:0] - yyc4644 = true - } - } else if yyl4644 > 0 { - var yyrr4644, yyrl4644 int - var yyrt4644 bool - if yyl4644 > cap(yyv4644) { - - yyrg4644 := len(yyv4644) > 0 - yyv24644 := yyv4644 - yyrl4644, yyrt4644 = z.DecInferLen(yyl4644, z.DecBasicHandle().MaxInitLen, 728) - if yyrt4644 { - if yyrl4644 <= cap(yyv4644) { - yyv4644 = yyv4644[:yyrl4644] - } else { - yyv4644 = make([]PodTemplate, yyrl4644) - } - } else { - yyv4644 = make([]PodTemplate, yyrl4644) - } - yyc4644 = true - yyrr4644 = len(yyv4644) - if yyrg4644 { - copy(yyv4644, yyv24644) - } - } else if yyl4644 != len(yyv4644) { - yyv4644 = yyv4644[:yyl4644] - yyc4644 = true - } - yyj4644 := 0 - for ; yyj4644 < yyrr4644; yyj4644++ { - yyh4644.ElemContainerState(yyj4644) - if r.TryDecodeAsNil() { - yyv4644[yyj4644] = PodTemplate{} - } else { - yyv4645 := &yyv4644[yyj4644] - yyv4645.CodecDecodeSelf(d) - } - - } - if yyrt4644 { - for ; yyj4644 < yyl4644; yyj4644++ { - yyv4644 = append(yyv4644, PodTemplate{}) - yyh4644.ElemContainerState(yyj4644) - if r.TryDecodeAsNil() { - yyv4644[yyj4644] = PodTemplate{} - } else { - yyv4646 := &yyv4644[yyj4644] - yyv4646.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4644 := 0 - for ; !r.CheckBreak(); yyj4644++ { - - if yyj4644 >= len(yyv4644) { - yyv4644 = append(yyv4644, PodTemplate{}) // var yyz4644 PodTemplate - yyc4644 = true - } - yyh4644.ElemContainerState(yyj4644) - if yyj4644 < len(yyv4644) { - if r.TryDecodeAsNil() { - yyv4644[yyj4644] = PodTemplate{} - } else { - yyv4647 := &yyv4644[yyj4644] - yyv4647.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4644 < len(yyv4644) { - yyv4644 = yyv4644[:yyj4644] - yyc4644 = true - } else if yyj4644 == 0 && yyv4644 == nil { - yyv4644 = []PodTemplate{} - yyc4644 = true - } - } - yyh4644.End() - if yyc4644 { - *v = yyv4644 - } -} - -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 _, yyv4648 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4649 := &yyv4648 - yy4649.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 - - yyv4650 := *v - yyh4650, yyl4650 := z.DecSliceHelperStart() - var yyc4650 bool - if yyl4650 == 0 { - if yyv4650 == nil { - yyv4650 = []ReplicationController{} - yyc4650 = true - } else if len(yyv4650) != 0 { - yyv4650 = yyv4650[:0] - yyc4650 = true - } - } else if yyl4650 > 0 { - var yyrr4650, yyrl4650 int - var yyrt4650 bool - if yyl4650 > cap(yyv4650) { - - yyrg4650 := len(yyv4650) > 0 - yyv24650 := yyv4650 - yyrl4650, yyrt4650 = z.DecInferLen(yyl4650, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4650 { - if yyrl4650 <= cap(yyv4650) { - yyv4650 = yyv4650[:yyrl4650] - } else { - yyv4650 = make([]ReplicationController, yyrl4650) - } - } else { - yyv4650 = make([]ReplicationController, yyrl4650) - } - yyc4650 = true - yyrr4650 = len(yyv4650) - if yyrg4650 { - copy(yyv4650, yyv24650) - } - } else if yyl4650 != len(yyv4650) { - yyv4650 = yyv4650[:yyl4650] - yyc4650 = true - } - yyj4650 := 0 - for ; yyj4650 < yyrr4650; yyj4650++ { - yyh4650.ElemContainerState(yyj4650) - if r.TryDecodeAsNil() { - yyv4650[yyj4650] = ReplicationController{} - } else { - yyv4651 := &yyv4650[yyj4650] - yyv4651.CodecDecodeSelf(d) - } - - } - if yyrt4650 { - for ; yyj4650 < yyl4650; yyj4650++ { - yyv4650 = append(yyv4650, ReplicationController{}) - yyh4650.ElemContainerState(yyj4650) - if r.TryDecodeAsNil() { - yyv4650[yyj4650] = ReplicationController{} - } else { - yyv4652 := &yyv4650[yyj4650] - yyv4652.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4650 := 0 - for ; !r.CheckBreak(); yyj4650++ { - - if yyj4650 >= len(yyv4650) { - yyv4650 = append(yyv4650, ReplicationController{}) // var yyz4650 ReplicationController - yyc4650 = true - } - yyh4650.ElemContainerState(yyj4650) - if yyj4650 < len(yyv4650) { - if r.TryDecodeAsNil() { - yyv4650[yyj4650] = ReplicationController{} - } else { - yyv4653 := &yyv4650[yyj4650] - yyv4653.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4650 < len(yyv4650) { - yyv4650 = yyv4650[:yyj4650] - yyc4650 = true - } else if yyj4650 == 0 && yyv4650 == nil { - yyv4650 = []ReplicationController{} - yyc4650 = true - } - } - yyh4650.End() - if yyc4650 { - *v = yyv4650 - } -} - -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 _, yyv4654 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4655 := &yyv4654 - yy4655.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 - - yyv4656 := *v - yyh4656, yyl4656 := z.DecSliceHelperStart() - var yyc4656 bool - if yyl4656 == 0 { - if yyv4656 == nil { - yyv4656 = []LoadBalancerIngress{} - yyc4656 = true - } else if len(yyv4656) != 0 { - yyv4656 = yyv4656[:0] - yyc4656 = true - } - } else if yyl4656 > 0 { - var yyrr4656, yyrl4656 int - var yyrt4656 bool - if yyl4656 > cap(yyv4656) { - - yyrg4656 := len(yyv4656) > 0 - yyv24656 := yyv4656 - yyrl4656, yyrt4656 = z.DecInferLen(yyl4656, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4656 { - if yyrl4656 <= cap(yyv4656) { - yyv4656 = yyv4656[:yyrl4656] - } else { - yyv4656 = make([]LoadBalancerIngress, yyrl4656) - } - } else { - yyv4656 = make([]LoadBalancerIngress, yyrl4656) - } - yyc4656 = true - yyrr4656 = len(yyv4656) - if yyrg4656 { - copy(yyv4656, yyv24656) - } - } else if yyl4656 != len(yyv4656) { - yyv4656 = yyv4656[:yyl4656] - yyc4656 = true - } - yyj4656 := 0 - for ; yyj4656 < yyrr4656; yyj4656++ { - yyh4656.ElemContainerState(yyj4656) - if r.TryDecodeAsNil() { - yyv4656[yyj4656] = LoadBalancerIngress{} - } else { - yyv4657 := &yyv4656[yyj4656] - yyv4657.CodecDecodeSelf(d) - } - - } - if yyrt4656 { - for ; yyj4656 < yyl4656; yyj4656++ { - yyv4656 = append(yyv4656, LoadBalancerIngress{}) - yyh4656.ElemContainerState(yyj4656) - if r.TryDecodeAsNil() { - yyv4656[yyj4656] = LoadBalancerIngress{} - } else { - yyv4658 := &yyv4656[yyj4656] - yyv4658.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4656 := 0 - for ; !r.CheckBreak(); yyj4656++ { - - if yyj4656 >= len(yyv4656) { - yyv4656 = append(yyv4656, LoadBalancerIngress{}) // var yyz4656 LoadBalancerIngress - yyc4656 = true - } - yyh4656.ElemContainerState(yyj4656) - if yyj4656 < len(yyv4656) { - if r.TryDecodeAsNil() { - yyv4656[yyj4656] = LoadBalancerIngress{} - } else { - yyv4659 := &yyv4656[yyj4656] - yyv4659.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4656 < len(yyv4656) { - yyv4656 = yyv4656[:yyj4656] - yyc4656 = true - } else if yyj4656 == 0 && yyv4656 == nil { - yyv4656 = []LoadBalancerIngress{} - yyc4656 = true - } - } - yyh4656.End() - if yyc4656 { - *v = yyv4656 - } -} - -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 _, yyv4660 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4661 := &yyv4660 - yy4661.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 - - yyv4662 := *v - yyh4662, yyl4662 := z.DecSliceHelperStart() - var yyc4662 bool - if yyl4662 == 0 { - if yyv4662 == nil { - yyv4662 = []ServicePort{} - yyc4662 = true - } else if len(yyv4662) != 0 { - yyv4662 = yyv4662[:0] - yyc4662 = true - } - } else if yyl4662 > 0 { - var yyrr4662, yyrl4662 int - var yyrt4662 bool - if yyl4662 > cap(yyv4662) { - - yyrg4662 := len(yyv4662) > 0 - yyv24662 := yyv4662 - yyrl4662, yyrt4662 = z.DecInferLen(yyl4662, z.DecBasicHandle().MaxInitLen, 80) - if yyrt4662 { - if yyrl4662 <= cap(yyv4662) { - yyv4662 = yyv4662[:yyrl4662] - } else { - yyv4662 = make([]ServicePort, yyrl4662) - } - } else { - yyv4662 = make([]ServicePort, yyrl4662) - } - yyc4662 = true - yyrr4662 = len(yyv4662) - if yyrg4662 { - copy(yyv4662, yyv24662) - } - } else if yyl4662 != len(yyv4662) { - yyv4662 = yyv4662[:yyl4662] - yyc4662 = true - } - yyj4662 := 0 - for ; yyj4662 < yyrr4662; yyj4662++ { - yyh4662.ElemContainerState(yyj4662) - if r.TryDecodeAsNil() { - yyv4662[yyj4662] = ServicePort{} - } else { - yyv4663 := &yyv4662[yyj4662] - yyv4663.CodecDecodeSelf(d) - } - - } - if yyrt4662 { - for ; yyj4662 < yyl4662; yyj4662++ { - yyv4662 = append(yyv4662, ServicePort{}) - yyh4662.ElemContainerState(yyj4662) - if r.TryDecodeAsNil() { - yyv4662[yyj4662] = ServicePort{} - } else { - yyv4664 := &yyv4662[yyj4662] - yyv4664.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4662 := 0 - for ; !r.CheckBreak(); yyj4662++ { - - if yyj4662 >= len(yyv4662) { - yyv4662 = append(yyv4662, ServicePort{}) // var yyz4662 ServicePort - yyc4662 = true - } - yyh4662.ElemContainerState(yyj4662) - if yyj4662 < len(yyv4662) { - if r.TryDecodeAsNil() { - yyv4662[yyj4662] = ServicePort{} - } else { - yyv4665 := &yyv4662[yyj4662] - yyv4665.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4662 < len(yyv4662) { - yyv4662 = yyv4662[:yyj4662] - yyc4662 = true - } else if yyj4662 == 0 && yyv4662 == nil { - yyv4662 = []ServicePort{} - yyc4662 = true - } - } - yyh4662.End() - if yyc4662 { - *v = yyv4662 - } -} - -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 _, yyv4666 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4667 := &yyv4666 - yy4667.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 - - yyv4668 := *v - yyh4668, yyl4668 := z.DecSliceHelperStart() - var yyc4668 bool - if yyl4668 == 0 { - if yyv4668 == nil { - yyv4668 = []Service{} - yyc4668 = true - } else if len(yyv4668) != 0 { - yyv4668 = yyv4668[:0] - yyc4668 = true - } - } else if yyl4668 > 0 { - var yyrr4668, yyrl4668 int - var yyrt4668 bool - if yyl4668 > cap(yyv4668) { - - yyrg4668 := len(yyv4668) > 0 - yyv24668 := yyv4668 - yyrl4668, yyrt4668 = z.DecInferLen(yyl4668, z.DecBasicHandle().MaxInitLen, 464) - if yyrt4668 { - if yyrl4668 <= cap(yyv4668) { - yyv4668 = yyv4668[:yyrl4668] - } else { - yyv4668 = make([]Service, yyrl4668) - } - } else { - yyv4668 = make([]Service, yyrl4668) - } - yyc4668 = true - yyrr4668 = len(yyv4668) - if yyrg4668 { - copy(yyv4668, yyv24668) - } - } else if yyl4668 != len(yyv4668) { - yyv4668 = yyv4668[:yyl4668] - yyc4668 = true - } - yyj4668 := 0 - for ; yyj4668 < yyrr4668; yyj4668++ { - yyh4668.ElemContainerState(yyj4668) - if r.TryDecodeAsNil() { - yyv4668[yyj4668] = Service{} - } else { - yyv4669 := &yyv4668[yyj4668] - yyv4669.CodecDecodeSelf(d) - } - - } - if yyrt4668 { - for ; yyj4668 < yyl4668; yyj4668++ { - yyv4668 = append(yyv4668, Service{}) - yyh4668.ElemContainerState(yyj4668) - if r.TryDecodeAsNil() { - yyv4668[yyj4668] = Service{} - } else { - yyv4670 := &yyv4668[yyj4668] - yyv4670.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4668 := 0 - for ; !r.CheckBreak(); yyj4668++ { - - if yyj4668 >= len(yyv4668) { - yyv4668 = append(yyv4668, Service{}) // var yyz4668 Service - yyc4668 = true - } - yyh4668.ElemContainerState(yyj4668) - if yyj4668 < len(yyv4668) { - if r.TryDecodeAsNil() { - yyv4668[yyj4668] = Service{} - } else { - yyv4671 := &yyv4668[yyj4668] - yyv4671.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4668 < len(yyv4668) { - yyv4668 = yyv4668[:yyj4668] - yyc4668 = true - } else if yyj4668 == 0 && yyv4668 == nil { - yyv4668 = []Service{} - yyc4668 = true - } - } - yyh4668.End() - if yyc4668 { - *v = yyv4668 - } -} - -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 _, yyv4672 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4673 := &yyv4672 - yy4673.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 - - yyv4674 := *v - yyh4674, yyl4674 := z.DecSliceHelperStart() - var yyc4674 bool - if yyl4674 == 0 { - if yyv4674 == nil { - yyv4674 = []ObjectReference{} - yyc4674 = true - } else if len(yyv4674) != 0 { - yyv4674 = yyv4674[:0] - yyc4674 = true - } - } else if yyl4674 > 0 { - var yyrr4674, yyrl4674 int - var yyrt4674 bool - if yyl4674 > cap(yyv4674) { - - yyrg4674 := len(yyv4674) > 0 - yyv24674 := yyv4674 - yyrl4674, yyrt4674 = z.DecInferLen(yyl4674, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4674 { - if yyrl4674 <= cap(yyv4674) { - yyv4674 = yyv4674[:yyrl4674] - } else { - yyv4674 = make([]ObjectReference, yyrl4674) - } - } else { - yyv4674 = make([]ObjectReference, yyrl4674) - } - yyc4674 = true - yyrr4674 = len(yyv4674) - if yyrg4674 { - copy(yyv4674, yyv24674) - } - } else if yyl4674 != len(yyv4674) { - yyv4674 = yyv4674[:yyl4674] - yyc4674 = true - } - yyj4674 := 0 - for ; yyj4674 < yyrr4674; yyj4674++ { - yyh4674.ElemContainerState(yyj4674) - if r.TryDecodeAsNil() { - yyv4674[yyj4674] = ObjectReference{} - } else { - yyv4675 := &yyv4674[yyj4674] - yyv4675.CodecDecodeSelf(d) - } - - } - if yyrt4674 { - for ; yyj4674 < yyl4674; yyj4674++ { - yyv4674 = append(yyv4674, ObjectReference{}) - yyh4674.ElemContainerState(yyj4674) - if r.TryDecodeAsNil() { - yyv4674[yyj4674] = ObjectReference{} - } else { - yyv4676 := &yyv4674[yyj4674] - yyv4676.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4674 := 0 - for ; !r.CheckBreak(); yyj4674++ { - - if yyj4674 >= len(yyv4674) { - yyv4674 = append(yyv4674, ObjectReference{}) // var yyz4674 ObjectReference - yyc4674 = true - } - yyh4674.ElemContainerState(yyj4674) - if yyj4674 < len(yyv4674) { - if r.TryDecodeAsNil() { - yyv4674[yyj4674] = ObjectReference{} - } else { - yyv4677 := &yyv4674[yyj4674] - yyv4677.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4674 < len(yyv4674) { - yyv4674 = yyv4674[:yyj4674] - yyc4674 = true - } else if yyj4674 == 0 && yyv4674 == nil { - yyv4674 = []ObjectReference{} - yyc4674 = true - } - } - yyh4674.End() - if yyc4674 { - *v = yyv4674 - } -} - -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 _, yyv4678 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4679 := &yyv4678 - yy4679.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 - - yyv4680 := *v - yyh4680, yyl4680 := z.DecSliceHelperStart() - var yyc4680 bool - if yyl4680 == 0 { - if yyv4680 == nil { - yyv4680 = []ServiceAccount{} - yyc4680 = true - } else if len(yyv4680) != 0 { - yyv4680 = yyv4680[:0] - yyc4680 = true - } - } else if yyl4680 > 0 { - var yyrr4680, yyrl4680 int - var yyrt4680 bool - if yyl4680 > cap(yyv4680) { - - yyrg4680 := len(yyv4680) > 0 - yyv24680 := yyv4680 - yyrl4680, yyrt4680 = z.DecInferLen(yyl4680, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4680 { - if yyrl4680 <= cap(yyv4680) { - yyv4680 = yyv4680[:yyrl4680] - } else { - yyv4680 = make([]ServiceAccount, yyrl4680) - } - } else { - yyv4680 = make([]ServiceAccount, yyrl4680) - } - yyc4680 = true - yyrr4680 = len(yyv4680) - if yyrg4680 { - copy(yyv4680, yyv24680) - } - } else if yyl4680 != len(yyv4680) { - yyv4680 = yyv4680[:yyl4680] - yyc4680 = true - } - yyj4680 := 0 - for ; yyj4680 < yyrr4680; yyj4680++ { - yyh4680.ElemContainerState(yyj4680) - if r.TryDecodeAsNil() { - yyv4680[yyj4680] = ServiceAccount{} - } else { - yyv4681 := &yyv4680[yyj4680] - yyv4681.CodecDecodeSelf(d) - } - - } - if yyrt4680 { - for ; yyj4680 < yyl4680; yyj4680++ { - yyv4680 = append(yyv4680, ServiceAccount{}) - yyh4680.ElemContainerState(yyj4680) - if r.TryDecodeAsNil() { - yyv4680[yyj4680] = ServiceAccount{} - } else { - yyv4682 := &yyv4680[yyj4680] - yyv4682.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4680 := 0 - for ; !r.CheckBreak(); yyj4680++ { - - if yyj4680 >= len(yyv4680) { - yyv4680 = append(yyv4680, ServiceAccount{}) // var yyz4680 ServiceAccount - yyc4680 = true - } - yyh4680.ElemContainerState(yyj4680) - if yyj4680 < len(yyv4680) { - if r.TryDecodeAsNil() { - yyv4680[yyj4680] = ServiceAccount{} - } else { - yyv4683 := &yyv4680[yyj4680] - yyv4683.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4680 < len(yyv4680) { - yyv4680 = yyv4680[:yyj4680] - yyc4680 = true - } else if yyj4680 == 0 && yyv4680 == nil { - yyv4680 = []ServiceAccount{} - yyc4680 = true - } - } - yyh4680.End() - if yyc4680 { - *v = yyv4680 - } -} - -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 _, yyv4684 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4685 := &yyv4684 - yy4685.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 - - yyv4686 := *v - yyh4686, yyl4686 := z.DecSliceHelperStart() - var yyc4686 bool - if yyl4686 == 0 { - if yyv4686 == nil { - yyv4686 = []EndpointSubset{} - yyc4686 = true - } else if len(yyv4686) != 0 { - yyv4686 = yyv4686[:0] - yyc4686 = true - } - } else if yyl4686 > 0 { - var yyrr4686, yyrl4686 int - var yyrt4686 bool - if yyl4686 > cap(yyv4686) { - - yyrg4686 := len(yyv4686) > 0 - yyv24686 := yyv4686 - yyrl4686, yyrt4686 = z.DecInferLen(yyl4686, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4686 { - if yyrl4686 <= cap(yyv4686) { - yyv4686 = yyv4686[:yyrl4686] - } else { - yyv4686 = make([]EndpointSubset, yyrl4686) - } - } else { - yyv4686 = make([]EndpointSubset, yyrl4686) - } - yyc4686 = true - yyrr4686 = len(yyv4686) - if yyrg4686 { - copy(yyv4686, yyv24686) - } - } else if yyl4686 != len(yyv4686) { - yyv4686 = yyv4686[:yyl4686] - yyc4686 = true - } - yyj4686 := 0 - for ; yyj4686 < yyrr4686; yyj4686++ { - yyh4686.ElemContainerState(yyj4686) - if r.TryDecodeAsNil() { - yyv4686[yyj4686] = EndpointSubset{} - } else { - yyv4687 := &yyv4686[yyj4686] - yyv4687.CodecDecodeSelf(d) - } - - } - if yyrt4686 { - for ; yyj4686 < yyl4686; yyj4686++ { - yyv4686 = append(yyv4686, EndpointSubset{}) - yyh4686.ElemContainerState(yyj4686) - if r.TryDecodeAsNil() { - yyv4686[yyj4686] = EndpointSubset{} - } else { - yyv4688 := &yyv4686[yyj4686] - yyv4688.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4686 := 0 - for ; !r.CheckBreak(); yyj4686++ { - - if yyj4686 >= len(yyv4686) { - yyv4686 = append(yyv4686, EndpointSubset{}) // var yyz4686 EndpointSubset - yyc4686 = true - } - yyh4686.ElemContainerState(yyj4686) - if yyj4686 < len(yyv4686) { - if r.TryDecodeAsNil() { - yyv4686[yyj4686] = EndpointSubset{} - } else { - yyv4689 := &yyv4686[yyj4686] - yyv4689.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4686 < len(yyv4686) { - yyv4686 = yyv4686[:yyj4686] - yyc4686 = true - } else if yyj4686 == 0 && yyv4686 == nil { - yyv4686 = []EndpointSubset{} - yyc4686 = true - } - } - yyh4686.End() - if yyc4686 { - *v = yyv4686 - } -} - -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 _, yyv4690 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4691 := &yyv4690 - yy4691.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 - - yyv4692 := *v - yyh4692, yyl4692 := z.DecSliceHelperStart() - var yyc4692 bool - if yyl4692 == 0 { - if yyv4692 == nil { - yyv4692 = []EndpointAddress{} - yyc4692 = true - } else if len(yyv4692) != 0 { - yyv4692 = yyv4692[:0] - yyc4692 = true - } - } else if yyl4692 > 0 { - var yyrr4692, yyrl4692 int - var yyrt4692 bool - if yyl4692 > cap(yyv4692) { - - yyrg4692 := len(yyv4692) > 0 - yyv24692 := yyv4692 - yyrl4692, yyrt4692 = z.DecInferLen(yyl4692, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4692 { - if yyrl4692 <= cap(yyv4692) { - yyv4692 = yyv4692[:yyrl4692] - } else { - yyv4692 = make([]EndpointAddress, yyrl4692) - } - } else { - yyv4692 = make([]EndpointAddress, yyrl4692) - } - yyc4692 = true - yyrr4692 = len(yyv4692) - if yyrg4692 { - copy(yyv4692, yyv24692) - } - } else if yyl4692 != len(yyv4692) { - yyv4692 = yyv4692[:yyl4692] - yyc4692 = true - } - yyj4692 := 0 - for ; yyj4692 < yyrr4692; yyj4692++ { - yyh4692.ElemContainerState(yyj4692) - if r.TryDecodeAsNil() { - yyv4692[yyj4692] = EndpointAddress{} - } else { - yyv4693 := &yyv4692[yyj4692] - yyv4693.CodecDecodeSelf(d) - } - - } - if yyrt4692 { - for ; yyj4692 < yyl4692; yyj4692++ { - yyv4692 = append(yyv4692, EndpointAddress{}) - yyh4692.ElemContainerState(yyj4692) - if r.TryDecodeAsNil() { - yyv4692[yyj4692] = EndpointAddress{} - } else { - yyv4694 := &yyv4692[yyj4692] - yyv4694.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4692 := 0 - for ; !r.CheckBreak(); yyj4692++ { - - if yyj4692 >= len(yyv4692) { - yyv4692 = append(yyv4692, EndpointAddress{}) // var yyz4692 EndpointAddress - yyc4692 = true - } - yyh4692.ElemContainerState(yyj4692) - if yyj4692 < len(yyv4692) { - if r.TryDecodeAsNil() { - yyv4692[yyj4692] = EndpointAddress{} - } else { - yyv4695 := &yyv4692[yyj4692] - yyv4695.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4692 < len(yyv4692) { - yyv4692 = yyv4692[:yyj4692] - yyc4692 = true - } else if yyj4692 == 0 && yyv4692 == nil { - yyv4692 = []EndpointAddress{} - yyc4692 = true - } - } - yyh4692.End() - if yyc4692 { - *v = yyv4692 - } -} - -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 _, yyv4696 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4697 := &yyv4696 - yy4697.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 - - yyv4698 := *v - yyh4698, yyl4698 := z.DecSliceHelperStart() - var yyc4698 bool - if yyl4698 == 0 { - if yyv4698 == nil { - yyv4698 = []EndpointPort{} - yyc4698 = true - } else if len(yyv4698) != 0 { - yyv4698 = yyv4698[:0] - yyc4698 = true - } - } else if yyl4698 > 0 { - var yyrr4698, yyrl4698 int - var yyrt4698 bool - if yyl4698 > cap(yyv4698) { - - yyrg4698 := len(yyv4698) > 0 - yyv24698 := yyv4698 - yyrl4698, yyrt4698 = z.DecInferLen(yyl4698, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4698 { - if yyrl4698 <= cap(yyv4698) { - yyv4698 = yyv4698[:yyrl4698] - } else { - yyv4698 = make([]EndpointPort, yyrl4698) - } - } else { - yyv4698 = make([]EndpointPort, yyrl4698) - } - yyc4698 = true - yyrr4698 = len(yyv4698) - if yyrg4698 { - copy(yyv4698, yyv24698) - } - } else if yyl4698 != len(yyv4698) { - yyv4698 = yyv4698[:yyl4698] - yyc4698 = true - } - yyj4698 := 0 - for ; yyj4698 < yyrr4698; yyj4698++ { - yyh4698.ElemContainerState(yyj4698) - if r.TryDecodeAsNil() { - yyv4698[yyj4698] = EndpointPort{} - } else { - yyv4699 := &yyv4698[yyj4698] - yyv4699.CodecDecodeSelf(d) - } - - } - if yyrt4698 { - for ; yyj4698 < yyl4698; yyj4698++ { - yyv4698 = append(yyv4698, EndpointPort{}) - yyh4698.ElemContainerState(yyj4698) - if r.TryDecodeAsNil() { - yyv4698[yyj4698] = EndpointPort{} - } else { - yyv4700 := &yyv4698[yyj4698] - yyv4700.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4698 := 0 - for ; !r.CheckBreak(); yyj4698++ { - - if yyj4698 >= len(yyv4698) { - yyv4698 = append(yyv4698, EndpointPort{}) // var yyz4698 EndpointPort - yyc4698 = true - } - yyh4698.ElemContainerState(yyj4698) - if yyj4698 < len(yyv4698) { - if r.TryDecodeAsNil() { - yyv4698[yyj4698] = EndpointPort{} - } else { - yyv4701 := &yyv4698[yyj4698] - yyv4701.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4698 < len(yyv4698) { - yyv4698 = yyv4698[:yyj4698] - yyc4698 = true - } else if yyj4698 == 0 && yyv4698 == nil { - yyv4698 = []EndpointPort{} - yyc4698 = true - } - } - yyh4698.End() - if yyc4698 { - *v = yyv4698 - } -} - -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 _, yyv4702 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4703 := &yyv4702 - yy4703.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 - - yyv4704 := *v - yyh4704, yyl4704 := z.DecSliceHelperStart() - var yyc4704 bool - if yyl4704 == 0 { - if yyv4704 == nil { - yyv4704 = []Endpoints{} - yyc4704 = true - } else if len(yyv4704) != 0 { - yyv4704 = yyv4704[:0] - yyc4704 = true - } - } else if yyl4704 > 0 { - var yyrr4704, yyrl4704 int - var yyrt4704 bool - if yyl4704 > cap(yyv4704) { - - yyrg4704 := len(yyv4704) > 0 - yyv24704 := yyv4704 - yyrl4704, yyrt4704 = z.DecInferLen(yyl4704, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4704 { - if yyrl4704 <= cap(yyv4704) { - yyv4704 = yyv4704[:yyrl4704] - } else { - yyv4704 = make([]Endpoints, yyrl4704) - } - } else { - yyv4704 = make([]Endpoints, yyrl4704) - } - yyc4704 = true - yyrr4704 = len(yyv4704) - if yyrg4704 { - copy(yyv4704, yyv24704) - } - } else if yyl4704 != len(yyv4704) { - yyv4704 = yyv4704[:yyl4704] - yyc4704 = true - } - yyj4704 := 0 - for ; yyj4704 < yyrr4704; yyj4704++ { - yyh4704.ElemContainerState(yyj4704) - if r.TryDecodeAsNil() { - yyv4704[yyj4704] = Endpoints{} - } else { - yyv4705 := &yyv4704[yyj4704] - yyv4705.CodecDecodeSelf(d) - } - - } - if yyrt4704 { - for ; yyj4704 < yyl4704; yyj4704++ { - yyv4704 = append(yyv4704, Endpoints{}) - yyh4704.ElemContainerState(yyj4704) - if r.TryDecodeAsNil() { - yyv4704[yyj4704] = Endpoints{} - } else { - yyv4706 := &yyv4704[yyj4704] - yyv4706.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4704 := 0 - for ; !r.CheckBreak(); yyj4704++ { - - if yyj4704 >= len(yyv4704) { - yyv4704 = append(yyv4704, Endpoints{}) // var yyz4704 Endpoints - yyc4704 = true - } - yyh4704.ElemContainerState(yyj4704) - if yyj4704 < len(yyv4704) { - if r.TryDecodeAsNil() { - yyv4704[yyj4704] = Endpoints{} - } else { - yyv4707 := &yyv4704[yyj4704] - yyv4707.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4704 < len(yyv4704) { - yyv4704 = yyv4704[:yyj4704] - yyc4704 = true - } else if yyj4704 == 0 && yyv4704 == nil { - yyv4704 = []Endpoints{} - yyc4704 = true - } - } - yyh4704.End() - if yyc4704 { - *v = yyv4704 - } -} - -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 _, yyv4708 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4709 := &yyv4708 - yy4709.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 - - yyv4710 := *v - yyh4710, yyl4710 := z.DecSliceHelperStart() - var yyc4710 bool - if yyl4710 == 0 { - if yyv4710 == nil { - yyv4710 = []NodeCondition{} - yyc4710 = true - } else if len(yyv4710) != 0 { - yyv4710 = yyv4710[:0] - yyc4710 = true - } - } else if yyl4710 > 0 { - var yyrr4710, yyrl4710 int - var yyrt4710 bool - if yyl4710 > cap(yyv4710) { - - yyrg4710 := len(yyv4710) > 0 - yyv24710 := yyv4710 - yyrl4710, yyrt4710 = z.DecInferLen(yyl4710, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4710 { - if yyrl4710 <= cap(yyv4710) { - yyv4710 = yyv4710[:yyrl4710] - } else { - yyv4710 = make([]NodeCondition, yyrl4710) - } - } else { - yyv4710 = make([]NodeCondition, yyrl4710) - } - yyc4710 = true - yyrr4710 = len(yyv4710) - if yyrg4710 { - copy(yyv4710, yyv24710) - } - } else if yyl4710 != len(yyv4710) { - yyv4710 = yyv4710[:yyl4710] - yyc4710 = true - } - yyj4710 := 0 - for ; yyj4710 < yyrr4710; yyj4710++ { - yyh4710.ElemContainerState(yyj4710) - if r.TryDecodeAsNil() { - yyv4710[yyj4710] = NodeCondition{} - } else { - yyv4711 := &yyv4710[yyj4710] - yyv4711.CodecDecodeSelf(d) - } - - } - if yyrt4710 { - for ; yyj4710 < yyl4710; yyj4710++ { - yyv4710 = append(yyv4710, NodeCondition{}) - yyh4710.ElemContainerState(yyj4710) - if r.TryDecodeAsNil() { - yyv4710[yyj4710] = NodeCondition{} - } else { - yyv4712 := &yyv4710[yyj4710] - yyv4712.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4710 := 0 - for ; !r.CheckBreak(); yyj4710++ { - - if yyj4710 >= len(yyv4710) { - yyv4710 = append(yyv4710, NodeCondition{}) // var yyz4710 NodeCondition - yyc4710 = true - } - yyh4710.ElemContainerState(yyj4710) - if yyj4710 < len(yyv4710) { - if r.TryDecodeAsNil() { - yyv4710[yyj4710] = NodeCondition{} - } else { - yyv4713 := &yyv4710[yyj4710] - yyv4713.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4710 < len(yyv4710) { - yyv4710 = yyv4710[:yyj4710] - yyc4710 = true - } else if yyj4710 == 0 && yyv4710 == nil { - yyv4710 = []NodeCondition{} - yyc4710 = true - } - } - yyh4710.End() - if yyc4710 { - *v = yyv4710 - } -} - -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 _, yyv4714 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4715 := &yyv4714 - yy4715.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 - - yyv4716 := *v - yyh4716, yyl4716 := z.DecSliceHelperStart() - var yyc4716 bool - if yyl4716 == 0 { - if yyv4716 == nil { - yyv4716 = []NodeAddress{} - yyc4716 = true - } else if len(yyv4716) != 0 { - yyv4716 = yyv4716[:0] - yyc4716 = true - } - } else if yyl4716 > 0 { - var yyrr4716, yyrl4716 int - var yyrt4716 bool - if yyl4716 > cap(yyv4716) { - - yyrg4716 := len(yyv4716) > 0 - yyv24716 := yyv4716 - yyrl4716, yyrt4716 = z.DecInferLen(yyl4716, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4716 { - if yyrl4716 <= cap(yyv4716) { - yyv4716 = yyv4716[:yyrl4716] - } else { - yyv4716 = make([]NodeAddress, yyrl4716) - } - } else { - yyv4716 = make([]NodeAddress, yyrl4716) - } - yyc4716 = true - yyrr4716 = len(yyv4716) - if yyrg4716 { - copy(yyv4716, yyv24716) - } - } else if yyl4716 != len(yyv4716) { - yyv4716 = yyv4716[:yyl4716] - yyc4716 = true - } - yyj4716 := 0 - for ; yyj4716 < yyrr4716; yyj4716++ { - yyh4716.ElemContainerState(yyj4716) - if r.TryDecodeAsNil() { - yyv4716[yyj4716] = NodeAddress{} - } else { - yyv4717 := &yyv4716[yyj4716] - yyv4717.CodecDecodeSelf(d) - } - - } - if yyrt4716 { - for ; yyj4716 < yyl4716; yyj4716++ { - yyv4716 = append(yyv4716, NodeAddress{}) - yyh4716.ElemContainerState(yyj4716) - if r.TryDecodeAsNil() { - yyv4716[yyj4716] = NodeAddress{} - } else { - yyv4718 := &yyv4716[yyj4716] - yyv4718.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4716 := 0 - for ; !r.CheckBreak(); yyj4716++ { - - if yyj4716 >= len(yyv4716) { - yyv4716 = append(yyv4716, NodeAddress{}) // var yyz4716 NodeAddress - yyc4716 = true - } - yyh4716.ElemContainerState(yyj4716) - if yyj4716 < len(yyv4716) { - if r.TryDecodeAsNil() { - yyv4716[yyj4716] = NodeAddress{} - } else { - yyv4719 := &yyv4716[yyj4716] - yyv4719.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4716 < len(yyv4716) { - yyv4716 = yyv4716[:yyj4716] - yyc4716 = true - } else if yyj4716 == 0 && yyv4716 == nil { - yyv4716 = []NodeAddress{} - yyc4716 = true - } - } - yyh4716.End() - if yyc4716 { - *v = yyv4716 - } -} - -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 _, yyv4720 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4721 := &yyv4720 - yy4721.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 - - yyv4722 := *v - yyh4722, yyl4722 := z.DecSliceHelperStart() - var yyc4722 bool - if yyl4722 == 0 { - if yyv4722 == nil { - yyv4722 = []ContainerImage{} - yyc4722 = true - } else if len(yyv4722) != 0 { - yyv4722 = yyv4722[:0] - yyc4722 = true - } - } else if yyl4722 > 0 { - var yyrr4722, yyrl4722 int - var yyrt4722 bool - if yyl4722 > cap(yyv4722) { - - yyrg4722 := len(yyv4722) > 0 - yyv24722 := yyv4722 - yyrl4722, yyrt4722 = z.DecInferLen(yyl4722, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4722 { - if yyrl4722 <= cap(yyv4722) { - yyv4722 = yyv4722[:yyrl4722] - } else { - yyv4722 = make([]ContainerImage, yyrl4722) - } - } else { - yyv4722 = make([]ContainerImage, yyrl4722) - } - yyc4722 = true - yyrr4722 = len(yyv4722) - if yyrg4722 { - copy(yyv4722, yyv24722) - } - } else if yyl4722 != len(yyv4722) { - yyv4722 = yyv4722[:yyl4722] - yyc4722 = true - } - yyj4722 := 0 - for ; yyj4722 < yyrr4722; yyj4722++ { - yyh4722.ElemContainerState(yyj4722) - if r.TryDecodeAsNil() { - yyv4722[yyj4722] = ContainerImage{} - } else { - yyv4723 := &yyv4722[yyj4722] - yyv4723.CodecDecodeSelf(d) - } - - } - if yyrt4722 { - for ; yyj4722 < yyl4722; yyj4722++ { - yyv4722 = append(yyv4722, ContainerImage{}) - yyh4722.ElemContainerState(yyj4722) - if r.TryDecodeAsNil() { - yyv4722[yyj4722] = ContainerImage{} - } else { - yyv4724 := &yyv4722[yyj4722] - yyv4724.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4722 := 0 - for ; !r.CheckBreak(); yyj4722++ { - - if yyj4722 >= len(yyv4722) { - yyv4722 = append(yyv4722, ContainerImage{}) // var yyz4722 ContainerImage - yyc4722 = true - } - yyh4722.ElemContainerState(yyj4722) - if yyj4722 < len(yyv4722) { - if r.TryDecodeAsNil() { - yyv4722[yyj4722] = ContainerImage{} - } else { - yyv4725 := &yyv4722[yyj4722] - yyv4725.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4722 < len(yyv4722) { - yyv4722 = yyv4722[:yyj4722] - yyc4722 = true - } else if yyj4722 == 0 && yyv4722 == nil { - yyv4722 = []ContainerImage{} - yyc4722 = true - } - } - yyh4722.End() - if yyc4722 { - *v = yyv4722 - } -} - -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 _, yyv4726 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4726.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 - - yyv4727 := *v - yyh4727, yyl4727 := z.DecSliceHelperStart() - var yyc4727 bool - if yyl4727 == 0 { - if yyv4727 == nil { - yyv4727 = []UniqueVolumeName{} - yyc4727 = true - } else if len(yyv4727) != 0 { - yyv4727 = yyv4727[:0] - yyc4727 = true - } - } else if yyl4727 > 0 { - var yyrr4727, yyrl4727 int - var yyrt4727 bool - if yyl4727 > cap(yyv4727) { - - yyrl4727, yyrt4727 = z.DecInferLen(yyl4727, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4727 { - if yyrl4727 <= cap(yyv4727) { - yyv4727 = yyv4727[:yyrl4727] - } else { - yyv4727 = make([]UniqueVolumeName, yyrl4727) - } - } else { - yyv4727 = make([]UniqueVolumeName, yyrl4727) - } - yyc4727 = true - yyrr4727 = len(yyv4727) - } else if yyl4727 != len(yyv4727) { - yyv4727 = yyv4727[:yyl4727] - yyc4727 = true - } - yyj4727 := 0 - for ; yyj4727 < yyrr4727; yyj4727++ { - yyh4727.ElemContainerState(yyj4727) - if r.TryDecodeAsNil() { - yyv4727[yyj4727] = "" - } else { - yyv4727[yyj4727] = UniqueVolumeName(r.DecodeString()) - } - - } - if yyrt4727 { - for ; yyj4727 < yyl4727; yyj4727++ { - yyv4727 = append(yyv4727, "") - yyh4727.ElemContainerState(yyj4727) - if r.TryDecodeAsNil() { - yyv4727[yyj4727] = "" - } else { - yyv4727[yyj4727] = UniqueVolumeName(r.DecodeString()) - } - - } - } - - } else { - yyj4727 := 0 - for ; !r.CheckBreak(); yyj4727++ { - - if yyj4727 >= len(yyv4727) { - yyv4727 = append(yyv4727, "") // var yyz4727 UniqueVolumeName - yyc4727 = true - } - yyh4727.ElemContainerState(yyj4727) - if yyj4727 < len(yyv4727) { - if r.TryDecodeAsNil() { - yyv4727[yyj4727] = "" - } else { - yyv4727[yyj4727] = UniqueVolumeName(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4727 < len(yyv4727) { - yyv4727 = yyv4727[:yyj4727] - yyc4727 = true - } else if yyj4727 == 0 && yyv4727 == nil { - yyv4727 = []UniqueVolumeName{} - yyc4727 = true - } - } - yyh4727.End() - if yyc4727 { - *v = yyv4727 - } -} - -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 _, yyv4731 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4732 := &yyv4731 - yy4732.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 - - yyv4733 := *v - yyh4733, yyl4733 := z.DecSliceHelperStart() - var yyc4733 bool - if yyl4733 == 0 { - if yyv4733 == nil { - yyv4733 = []AttachedVolume{} - yyc4733 = true - } else if len(yyv4733) != 0 { - yyv4733 = yyv4733[:0] - yyc4733 = true - } - } else if yyl4733 > 0 { - var yyrr4733, yyrl4733 int - var yyrt4733 bool - if yyl4733 > cap(yyv4733) { - - yyrg4733 := len(yyv4733) > 0 - yyv24733 := yyv4733 - yyrl4733, yyrt4733 = z.DecInferLen(yyl4733, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4733 { - if yyrl4733 <= cap(yyv4733) { - yyv4733 = yyv4733[:yyrl4733] - } else { - yyv4733 = make([]AttachedVolume, yyrl4733) - } - } else { - yyv4733 = make([]AttachedVolume, yyrl4733) - } - yyc4733 = true - yyrr4733 = len(yyv4733) - if yyrg4733 { - copy(yyv4733, yyv24733) - } - } else if yyl4733 != len(yyv4733) { - yyv4733 = yyv4733[:yyl4733] - yyc4733 = true - } - yyj4733 := 0 - for ; yyj4733 < yyrr4733; yyj4733++ { - yyh4733.ElemContainerState(yyj4733) - if r.TryDecodeAsNil() { - yyv4733[yyj4733] = AttachedVolume{} - } else { - yyv4734 := &yyv4733[yyj4733] - yyv4734.CodecDecodeSelf(d) - } - - } - if yyrt4733 { - for ; yyj4733 < yyl4733; yyj4733++ { - yyv4733 = append(yyv4733, AttachedVolume{}) - yyh4733.ElemContainerState(yyj4733) - if r.TryDecodeAsNil() { - yyv4733[yyj4733] = AttachedVolume{} - } else { - yyv4735 := &yyv4733[yyj4733] - yyv4735.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4733 := 0 - for ; !r.CheckBreak(); yyj4733++ { - - if yyj4733 >= len(yyv4733) { - yyv4733 = append(yyv4733, AttachedVolume{}) // var yyz4733 AttachedVolume - yyc4733 = true - } - yyh4733.ElemContainerState(yyj4733) - if yyj4733 < len(yyv4733) { - if r.TryDecodeAsNil() { - yyv4733[yyj4733] = AttachedVolume{} - } else { - yyv4736 := &yyv4733[yyj4733] - yyv4736.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4733 < len(yyv4733) { - yyv4733 = yyv4733[:yyj4733] - yyc4733 = true - } else if yyj4733 == 0 && yyv4733 == nil { - yyv4733 = []AttachedVolume{} - yyc4733 = true - } - } - yyh4733.End() - if yyc4733 { - *v = yyv4733 - } -} - -func (x codecSelfer1234) encSlicePreferAvoidPodsEntry(v []PreferAvoidPodsEntry, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv4737 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4738 := &yyv4737 - yy4738.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSlicePreferAvoidPodsEntry(v *[]PreferAvoidPodsEntry, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv4739 := *v - yyh4739, yyl4739 := z.DecSliceHelperStart() - var yyc4739 bool - if yyl4739 == 0 { - if yyv4739 == nil { - yyv4739 = []PreferAvoidPodsEntry{} - yyc4739 = true - } else if len(yyv4739) != 0 { - yyv4739 = yyv4739[:0] - yyc4739 = true - } - } else if yyl4739 > 0 { - var yyrr4739, yyrl4739 int - var yyrt4739 bool - if yyl4739 > cap(yyv4739) { - - yyrg4739 := len(yyv4739) > 0 - yyv24739 := yyv4739 - yyrl4739, yyrt4739 = z.DecInferLen(yyl4739, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4739 { - if yyrl4739 <= cap(yyv4739) { - yyv4739 = yyv4739[:yyrl4739] - } else { - yyv4739 = make([]PreferAvoidPodsEntry, yyrl4739) - } - } else { - yyv4739 = make([]PreferAvoidPodsEntry, yyrl4739) - } - yyc4739 = true - yyrr4739 = len(yyv4739) - if yyrg4739 { - copy(yyv4739, yyv24739) - } - } else if yyl4739 != len(yyv4739) { - yyv4739 = yyv4739[:yyl4739] - yyc4739 = true - } - yyj4739 := 0 - for ; yyj4739 < yyrr4739; yyj4739++ { - yyh4739.ElemContainerState(yyj4739) - if r.TryDecodeAsNil() { - yyv4739[yyj4739] = PreferAvoidPodsEntry{} - } else { - yyv4740 := &yyv4739[yyj4739] - yyv4740.CodecDecodeSelf(d) - } - - } - if yyrt4739 { - for ; yyj4739 < yyl4739; yyj4739++ { - yyv4739 = append(yyv4739, PreferAvoidPodsEntry{}) - yyh4739.ElemContainerState(yyj4739) - if r.TryDecodeAsNil() { - yyv4739[yyj4739] = PreferAvoidPodsEntry{} - } else { - yyv4741 := &yyv4739[yyj4739] - yyv4741.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4739 := 0 - for ; !r.CheckBreak(); yyj4739++ { - - if yyj4739 >= len(yyv4739) { - yyv4739 = append(yyv4739, PreferAvoidPodsEntry{}) // var yyz4739 PreferAvoidPodsEntry - yyc4739 = true - } - yyh4739.ElemContainerState(yyj4739) - if yyj4739 < len(yyv4739) { - if r.TryDecodeAsNil() { - yyv4739[yyj4739] = PreferAvoidPodsEntry{} - } else { - yyv4742 := &yyv4739[yyj4739] - yyv4742.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4739 < len(yyv4739) { - yyv4739 = yyv4739[:yyj4739] - yyc4739 = true - } else if yyj4739 == 0 && yyv4739 == nil { - yyv4739 = []PreferAvoidPodsEntry{} - yyc4739 = true - } - } - yyh4739.End() - if yyc4739 { - *v = yyv4739 - } -} - -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 yyk4743, yyv4743 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yyk4743.CodecEncodeSelf(e) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4744 := &yyv4743 - yym4745 := z.EncBinary() - _ = yym4745 - if false { - } else if z.HasExtensions() && z.EncExt(yy4744) { - } else if !yym4745 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4744) - } else { - z.EncFallback(yy4744) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) decResourceList(v *ResourceList, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv4746 := *v - yyl4746 := r.ReadMapStart() - yybh4746 := z.DecBasicHandle() - if yyv4746 == nil { - yyrl4746, _ := z.DecInferLen(yyl4746, yybh4746.MaxInitLen, 72) - yyv4746 = make(map[ResourceName]pkg3_resource.Quantity, yyrl4746) - *v = yyv4746 - } - var yymk4746 ResourceName - var yymv4746 pkg3_resource.Quantity - var yymg4746 bool - if yybh4746.MapValueReset { - yymg4746 = true - } - if yyl4746 > 0 { - for yyj4746 := 0; yyj4746 < yyl4746; yyj4746++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4746 = "" - } else { - yymk4746 = ResourceName(r.DecodeString()) - } - - if yymg4746 { - yymv4746 = yyv4746[yymk4746] - } else { - yymv4746 = pkg3_resource.Quantity{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4746 = pkg3_resource.Quantity{} - } else { - yyv4748 := &yymv4746 - yym4749 := z.DecBinary() - _ = yym4749 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4748) { - } else if !yym4749 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4748) - } else { - z.DecFallback(yyv4748, false) - } - } - - if yyv4746 != nil { - yyv4746[yymk4746] = yymv4746 - } - } - } else if yyl4746 < 0 { - for yyj4746 := 0; !r.CheckBreak(); yyj4746++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4746 = "" - } else { - yymk4746 = ResourceName(r.DecodeString()) - } - - if yymg4746 { - yymv4746 = yyv4746[yymk4746] - } else { - yymv4746 = pkg3_resource.Quantity{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4746 = pkg3_resource.Quantity{} - } else { - yyv4751 := &yymv4746 - yym4752 := z.DecBinary() - _ = yym4752 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4751) { - } else if !yym4752 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4751) - } else { - z.DecFallback(yyv4751, false) - } - } - - if yyv4746 != nil { - yyv4746[yymk4746] = yymv4746 - } - } - } // 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 _, yyv4753 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4754 := &yyv4753 - yy4754.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 - - yyv4755 := *v - yyh4755, yyl4755 := z.DecSliceHelperStart() - var yyc4755 bool - if yyl4755 == 0 { - if yyv4755 == nil { - yyv4755 = []Node{} - yyc4755 = true - } else if len(yyv4755) != 0 { - yyv4755 = yyv4755[:0] - yyc4755 = true - } - } else if yyl4755 > 0 { - var yyrr4755, yyrl4755 int - var yyrt4755 bool - if yyl4755 > cap(yyv4755) { - - yyrg4755 := len(yyv4755) > 0 - yyv24755 := yyv4755 - yyrl4755, yyrt4755 = z.DecInferLen(yyl4755, z.DecBasicHandle().MaxInitLen, 632) - if yyrt4755 { - if yyrl4755 <= cap(yyv4755) { - yyv4755 = yyv4755[:yyrl4755] - } else { - yyv4755 = make([]Node, yyrl4755) - } - } else { - yyv4755 = make([]Node, yyrl4755) - } - yyc4755 = true - yyrr4755 = len(yyv4755) - if yyrg4755 { - copy(yyv4755, yyv24755) - } - } else if yyl4755 != len(yyv4755) { - yyv4755 = yyv4755[:yyl4755] - yyc4755 = true - } - yyj4755 := 0 - for ; yyj4755 < yyrr4755; yyj4755++ { - yyh4755.ElemContainerState(yyj4755) - if r.TryDecodeAsNil() { - yyv4755[yyj4755] = Node{} - } else { - yyv4756 := &yyv4755[yyj4755] - yyv4756.CodecDecodeSelf(d) - } - - } - if yyrt4755 { - for ; yyj4755 < yyl4755; yyj4755++ { - yyv4755 = append(yyv4755, Node{}) - yyh4755.ElemContainerState(yyj4755) - if r.TryDecodeAsNil() { - yyv4755[yyj4755] = Node{} - } else { - yyv4757 := &yyv4755[yyj4755] - yyv4757.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4755 := 0 - for ; !r.CheckBreak(); yyj4755++ { - - if yyj4755 >= len(yyv4755) { - yyv4755 = append(yyv4755, Node{}) // var yyz4755 Node - yyc4755 = true - } - yyh4755.ElemContainerState(yyj4755) - if yyj4755 < len(yyv4755) { - if r.TryDecodeAsNil() { - yyv4755[yyj4755] = Node{} - } else { - yyv4758 := &yyv4755[yyj4755] - yyv4758.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4755 < len(yyv4755) { - yyv4755 = yyv4755[:yyj4755] - yyc4755 = true - } else if yyj4755 == 0 && yyv4755 == nil { - yyv4755 = []Node{} - yyc4755 = true - } - } - yyh4755.End() - if yyc4755 { - *v = yyv4755 - } -} - -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 _, yyv4759 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4759.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 - - yyv4760 := *v - yyh4760, yyl4760 := z.DecSliceHelperStart() - var yyc4760 bool - if yyl4760 == 0 { - if yyv4760 == nil { - yyv4760 = []FinalizerName{} - yyc4760 = true - } else if len(yyv4760) != 0 { - yyv4760 = yyv4760[:0] - yyc4760 = true - } - } else if yyl4760 > 0 { - var yyrr4760, yyrl4760 int - var yyrt4760 bool - if yyl4760 > cap(yyv4760) { - - yyrl4760, yyrt4760 = z.DecInferLen(yyl4760, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4760 { - if yyrl4760 <= cap(yyv4760) { - yyv4760 = yyv4760[:yyrl4760] - } else { - yyv4760 = make([]FinalizerName, yyrl4760) - } - } else { - yyv4760 = make([]FinalizerName, yyrl4760) - } - yyc4760 = true - yyrr4760 = len(yyv4760) - } else if yyl4760 != len(yyv4760) { - yyv4760 = yyv4760[:yyl4760] - yyc4760 = true - } - yyj4760 := 0 - for ; yyj4760 < yyrr4760; yyj4760++ { - yyh4760.ElemContainerState(yyj4760) - if r.TryDecodeAsNil() { - yyv4760[yyj4760] = "" - } else { - yyv4760[yyj4760] = FinalizerName(r.DecodeString()) - } - - } - if yyrt4760 { - for ; yyj4760 < yyl4760; yyj4760++ { - yyv4760 = append(yyv4760, "") - yyh4760.ElemContainerState(yyj4760) - if r.TryDecodeAsNil() { - yyv4760[yyj4760] = "" - } else { - yyv4760[yyj4760] = FinalizerName(r.DecodeString()) - } - - } - } - - } else { - yyj4760 := 0 - for ; !r.CheckBreak(); yyj4760++ { - - if yyj4760 >= len(yyv4760) { - yyv4760 = append(yyv4760, "") // var yyz4760 FinalizerName - yyc4760 = true - } - yyh4760.ElemContainerState(yyj4760) - if yyj4760 < len(yyv4760) { - if r.TryDecodeAsNil() { - yyv4760[yyj4760] = "" - } else { - yyv4760[yyj4760] = FinalizerName(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4760 < len(yyv4760) { - yyv4760 = yyv4760[:yyj4760] - yyc4760 = true - } else if yyj4760 == 0 && yyv4760 == nil { - yyv4760 = []FinalizerName{} - yyc4760 = true - } - } - yyh4760.End() - if yyc4760 { - *v = yyv4760 - } -} - -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 _, yyv4764 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4765 := &yyv4764 - yy4765.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 - - yyv4766 := *v - yyh4766, yyl4766 := z.DecSliceHelperStart() - var yyc4766 bool - if yyl4766 == 0 { - if yyv4766 == nil { - yyv4766 = []Namespace{} - yyc4766 = true - } else if len(yyv4766) != 0 { - yyv4766 = yyv4766[:0] - yyc4766 = true - } - } else if yyl4766 > 0 { - var yyrr4766, yyrl4766 int - var yyrt4766 bool - if yyl4766 > cap(yyv4766) { - - yyrg4766 := len(yyv4766) > 0 - yyv24766 := yyv4766 - yyrl4766, yyrt4766 = z.DecInferLen(yyl4766, z.DecBasicHandle().MaxInitLen, 296) - if yyrt4766 { - if yyrl4766 <= cap(yyv4766) { - yyv4766 = yyv4766[:yyrl4766] - } else { - yyv4766 = make([]Namespace, yyrl4766) - } - } else { - yyv4766 = make([]Namespace, yyrl4766) - } - yyc4766 = true - yyrr4766 = len(yyv4766) - if yyrg4766 { - copy(yyv4766, yyv24766) - } - } else if yyl4766 != len(yyv4766) { - yyv4766 = yyv4766[:yyl4766] - yyc4766 = true - } - yyj4766 := 0 - for ; yyj4766 < yyrr4766; yyj4766++ { - yyh4766.ElemContainerState(yyj4766) - if r.TryDecodeAsNil() { - yyv4766[yyj4766] = Namespace{} - } else { - yyv4767 := &yyv4766[yyj4766] - yyv4767.CodecDecodeSelf(d) - } - - } - if yyrt4766 { - for ; yyj4766 < yyl4766; yyj4766++ { - yyv4766 = append(yyv4766, Namespace{}) - yyh4766.ElemContainerState(yyj4766) - if r.TryDecodeAsNil() { - yyv4766[yyj4766] = Namespace{} - } else { - yyv4768 := &yyv4766[yyj4766] - yyv4768.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4766 := 0 - for ; !r.CheckBreak(); yyj4766++ { - - if yyj4766 >= len(yyv4766) { - yyv4766 = append(yyv4766, Namespace{}) // var yyz4766 Namespace - yyc4766 = true - } - yyh4766.ElemContainerState(yyj4766) - if yyj4766 < len(yyv4766) { - if r.TryDecodeAsNil() { - yyv4766[yyj4766] = Namespace{} - } else { - yyv4769 := &yyv4766[yyj4766] - yyv4769.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4766 < len(yyv4766) { - yyv4766 = yyv4766[:yyj4766] - yyc4766 = true - } else if yyj4766 == 0 && yyv4766 == nil { - yyv4766 = []Namespace{} - yyc4766 = true - } - } - yyh4766.End() - if yyc4766 { - *v = yyv4766 - } -} - -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 _, yyv4770 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4771 := &yyv4770 - yy4771.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 - - yyv4772 := *v - yyh4772, yyl4772 := z.DecSliceHelperStart() - var yyc4772 bool - if yyl4772 == 0 { - if yyv4772 == nil { - yyv4772 = []Event{} - yyc4772 = true - } else if len(yyv4772) != 0 { - yyv4772 = yyv4772[:0] - yyc4772 = true - } - } else if yyl4772 > 0 { - var yyrr4772, yyrl4772 int - var yyrt4772 bool - if yyl4772 > cap(yyv4772) { - - yyrg4772 := len(yyv4772) > 0 - yyv24772 := yyv4772 - yyrl4772, yyrt4772 = z.DecInferLen(yyl4772, z.DecBasicHandle().MaxInitLen, 504) - if yyrt4772 { - if yyrl4772 <= cap(yyv4772) { - yyv4772 = yyv4772[:yyrl4772] - } else { - yyv4772 = make([]Event, yyrl4772) - } - } else { - yyv4772 = make([]Event, yyrl4772) - } - yyc4772 = true - yyrr4772 = len(yyv4772) - if yyrg4772 { - copy(yyv4772, yyv24772) - } - } else if yyl4772 != len(yyv4772) { - yyv4772 = yyv4772[:yyl4772] - yyc4772 = true - } - yyj4772 := 0 - for ; yyj4772 < yyrr4772; yyj4772++ { - yyh4772.ElemContainerState(yyj4772) - if r.TryDecodeAsNil() { - yyv4772[yyj4772] = Event{} - } else { - yyv4773 := &yyv4772[yyj4772] - yyv4773.CodecDecodeSelf(d) - } - - } - if yyrt4772 { - for ; yyj4772 < yyl4772; yyj4772++ { - yyv4772 = append(yyv4772, Event{}) - yyh4772.ElemContainerState(yyj4772) - if r.TryDecodeAsNil() { - yyv4772[yyj4772] = Event{} - } else { - yyv4774 := &yyv4772[yyj4772] - yyv4774.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4772 := 0 - for ; !r.CheckBreak(); yyj4772++ { - - if yyj4772 >= len(yyv4772) { - yyv4772 = append(yyv4772, Event{}) // var yyz4772 Event - yyc4772 = true - } - yyh4772.ElemContainerState(yyj4772) - if yyj4772 < len(yyv4772) { - if r.TryDecodeAsNil() { - yyv4772[yyj4772] = Event{} - } else { - yyv4775 := &yyv4772[yyj4772] - yyv4775.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4772 < len(yyv4772) { - yyv4772 = yyv4772[:yyj4772] - yyc4772 = true - } else if yyj4772 == 0 && yyv4772 == nil { - yyv4772 = []Event{} - yyc4772 = true - } - } - yyh4772.End() - if yyc4772 { - *v = yyv4772 - } -} - -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 _, yyv4776 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4777 := &yyv4776 - yym4778 := z.EncBinary() - _ = yym4778 - if false { - } else if z.HasExtensions() && z.EncExt(yy4777) { - } else if !yym4778 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4777) - } else { - z.EncFallback(yy4777) - } - } - 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 - - yyv4779 := *v - yyh4779, yyl4779 := z.DecSliceHelperStart() - var yyc4779 bool - if yyl4779 == 0 { - if yyv4779 == nil { - yyv4779 = []pkg5_runtime.RawExtension{} - yyc4779 = true - } else if len(yyv4779) != 0 { - yyv4779 = yyv4779[:0] - yyc4779 = true - } - } else if yyl4779 > 0 { - var yyrr4779, yyrl4779 int - var yyrt4779 bool - if yyl4779 > cap(yyv4779) { - - yyrg4779 := len(yyv4779) > 0 - yyv24779 := yyv4779 - yyrl4779, yyrt4779 = z.DecInferLen(yyl4779, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4779 { - if yyrl4779 <= cap(yyv4779) { - yyv4779 = yyv4779[:yyrl4779] - } else { - yyv4779 = make([]pkg5_runtime.RawExtension, yyrl4779) - } - } else { - yyv4779 = make([]pkg5_runtime.RawExtension, yyrl4779) - } - yyc4779 = true - yyrr4779 = len(yyv4779) - if yyrg4779 { - copy(yyv4779, yyv24779) - } - } else if yyl4779 != len(yyv4779) { - yyv4779 = yyv4779[:yyl4779] - yyc4779 = true - } - yyj4779 := 0 - for ; yyj4779 < yyrr4779; yyj4779++ { - yyh4779.ElemContainerState(yyj4779) - if r.TryDecodeAsNil() { - yyv4779[yyj4779] = pkg5_runtime.RawExtension{} - } else { - yyv4780 := &yyv4779[yyj4779] - yym4781 := z.DecBinary() - _ = yym4781 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4780) { - } else if !yym4781 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4780) - } else { - z.DecFallback(yyv4780, false) - } - } - - } - if yyrt4779 { - for ; yyj4779 < yyl4779; yyj4779++ { - yyv4779 = append(yyv4779, pkg5_runtime.RawExtension{}) - yyh4779.ElemContainerState(yyj4779) - if r.TryDecodeAsNil() { - yyv4779[yyj4779] = pkg5_runtime.RawExtension{} - } else { - yyv4782 := &yyv4779[yyj4779] - yym4783 := z.DecBinary() - _ = yym4783 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4782) { - } else if !yym4783 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4782) - } else { - z.DecFallback(yyv4782, false) - } - } - - } - } - - } else { - yyj4779 := 0 - for ; !r.CheckBreak(); yyj4779++ { - - if yyj4779 >= len(yyv4779) { - yyv4779 = append(yyv4779, pkg5_runtime.RawExtension{}) // var yyz4779 pkg5_runtime.RawExtension - yyc4779 = true - } - yyh4779.ElemContainerState(yyj4779) - if yyj4779 < len(yyv4779) { - if r.TryDecodeAsNil() { - yyv4779[yyj4779] = pkg5_runtime.RawExtension{} - } else { - yyv4784 := &yyv4779[yyj4779] - yym4785 := z.DecBinary() - _ = yym4785 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4784) { - } else if !yym4785 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4784) - } else { - z.DecFallback(yyv4784, false) - } - } - - } else { - z.DecSwallow() - } - - } - if yyj4779 < len(yyv4779) { - yyv4779 = yyv4779[:yyj4779] - yyc4779 = true - } else if yyj4779 == 0 && yyv4779 == nil { - yyv4779 = []pkg5_runtime.RawExtension{} - yyc4779 = true - } - } - yyh4779.End() - if yyc4779 { - *v = yyv4779 - } -} - -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 _, yyv4786 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4787 := &yyv4786 - yy4787.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 - - yyv4788 := *v - yyh4788, yyl4788 := z.DecSliceHelperStart() - var yyc4788 bool - if yyl4788 == 0 { - if yyv4788 == nil { - yyv4788 = []LimitRangeItem{} - yyc4788 = true - } else if len(yyv4788) != 0 { - yyv4788 = yyv4788[:0] - yyc4788 = true - } - } else if yyl4788 > 0 { - var yyrr4788, yyrl4788 int - var yyrt4788 bool - if yyl4788 > cap(yyv4788) { - - yyrg4788 := len(yyv4788) > 0 - yyv24788 := yyv4788 - yyrl4788, yyrt4788 = z.DecInferLen(yyl4788, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4788 { - if yyrl4788 <= cap(yyv4788) { - yyv4788 = yyv4788[:yyrl4788] - } else { - yyv4788 = make([]LimitRangeItem, yyrl4788) - } - } else { - yyv4788 = make([]LimitRangeItem, yyrl4788) - } - yyc4788 = true - yyrr4788 = len(yyv4788) - if yyrg4788 { - copy(yyv4788, yyv24788) - } - } else if yyl4788 != len(yyv4788) { - yyv4788 = yyv4788[:yyl4788] - yyc4788 = true - } - yyj4788 := 0 - for ; yyj4788 < yyrr4788; yyj4788++ { - yyh4788.ElemContainerState(yyj4788) - if r.TryDecodeAsNil() { - yyv4788[yyj4788] = LimitRangeItem{} - } else { - yyv4789 := &yyv4788[yyj4788] - yyv4789.CodecDecodeSelf(d) - } - - } - if yyrt4788 { - for ; yyj4788 < yyl4788; yyj4788++ { - yyv4788 = append(yyv4788, LimitRangeItem{}) - yyh4788.ElemContainerState(yyj4788) - if r.TryDecodeAsNil() { - yyv4788[yyj4788] = LimitRangeItem{} - } else { - yyv4790 := &yyv4788[yyj4788] - yyv4790.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4788 := 0 - for ; !r.CheckBreak(); yyj4788++ { - - if yyj4788 >= len(yyv4788) { - yyv4788 = append(yyv4788, LimitRangeItem{}) // var yyz4788 LimitRangeItem - yyc4788 = true - } - yyh4788.ElemContainerState(yyj4788) - if yyj4788 < len(yyv4788) { - if r.TryDecodeAsNil() { - yyv4788[yyj4788] = LimitRangeItem{} - } else { - yyv4791 := &yyv4788[yyj4788] - yyv4791.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4788 < len(yyv4788) { - yyv4788 = yyv4788[:yyj4788] - yyc4788 = true - } else if yyj4788 == 0 && yyv4788 == nil { - yyv4788 = []LimitRangeItem{} - yyc4788 = true - } - } - yyh4788.End() - if yyc4788 { - *v = yyv4788 - } -} - -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 _, yyv4792 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4793 := &yyv4792 - yy4793.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 - - yyv4794 := *v - yyh4794, yyl4794 := z.DecSliceHelperStart() - var yyc4794 bool - if yyl4794 == 0 { - if yyv4794 == nil { - yyv4794 = []LimitRange{} - yyc4794 = true - } else if len(yyv4794) != 0 { - yyv4794 = yyv4794[:0] - yyc4794 = true - } - } else if yyl4794 > 0 { - var yyrr4794, yyrl4794 int - var yyrt4794 bool - if yyl4794 > cap(yyv4794) { - - yyrg4794 := len(yyv4794) > 0 - yyv24794 := yyv4794 - yyrl4794, yyrt4794 = z.DecInferLen(yyl4794, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4794 { - if yyrl4794 <= cap(yyv4794) { - yyv4794 = yyv4794[:yyrl4794] - } else { - yyv4794 = make([]LimitRange, yyrl4794) - } - } else { - yyv4794 = make([]LimitRange, yyrl4794) - } - yyc4794 = true - yyrr4794 = len(yyv4794) - if yyrg4794 { - copy(yyv4794, yyv24794) - } - } else if yyl4794 != len(yyv4794) { - yyv4794 = yyv4794[:yyl4794] - yyc4794 = true - } - yyj4794 := 0 - for ; yyj4794 < yyrr4794; yyj4794++ { - yyh4794.ElemContainerState(yyj4794) - if r.TryDecodeAsNil() { - yyv4794[yyj4794] = LimitRange{} - } else { - yyv4795 := &yyv4794[yyj4794] - yyv4795.CodecDecodeSelf(d) - } - - } - if yyrt4794 { - for ; yyj4794 < yyl4794; yyj4794++ { - yyv4794 = append(yyv4794, LimitRange{}) - yyh4794.ElemContainerState(yyj4794) - if r.TryDecodeAsNil() { - yyv4794[yyj4794] = LimitRange{} - } else { - yyv4796 := &yyv4794[yyj4794] - yyv4796.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4794 := 0 - for ; !r.CheckBreak(); yyj4794++ { - - if yyj4794 >= len(yyv4794) { - yyv4794 = append(yyv4794, LimitRange{}) // var yyz4794 LimitRange - yyc4794 = true - } - yyh4794.ElemContainerState(yyj4794) - if yyj4794 < len(yyv4794) { - if r.TryDecodeAsNil() { - yyv4794[yyj4794] = LimitRange{} - } else { - yyv4797 := &yyv4794[yyj4794] - yyv4797.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4794 < len(yyv4794) { - yyv4794 = yyv4794[:yyj4794] - yyc4794 = true - } else if yyj4794 == 0 && yyv4794 == nil { - yyv4794 = []LimitRange{} - yyc4794 = true - } - } - yyh4794.End() - if yyc4794 { - *v = yyv4794 - } -} - -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 _, yyv4798 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4798.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 - - yyv4799 := *v - yyh4799, yyl4799 := z.DecSliceHelperStart() - var yyc4799 bool - if yyl4799 == 0 { - if yyv4799 == nil { - yyv4799 = []ResourceQuotaScope{} - yyc4799 = true - } else if len(yyv4799) != 0 { - yyv4799 = yyv4799[:0] - yyc4799 = true - } - } else if yyl4799 > 0 { - var yyrr4799, yyrl4799 int - var yyrt4799 bool - if yyl4799 > cap(yyv4799) { - - yyrl4799, yyrt4799 = z.DecInferLen(yyl4799, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4799 { - if yyrl4799 <= cap(yyv4799) { - yyv4799 = yyv4799[:yyrl4799] - } else { - yyv4799 = make([]ResourceQuotaScope, yyrl4799) - } - } else { - yyv4799 = make([]ResourceQuotaScope, yyrl4799) - } - yyc4799 = true - yyrr4799 = len(yyv4799) - } else if yyl4799 != len(yyv4799) { - yyv4799 = yyv4799[:yyl4799] - yyc4799 = true - } - yyj4799 := 0 - for ; yyj4799 < yyrr4799; yyj4799++ { - yyh4799.ElemContainerState(yyj4799) - if r.TryDecodeAsNil() { - yyv4799[yyj4799] = "" - } else { - yyv4799[yyj4799] = ResourceQuotaScope(r.DecodeString()) - } - - } - if yyrt4799 { - for ; yyj4799 < yyl4799; yyj4799++ { - yyv4799 = append(yyv4799, "") - yyh4799.ElemContainerState(yyj4799) - if r.TryDecodeAsNil() { - yyv4799[yyj4799] = "" - } else { - yyv4799[yyj4799] = ResourceQuotaScope(r.DecodeString()) - } - - } - } - - } else { - yyj4799 := 0 - for ; !r.CheckBreak(); yyj4799++ { - - if yyj4799 >= len(yyv4799) { - yyv4799 = append(yyv4799, "") // var yyz4799 ResourceQuotaScope - yyc4799 = true - } - yyh4799.ElemContainerState(yyj4799) - if yyj4799 < len(yyv4799) { - if r.TryDecodeAsNil() { - yyv4799[yyj4799] = "" - } else { - yyv4799[yyj4799] = ResourceQuotaScope(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4799 < len(yyv4799) { - yyv4799 = yyv4799[:yyj4799] - yyc4799 = true - } else if yyj4799 == 0 && yyv4799 == nil { - yyv4799 = []ResourceQuotaScope{} - yyc4799 = true - } - } - yyh4799.End() - if yyc4799 { - *v = yyv4799 - } -} - -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 _, yyv4803 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4804 := &yyv4803 - yy4804.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 - - yyv4805 := *v - yyh4805, yyl4805 := z.DecSliceHelperStart() - var yyc4805 bool - if yyl4805 == 0 { - if yyv4805 == nil { - yyv4805 = []ResourceQuota{} - yyc4805 = true - } else if len(yyv4805) != 0 { - yyv4805 = yyv4805[:0] - yyc4805 = true - } - } else if yyl4805 > 0 { - var yyrr4805, yyrl4805 int - var yyrt4805 bool - if yyl4805 > cap(yyv4805) { - - yyrg4805 := len(yyv4805) > 0 - yyv24805 := yyv4805 - yyrl4805, yyrt4805 = z.DecInferLen(yyl4805, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4805 { - if yyrl4805 <= cap(yyv4805) { - yyv4805 = yyv4805[:yyrl4805] - } else { - yyv4805 = make([]ResourceQuota, yyrl4805) - } - } else { - yyv4805 = make([]ResourceQuota, yyrl4805) - } - yyc4805 = true - yyrr4805 = len(yyv4805) - if yyrg4805 { - copy(yyv4805, yyv24805) - } - } else if yyl4805 != len(yyv4805) { - yyv4805 = yyv4805[:yyl4805] - yyc4805 = true - } - yyj4805 := 0 - for ; yyj4805 < yyrr4805; yyj4805++ { - yyh4805.ElemContainerState(yyj4805) - if r.TryDecodeAsNil() { - yyv4805[yyj4805] = ResourceQuota{} - } else { - yyv4806 := &yyv4805[yyj4805] - yyv4806.CodecDecodeSelf(d) - } - - } - if yyrt4805 { - for ; yyj4805 < yyl4805; yyj4805++ { - yyv4805 = append(yyv4805, ResourceQuota{}) - yyh4805.ElemContainerState(yyj4805) - if r.TryDecodeAsNil() { - yyv4805[yyj4805] = ResourceQuota{} - } else { - yyv4807 := &yyv4805[yyj4805] - yyv4807.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4805 := 0 - for ; !r.CheckBreak(); yyj4805++ { - - if yyj4805 >= len(yyv4805) { - yyv4805 = append(yyv4805, ResourceQuota{}) // var yyz4805 ResourceQuota - yyc4805 = true - } - yyh4805.ElemContainerState(yyj4805) - if yyj4805 < len(yyv4805) { - if r.TryDecodeAsNil() { - yyv4805[yyj4805] = ResourceQuota{} - } else { - yyv4808 := &yyv4805[yyj4805] - yyv4808.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4805 < len(yyv4805) { - yyv4805 = yyv4805[:yyj4805] - yyc4805 = true - } else if yyj4805 == 0 && yyv4805 == nil { - yyv4805 = []ResourceQuota{} - yyc4805 = true - } - } - yyh4805.End() - if yyc4805 { - *v = yyv4805 - } -} - -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 yyk4809, yyv4809 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym4810 := z.EncBinary() - _ = yym4810 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk4809)) - } - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv4809 == nil { - r.EncodeNil() - } else { - yym4811 := z.EncBinary() - _ = yym4811 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(yyv4809)) - } - } - } - 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 - - yyv4812 := *v - yyl4812 := r.ReadMapStart() - yybh4812 := z.DecBasicHandle() - if yyv4812 == nil { - yyrl4812, _ := z.DecInferLen(yyl4812, yybh4812.MaxInitLen, 40) - yyv4812 = make(map[string][]uint8, yyrl4812) - *v = yyv4812 - } - var yymk4812 string - var yymv4812 []uint8 - var yymg4812 bool - if yybh4812.MapValueReset { - yymg4812 = true - } - if yyl4812 > 0 { - for yyj4812 := 0; yyj4812 < yyl4812; yyj4812++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4812 = "" - } else { - yymk4812 = string(r.DecodeString()) - } - - if yymg4812 { - yymv4812 = yyv4812[yymk4812] - } else { - yymv4812 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4812 = nil - } else { - yyv4814 := &yymv4812 - yym4815 := z.DecBinary() - _ = yym4815 - if false { - } else { - *yyv4814 = r.DecodeBytes(*(*[]byte)(yyv4814), false, false) - } - } - - if yyv4812 != nil { - yyv4812[yymk4812] = yymv4812 - } - } - } else if yyl4812 < 0 { - for yyj4812 := 0; !r.CheckBreak(); yyj4812++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4812 = "" - } else { - yymk4812 = string(r.DecodeString()) - } - - if yymg4812 { - yymv4812 = yyv4812[yymk4812] - } else { - yymv4812 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4812 = nil - } else { - yyv4817 := &yymv4812 - yym4818 := z.DecBinary() - _ = yym4818 - if false { - } else { - *yyv4817 = r.DecodeBytes(*(*[]byte)(yyv4817), false, false) - } - } - - if yyv4812 != nil { - yyv4812[yymk4812] = yymv4812 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -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 _, yyv4819 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4820 := &yyv4819 - yy4820.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 - - yyv4821 := *v - yyh4821, yyl4821 := z.DecSliceHelperStart() - var yyc4821 bool - if yyl4821 == 0 { - if yyv4821 == nil { - yyv4821 = []Secret{} - yyc4821 = true - } else if len(yyv4821) != 0 { - yyv4821 = yyv4821[:0] - yyc4821 = true - } - } else if yyl4821 > 0 { - var yyrr4821, yyrl4821 int - var yyrt4821 bool - if yyl4821 > cap(yyv4821) { - - yyrg4821 := len(yyv4821) > 0 - yyv24821 := yyv4821 - yyrl4821, yyrt4821 = z.DecInferLen(yyl4821, z.DecBasicHandle().MaxInitLen, 288) - if yyrt4821 { - if yyrl4821 <= cap(yyv4821) { - yyv4821 = yyv4821[:yyrl4821] - } else { - yyv4821 = make([]Secret, yyrl4821) - } - } else { - yyv4821 = make([]Secret, yyrl4821) - } - yyc4821 = true - yyrr4821 = len(yyv4821) - if yyrg4821 { - copy(yyv4821, yyv24821) - } - } else if yyl4821 != len(yyv4821) { - yyv4821 = yyv4821[:yyl4821] - yyc4821 = true - } - yyj4821 := 0 - for ; yyj4821 < yyrr4821; yyj4821++ { - yyh4821.ElemContainerState(yyj4821) - if r.TryDecodeAsNil() { - yyv4821[yyj4821] = Secret{} - } else { - yyv4822 := &yyv4821[yyj4821] - yyv4822.CodecDecodeSelf(d) - } - - } - if yyrt4821 { - for ; yyj4821 < yyl4821; yyj4821++ { - yyv4821 = append(yyv4821, Secret{}) - yyh4821.ElemContainerState(yyj4821) - if r.TryDecodeAsNil() { - yyv4821[yyj4821] = Secret{} - } else { - yyv4823 := &yyv4821[yyj4821] - yyv4823.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4821 := 0 - for ; !r.CheckBreak(); yyj4821++ { - - if yyj4821 >= len(yyv4821) { - yyv4821 = append(yyv4821, Secret{}) // var yyz4821 Secret - yyc4821 = true - } - yyh4821.ElemContainerState(yyj4821) - if yyj4821 < len(yyv4821) { - if r.TryDecodeAsNil() { - yyv4821[yyj4821] = Secret{} - } else { - yyv4824 := &yyv4821[yyj4821] - yyv4824.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4821 < len(yyv4821) { - yyv4821 = yyv4821[:yyj4821] - yyc4821 = true - } else if yyj4821 == 0 && yyv4821 == nil { - yyv4821 = []Secret{} - yyc4821 = true - } - } - yyh4821.End() - if yyc4821 { - *v = yyv4821 - } -} - -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 _, yyv4825 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4826 := &yyv4825 - yy4826.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 - - yyv4827 := *v - yyh4827, yyl4827 := z.DecSliceHelperStart() - var yyc4827 bool - if yyl4827 == 0 { - if yyv4827 == nil { - yyv4827 = []ConfigMap{} - yyc4827 = true - } else if len(yyv4827) != 0 { - yyv4827 = yyv4827[:0] - yyc4827 = true - } - } else if yyl4827 > 0 { - var yyrr4827, yyrl4827 int - var yyrt4827 bool - if yyl4827 > cap(yyv4827) { - - yyrg4827 := len(yyv4827) > 0 - yyv24827 := yyv4827 - yyrl4827, yyrt4827 = z.DecInferLen(yyl4827, z.DecBasicHandle().MaxInitLen, 264) - if yyrt4827 { - if yyrl4827 <= cap(yyv4827) { - yyv4827 = yyv4827[:yyrl4827] - } else { - yyv4827 = make([]ConfigMap, yyrl4827) - } - } else { - yyv4827 = make([]ConfigMap, yyrl4827) - } - yyc4827 = true - yyrr4827 = len(yyv4827) - if yyrg4827 { - copy(yyv4827, yyv24827) - } - } else if yyl4827 != len(yyv4827) { - yyv4827 = yyv4827[:yyl4827] - yyc4827 = true - } - yyj4827 := 0 - for ; yyj4827 < yyrr4827; yyj4827++ { - yyh4827.ElemContainerState(yyj4827) - if r.TryDecodeAsNil() { - yyv4827[yyj4827] = ConfigMap{} - } else { - yyv4828 := &yyv4827[yyj4827] - yyv4828.CodecDecodeSelf(d) - } - - } - if yyrt4827 { - for ; yyj4827 < yyl4827; yyj4827++ { - yyv4827 = append(yyv4827, ConfigMap{}) - yyh4827.ElemContainerState(yyj4827) - if r.TryDecodeAsNil() { - yyv4827[yyj4827] = ConfigMap{} - } else { - yyv4829 := &yyv4827[yyj4827] - yyv4829.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4827 := 0 - for ; !r.CheckBreak(); yyj4827++ { - - if yyj4827 >= len(yyv4827) { - yyv4827 = append(yyv4827, ConfigMap{}) // var yyz4827 ConfigMap - yyc4827 = true - } - yyh4827.ElemContainerState(yyj4827) - if yyj4827 < len(yyv4827) { - if r.TryDecodeAsNil() { - yyv4827[yyj4827] = ConfigMap{} - } else { - yyv4830 := &yyv4827[yyj4827] - yyv4830.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4827 < len(yyv4827) { - yyv4827 = yyv4827[:yyj4827] - yyc4827 = true - } else if yyj4827 == 0 && yyv4827 == nil { - yyv4827 = []ConfigMap{} - yyc4827 = true - } - } - yyh4827.End() - if yyc4827 { - *v = yyv4827 - } -} - -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 _, yyv4831 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4832 := &yyv4831 - yy4832.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 - - yyv4833 := *v - yyh4833, yyl4833 := z.DecSliceHelperStart() - var yyc4833 bool - if yyl4833 == 0 { - if yyv4833 == nil { - yyv4833 = []ComponentCondition{} - yyc4833 = true - } else if len(yyv4833) != 0 { - yyv4833 = yyv4833[:0] - yyc4833 = true - } - } else if yyl4833 > 0 { - var yyrr4833, yyrl4833 int - var yyrt4833 bool - if yyl4833 > cap(yyv4833) { - - yyrg4833 := len(yyv4833) > 0 - yyv24833 := yyv4833 - yyrl4833, yyrt4833 = z.DecInferLen(yyl4833, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4833 { - if yyrl4833 <= cap(yyv4833) { - yyv4833 = yyv4833[:yyrl4833] - } else { - yyv4833 = make([]ComponentCondition, yyrl4833) - } - } else { - yyv4833 = make([]ComponentCondition, yyrl4833) - } - yyc4833 = true - yyrr4833 = len(yyv4833) - if yyrg4833 { - copy(yyv4833, yyv24833) - } - } else if yyl4833 != len(yyv4833) { - yyv4833 = yyv4833[:yyl4833] - yyc4833 = true - } - yyj4833 := 0 - for ; yyj4833 < yyrr4833; yyj4833++ { - yyh4833.ElemContainerState(yyj4833) - if r.TryDecodeAsNil() { - yyv4833[yyj4833] = ComponentCondition{} - } else { - yyv4834 := &yyv4833[yyj4833] - yyv4834.CodecDecodeSelf(d) - } - - } - if yyrt4833 { - for ; yyj4833 < yyl4833; yyj4833++ { - yyv4833 = append(yyv4833, ComponentCondition{}) - yyh4833.ElemContainerState(yyj4833) - if r.TryDecodeAsNil() { - yyv4833[yyj4833] = ComponentCondition{} - } else { - yyv4835 := &yyv4833[yyj4833] - yyv4835.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4833 := 0 - for ; !r.CheckBreak(); yyj4833++ { - - if yyj4833 >= len(yyv4833) { - yyv4833 = append(yyv4833, ComponentCondition{}) // var yyz4833 ComponentCondition - yyc4833 = true - } - yyh4833.ElemContainerState(yyj4833) - if yyj4833 < len(yyv4833) { - if r.TryDecodeAsNil() { - yyv4833[yyj4833] = ComponentCondition{} - } else { - yyv4836 := &yyv4833[yyj4833] - yyv4836.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4833 < len(yyv4833) { - yyv4833 = yyv4833[:yyj4833] - yyc4833 = true - } else if yyj4833 == 0 && yyv4833 == nil { - yyv4833 = []ComponentCondition{} - yyc4833 = true - } - } - yyh4833.End() - if yyc4833 { - *v = yyv4833 - } -} - -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 _, yyv4837 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4838 := &yyv4837 - yy4838.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 - - yyv4839 := *v - yyh4839, yyl4839 := z.DecSliceHelperStart() - var yyc4839 bool - if yyl4839 == 0 { - if yyv4839 == nil { - yyv4839 = []ComponentStatus{} - yyc4839 = true - } else if len(yyv4839) != 0 { - yyv4839 = yyv4839[:0] - yyc4839 = true - } - } else if yyl4839 > 0 { - var yyrr4839, yyrl4839 int - var yyrt4839 bool - if yyl4839 > cap(yyv4839) { - - yyrg4839 := len(yyv4839) > 0 - yyv24839 := yyv4839 - yyrl4839, yyrt4839 = z.DecInferLen(yyl4839, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4839 { - if yyrl4839 <= cap(yyv4839) { - yyv4839 = yyv4839[:yyrl4839] - } else { - yyv4839 = make([]ComponentStatus, yyrl4839) - } - } else { - yyv4839 = make([]ComponentStatus, yyrl4839) - } - yyc4839 = true - yyrr4839 = len(yyv4839) - if yyrg4839 { - copy(yyv4839, yyv24839) - } - } else if yyl4839 != len(yyv4839) { - yyv4839 = yyv4839[:yyl4839] - yyc4839 = true - } - yyj4839 := 0 - for ; yyj4839 < yyrr4839; yyj4839++ { - yyh4839.ElemContainerState(yyj4839) - if r.TryDecodeAsNil() { - yyv4839[yyj4839] = ComponentStatus{} - } else { - yyv4840 := &yyv4839[yyj4839] - yyv4840.CodecDecodeSelf(d) - } - - } - if yyrt4839 { - for ; yyj4839 < yyl4839; yyj4839++ { - yyv4839 = append(yyv4839, ComponentStatus{}) - yyh4839.ElemContainerState(yyj4839) - if r.TryDecodeAsNil() { - yyv4839[yyj4839] = ComponentStatus{} - } else { - yyv4841 := &yyv4839[yyj4839] - yyv4841.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4839 := 0 - for ; !r.CheckBreak(); yyj4839++ { - - if yyj4839 >= len(yyv4839) { - yyv4839 = append(yyv4839, ComponentStatus{}) // var yyz4839 ComponentStatus - yyc4839 = true - } - yyh4839.ElemContainerState(yyj4839) - if yyj4839 < len(yyv4839) { - if r.TryDecodeAsNil() { - yyv4839[yyj4839] = ComponentStatus{} - } else { - yyv4842 := &yyv4839[yyj4839] - yyv4842.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4839 < len(yyv4839) { - yyv4839 = yyv4839[:yyj4839] - yyc4839 = true - } else if yyj4839 == 0 && yyv4839 == nil { - yyv4839 = []ComponentStatus{} - yyc4839 = true - } - } - yyh4839.End() - if yyc4839 { - *v = yyv4839 - } -} - -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 _, yyv4843 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4844 := &yyv4843 - yy4844.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 - - yyv4845 := *v - yyh4845, yyl4845 := z.DecSliceHelperStart() - var yyc4845 bool - if yyl4845 == 0 { - if yyv4845 == nil { - yyv4845 = []DownwardAPIVolumeFile{} - yyc4845 = true - } else if len(yyv4845) != 0 { - yyv4845 = yyv4845[:0] - yyc4845 = true - } - } else if yyl4845 > 0 { - var yyrr4845, yyrl4845 int - var yyrt4845 bool - if yyl4845 > cap(yyv4845) { - - yyrg4845 := len(yyv4845) > 0 - yyv24845 := yyv4845 - yyrl4845, yyrt4845 = z.DecInferLen(yyl4845, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4845 { - if yyrl4845 <= cap(yyv4845) { - yyv4845 = yyv4845[:yyrl4845] - } else { - yyv4845 = make([]DownwardAPIVolumeFile, yyrl4845) - } - } else { - yyv4845 = make([]DownwardAPIVolumeFile, yyrl4845) - } - yyc4845 = true - yyrr4845 = len(yyv4845) - if yyrg4845 { - copy(yyv4845, yyv24845) - } - } else if yyl4845 != len(yyv4845) { - yyv4845 = yyv4845[:yyl4845] - yyc4845 = true - } - yyj4845 := 0 - for ; yyj4845 < yyrr4845; yyj4845++ { - yyh4845.ElemContainerState(yyj4845) - if r.TryDecodeAsNil() { - yyv4845[yyj4845] = DownwardAPIVolumeFile{} - } else { - yyv4846 := &yyv4845[yyj4845] - yyv4846.CodecDecodeSelf(d) - } - - } - if yyrt4845 { - for ; yyj4845 < yyl4845; yyj4845++ { - yyv4845 = append(yyv4845, DownwardAPIVolumeFile{}) - yyh4845.ElemContainerState(yyj4845) - if r.TryDecodeAsNil() { - yyv4845[yyj4845] = DownwardAPIVolumeFile{} - } else { - yyv4847 := &yyv4845[yyj4845] - yyv4847.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4845 := 0 - for ; !r.CheckBreak(); yyj4845++ { - - if yyj4845 >= len(yyv4845) { - yyv4845 = append(yyv4845, DownwardAPIVolumeFile{}) // var yyz4845 DownwardAPIVolumeFile - yyc4845 = true - } - yyh4845.ElemContainerState(yyj4845) - if yyj4845 < len(yyv4845) { - if r.TryDecodeAsNil() { - yyv4845[yyj4845] = DownwardAPIVolumeFile{} - } else { - yyv4848 := &yyv4845[yyj4845] - yyv4848.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4845 < len(yyv4845) { - yyv4845 = yyv4845[:yyj4845] - yyc4845 = true - } else if yyj4845 == 0 && yyv4845 == nil { - yyv4845 = []DownwardAPIVolumeFile{} - yyc4845 = true - } - } - yyh4845.End() - if yyc4845 { - *v = yyv4845 - } -}